RemVdH commited on
Commit
bb4c5c2
·
verified ·
1 Parent(s): b9335e3

Update app.py

Browse files

Changed typing to help the models to get to the right conclussion

Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -6,7 +6,7 @@ from smolagents import CodeAgent, HfApiModel, load_tool, tool
6
  import yaml
7
  import wikipedia
8
  from tools.final_answer import FinalAnswerTool
9
-
10
  from Gradio_UI import GradioUI
11
 
12
 
@@ -18,9 +18,9 @@ from Gradio_UI import GradioUI
18
  # from Gradio_UI import GradioUI
19
 
20
  @tool
21
- def search_wikipedia_pages(search_string: str) -> str:
22
  """This tool helps to search for wikipedia pages related to a search string.
23
- The output are the first 10 pages related to the search string.
24
  Args:
25
  search_string: the search string
26
  """
 
6
  import yaml
7
  import wikipedia
8
  from tools.final_answer import FinalAnswerTool
9
+ from typing import List
10
  from Gradio_UI import GradioUI
11
 
12
 
 
18
  # from Gradio_UI import GradioUI
19
 
20
  @tool
21
+ def search_wikipedia_pages(search_string: str) -> List[str]:
22
  """This tool helps to search for wikipedia pages related to a search string.
23
+ The output are the first 10 pages related to the search string in a list of strings.
24
  Args:
25
  search_string: the search string
26
  """