Dalageo commited on
Commit
3b319d6
·
verified ·
1 Parent(s): 2e3b5ed

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -11,13 +11,15 @@ from Gradio_UI import GradioUI
11
  @tool
12
  def calculator(expression: str)-> str: # Returns a string result
13
  """
14
- A tool that evaluates a mathematical expression using the Wolfram Alpha API.
15
 
16
  Args:
17
  expression: A mathematical expression to solve (e.g., "1+2", "3*5").
18
 
19
  Returns:
20
  str: The result of the calculation if successful, or an error message if the request fails.
 
 
21
  """
22
  try:
23
  # app_id = "replace_with_your_Wolfram_ID" # Your Wolfram Alpha App ID
 
11
  @tool
12
  def calculator(expression: str)-> str: # Returns a string result
13
  """
14
+ A tool able to solve mathematical expressions using the Wolfram Alpha API.
15
 
16
  Args:
17
  expression: A mathematical expression to solve (e.g., "1+2", "3*5").
18
 
19
  Returns:
20
  str: The result of the calculation if successful, or an error message if the request fails.
21
+
22
+ Note: The input string may contain spaces. Ensure you remove them before performing the calculation.
23
  """
24
  try:
25
  # app_id = "replace_with_your_Wolfram_ID" # Your Wolfram Alpha App ID