Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -10,10 +10,16 @@ from Gradio_UI import GradioUI
|
|
| 10 |
|
| 11 |
@tool
|
| 12 |
def calculator(a: int, b: int) -> int:
|
| 13 |
-
"Multiply two intergers.
|
| 14 |
-
|
| 15 |
-
|
|
|
|
| 16 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 17 |
print(calculator.to_string())
|
| 18 |
|
| 19 |
@tool
|
|
@@ -57,7 +63,7 @@ from tools.final_answer import FinalAnswerTool
|
|
| 57 |
from smolagents import load_tool
|
| 58 |
|
| 59 |
tool_registry = {
|
| 60 |
-
"
|
| 61 |
"tool": calculator,
|
| 62 |
"schema": calculator_tool_schema(),
|
| 63 |
"enabled": True
|
|
|
|
| 10 |
|
| 11 |
@tool
|
| 12 |
def calculator(a: int, b: int) -> int:
|
| 13 |
+
"""Multiply two intergers.
|
| 14 |
+
Args:
|
| 15 |
+
a (int): First number
|
| 16 |
+
b (int): Second number
|
| 17 |
|
| 18 |
+
Returns:
|
| 19 |
+
int: The product of a and b
|
| 20 |
+
"""
|
| 21 |
+
return a * b
|
| 22 |
+
|
| 23 |
print(calculator.to_string())
|
| 24 |
|
| 25 |
@tool
|
|
|
|
| 63 |
from smolagents import load_tool
|
| 64 |
|
| 65 |
tool_registry = {
|
| 66 |
+
"calculator": {
|
| 67 |
"tool": calculator,
|
| 68 |
"schema": calculator_tool_schema(),
|
| 69 |
"enabled": True
|