Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -35,6 +35,18 @@ def mountain_color(height:int)-> str:
|
|
| 35 |
return f"Error determining the mountain color : {str(e)}"
|
| 36 |
|
| 37 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 38 |
@tool
|
| 39 |
def get_current_time_in_timezone(timezone: str) -> str:
|
| 40 |
"""A tool that fetches the current local time in a specified timezone.
|
|
@@ -72,7 +84,7 @@ with open("prompts.yaml", 'r') as stream:
|
|
| 72 |
|
| 73 |
agent = CodeAgent(
|
| 74 |
model=model,
|
| 75 |
-
tools=[final_answer,
|
| 76 |
max_steps=6,
|
| 77 |
verbosity_level=1,
|
| 78 |
grammar=None,
|
|
|
|
| 35 |
return f"Error determining the mountain color : {str(e)}"
|
| 36 |
|
| 37 |
|
| 38 |
+
@tool
|
| 39 |
+
def bill_dudii_height()-> str:
|
| 40 |
+
"""A tool that gives the height of Bill Dudii
|
| 41 |
+
Args:
|
| 42 |
+
none
|
| 43 |
+
"""
|
| 44 |
+
try:
|
| 45 |
+
return "5577"
|
| 46 |
+
except Exception as e:
|
| 47 |
+
return f"Error giving Bill Dudii's height : {str(e)}"
|
| 48 |
+
|
| 49 |
+
|
| 50 |
@tool
|
| 51 |
def get_current_time_in_timezone(timezone: str) -> str:
|
| 52 |
"""A tool that fetches the current local time in a specified timezone.
|
|
|
|
| 84 |
|
| 85 |
agent = CodeAgent(
|
| 86 |
model=model,
|
| 87 |
+
tools=[final_answer, bill_dudii_height], ## add your tools here (don't remove final answer)
|
| 88 |
max_steps=6,
|
| 89 |
verbosity_level=1,
|
| 90 |
grammar=None,
|