Spaces:
Sleeping
Sleeping
feat: add adder
Browse files
app.py
CHANGED
|
@@ -8,18 +8,15 @@ from Gradio_UI import GradioUI
|
|
| 8 |
from tools.final_answer import FinalAnswerTool
|
| 9 |
|
| 10 |
|
| 11 |
-
# Below is an example of a tool that does nothing. Amaze us with your creativity !
|
| 12 |
@tool
|
| 13 |
-
def
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
# Keep this format for the description / args / args description but feel free to modify the tool
|
| 17 |
-
"""A tool that does nothing yet
|
| 18 |
Args:
|
| 19 |
-
|
| 20 |
-
|
| 21 |
"""
|
| 22 |
-
return
|
| 23 |
|
| 24 |
|
| 25 |
@tool
|
|
@@ -61,7 +58,7 @@ tools = [
|
|
| 61 |
|
| 62 |
agent = CodeAgent(
|
| 63 |
model=model,
|
| 64 |
-
tools=tools,
|
| 65 |
max_steps=6,
|
| 66 |
verbosity_level=1,
|
| 67 |
grammar=None,
|
|
|
|
| 8 |
from tools.final_answer import FinalAnswerTool
|
| 9 |
|
| 10 |
|
|
|
|
| 11 |
@tool
|
| 12 |
+
def add_two_numbers(num_1: int, num_2: int) -> str:
|
| 13 |
+
"""A tool that adds two numbers together.
|
| 14 |
+
|
|
|
|
|
|
|
| 15 |
Args:
|
| 16 |
+
num_1: the first number.
|
| 17 |
+
num_2: the second number.
|
| 18 |
"""
|
| 19 |
+
return str(num_1 + num_2)
|
| 20 |
|
| 21 |
|
| 22 |
@tool
|
|
|
|
| 58 |
|
| 59 |
agent = CodeAgent(
|
| 60 |
model=model,
|
| 61 |
+
tools=tools,
|
| 62 |
max_steps=6,
|
| 63 |
verbosity_level=1,
|
| 64 |
grammar=None,
|