Spaces:
Sleeping
Sleeping
Adding more description context about the tool
Browse files
app.py
CHANGED
|
@@ -25,13 +25,13 @@ def my_custom_tool(arg1:str, arg2:int)-> str: #it's import to specify the return
|
|
| 25 |
#ds = load_dataset("nfliu/decontextualization")
|
| 26 |
|
| 27 |
@tool
|
| 28 |
-
def
|
| 29 |
|
| 30 |
"""
|
| 31 |
-
A tool
|
| 32 |
|
| 33 |
Args:
|
| 34 |
-
question: The user question to lookup the answer
|
| 35 |
"""
|
| 36 |
|
| 37 |
# Prepare the duckduckgo query
|
|
@@ -120,7 +120,7 @@ with open("prompts.yaml", 'r') as stream:
|
|
| 120 |
|
| 121 |
agent = CodeAgent(
|
| 122 |
model=model,
|
| 123 |
-
tools=[final_answer,tool_calculator,
|
| 124 |
max_steps=6,
|
| 125 |
verbosity_level=1,
|
| 126 |
grammar=None,
|
|
|
|
| 25 |
#ds = load_dataset("nfliu/decontextualization")
|
| 26 |
|
| 27 |
@tool
|
| 28 |
+
def answer_nfl_question_tool(question: str ) -> str:
|
| 29 |
|
| 30 |
"""
|
| 31 |
+
A tool that answer the user's questions about the NFL rules, tactics and players.
|
| 32 |
|
| 33 |
Args:
|
| 34 |
+
question: The user's question that agent have to lookup the answer using the DuckDuckGo browser
|
| 35 |
"""
|
| 36 |
|
| 37 |
# Prepare the duckduckgo query
|
|
|
|
| 120 |
|
| 121 |
agent = CodeAgent(
|
| 122 |
model=model,
|
| 123 |
+
tools=[final_answer,tool_calculator,answer_nfl_question_tool], ## add your tools here (don't remove final answer)
|
| 124 |
max_steps=6,
|
| 125 |
verbosity_level=1,
|
| 126 |
grammar=None,
|