Gas96 commited on
Commit
a657532
·
verified ·
1 Parent(s): d1abb3b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -7,6 +7,7 @@ from tools.visit_webpage import VisitWebpageTool
7
  from tools.final_answer import FinalAnswerTool
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 get_current_time_in_timezone(timezone: str) -> str:
@@ -26,7 +27,7 @@ def get_current_time_in_timezone(timezone: str) -> str:
26
 
27
  #Following my creation.
28
  @tool
29
- def get_fun_fact(topic: str) -> str:
30
  """Finds an URL where I can read news about a given topic using DuckDuckGo.
31
  Args:
32
  topic: The topic to search for news.
@@ -64,7 +65,7 @@ with open("prompts.yaml", 'r') as stream:
64
 
65
  agent = CodeAgent(
66
  model=model,
67
- tools=[get_fun_fact, final_answer], ## add your tools here (don't remove final answer)
68
  max_steps=6,
69
  verbosity_level=1,
70
  grammar=None,
 
7
  from tools.final_answer import FinalAnswerTool
8
  from Gradio_UI import GradioUI
9
 
10
+ visit_web_page=VisitWebpageTool()
11
  # Below is an example of a tool that does nothing. Amaze us with your creativity !
12
  @tool
13
  def get_current_time_in_timezone(timezone: str) -> str:
 
27
 
28
  #Following my creation.
29
  @tool
30
+ def get_news(topic: str) -> str:
31
  """Finds an URL where I can read news about a given topic using DuckDuckGo.
32
  Args:
33
  topic: The topic to search for news.
 
65
 
66
  agent = CodeAgent(
67
  model=model,
68
+ tools=[get_news, final_answer, visit_web_page], ## add your tools here (don't remove final answer)
69
  max_steps=6,
70
  verbosity_level=1,
71
  grammar=None,