Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -31,8 +31,8 @@ def my_websearch(query:str, max_result:int = 3)-> str: #it's import to specify t
|
|
| 31 |
except Exception as e:
|
| 32 |
return f"Search failed with error: {str(e)}"
|
| 33 |
|
| 34 |
-
|
| 35 |
-
web_page = DuckDuckGoSearchTool()
|
| 36 |
|
| 37 |
@tool
|
| 38 |
def get_current_time_in_timezone(timezone: str) -> str:
|
|
@@ -71,7 +71,7 @@ with open("prompts.yaml", 'r') as stream:
|
|
| 71 |
|
| 72 |
agent = CodeAgent(
|
| 73 |
model=model,
|
| 74 |
-
tools=[final_answer,
|
| 75 |
max_steps=6,
|
| 76 |
verbosity_level=1,
|
| 77 |
grammar=None,
|
|
|
|
| 31 |
except Exception as e:
|
| 32 |
return f"Search failed with error: {str(e)}"
|
| 33 |
|
| 34 |
+
websearch = DuckDuckGoSearchTool()
|
| 35 |
+
#web_page = DuckDuckGoSearchTool()
|
| 36 |
|
| 37 |
@tool
|
| 38 |
def get_current_time_in_timezone(timezone: str) -> str:
|
|
|
|
| 71 |
|
| 72 |
agent = CodeAgent(
|
| 73 |
model=model,
|
| 74 |
+
tools=[final_answer, websearch], ## add your tools here (don't remove final answer)
|
| 75 |
max_steps=6,
|
| 76 |
verbosity_level=1,
|
| 77 |
grammar=None,
|