Spaces:
				
			
			
	
			
			
		Sleeping
		
	
	
	
			
			
	
	
	
	
		
		
		Sleeping
		
	Update app.py
Browse files
    	
        app.py
    CHANGED
    
    | @@ -3,6 +3,7 @@ import datetime | |
| 3 | 
             
            import requests
         | 
| 4 | 
             
            import pytz
         | 
| 5 | 
             
            import yaml
         | 
|  | |
| 6 |  | 
| 7 | 
             
            from Gradio_UI import GradioUI
         | 
| 8 |  | 
| @@ -32,6 +33,7 @@ def get_current_time_in_timezone(timezone: str) -> str: | |
| 32 | 
             
                    return f"Error fetching time for timezone '{timezone}': {str(e)}"
         | 
| 33 |  | 
| 34 |  | 
|  | |
| 35 | 
             
            model = HfApiModel(
         | 
| 36 | 
             
            max_tokens=2096,
         | 
| 37 | 
             
            temperature=0.5,
         | 
| @@ -48,7 +50,7 @@ with open("prompts.yaml", 'r') as stream: | |
| 48 |  | 
| 49 | 
             
            agent = CodeAgent(
         | 
| 50 | 
             
                model=model,
         | 
| 51 | 
            -
                tools=[image_generation_tool,get_current_time_in_timezone,DuckDuckGoSearchTool()], ## add or remove tools here
         | 
| 52 | 
             
                max_steps=6,
         | 
| 53 | 
             
                verbosity_level=1,
         | 
| 54 | 
             
                grammar=None,
         | 
|  | |
| 3 | 
             
            import requests
         | 
| 4 | 
             
            import pytz
         | 
| 5 | 
             
            import yaml
         | 
| 6 | 
            +
            from tools.final_answer import FinalAnswerTool
         | 
| 7 |  | 
| 8 | 
             
            from Gradio_UI import GradioUI
         | 
| 9 |  | 
|  | |
| 33 | 
             
                    return f"Error fetching time for timezone '{timezone}': {str(e)}"
         | 
| 34 |  | 
| 35 |  | 
| 36 | 
            +
            final_answer = FinalAnswerTool()
         | 
| 37 | 
             
            model = HfApiModel(
         | 
| 38 | 
             
            max_tokens=2096,
         | 
| 39 | 
             
            temperature=0.5,
         | 
|  | |
| 50 |  | 
| 51 | 
             
            agent = CodeAgent(
         | 
| 52 | 
             
                model=model,
         | 
| 53 | 
            +
                tools=[image_generation_tool,get_current_time_in_timezone,final_answer,DuckDuckGoSearchTool()], ## add or remove tools here
         | 
| 54 | 
             
                max_steps=6,
         | 
| 55 | 
             
                verbosity_level=1,
         | 
| 56 | 
             
                grammar=None,
         | 
 
			
