Spaces:
Runtime error
Runtime error
Using simpy
Browse filesAll is in the title
app.py
CHANGED
|
@@ -7,10 +7,9 @@ from tools.final_answer import FinalAnswerTool
|
|
| 7 |
|
| 8 |
from Gradio_UI import GradioUI
|
| 9 |
|
| 10 |
-
# Below is an example of a tool that does nothing. Amaze us with your creativity !
|
| 11 |
@tool
|
| 12 |
def simplify_expression(arg1:str)-> str:
|
| 13 |
-
"""A tool
|
| 14 |
Args:
|
| 15 |
arg1: the mathematical expression
|
| 16 |
"""
|
|
@@ -24,7 +23,6 @@ def simplify_expression(arg1:str)-> str:
|
|
| 24 |
factored_expression = sp.factor(simplified_expression)
|
| 25 |
# Générer LaTeX output (best rendered in md)
|
| 26 |
latex_code = sp.latex(factored_expression)
|
| 27 |
-
|
| 28 |
return latex_code
|
| 29 |
except Exception as e:
|
| 30 |
return f"Ouch, is that a valid math expression : {e}"
|
|
|
|
| 7 |
|
| 8 |
from Gradio_UI import GradioUI
|
| 9 |
|
|
|
|
| 10 |
@tool
|
| 11 |
def simplify_expression(arg1:str)-> str:
|
| 12 |
+
"""A tool that simplify mathematical expression with x and y variables
|
| 13 |
Args:
|
| 14 |
arg1: the mathematical expression
|
| 15 |
"""
|
|
|
|
| 23 |
factored_expression = sp.factor(simplified_expression)
|
| 24 |
# Générer LaTeX output (best rendered in md)
|
| 25 |
latex_code = sp.latex(factored_expression)
|
|
|
|
| 26 |
return latex_code
|
| 27 |
except Exception as e:
|
| 28 |
return f"Ouch, is that a valid math expression : {e}"
|