ravirai commited on
Commit
0fa9138
·
verified ·
1 Parent(s): b6b1153

Update app.py

Browse files

changed get_news to fetch_news
++fetch_news to tools

Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -10,7 +10,7 @@ from Gradio_UI import GradioUI
10
 
11
  # Below is an example of a tool that does nothing. Amaze us with your creativity !
12
  @tool
13
- def get_news(company:str, count:int=5)-> list: #it's import to specify the return type
14
  #Keep this format for the description / args / args description but feel free to modify the tool
15
  """A tool that gets the latest news articles for a given company.
16
  Args:
@@ -64,7 +64,7 @@ with open("prompts.yaml", 'r') as stream:
64
 
65
  agent = CodeAgent(
66
  model=model,
67
- tools=[final_answer, image_generation_tool, get_current_time_in_timezone], ## add your tools here (don't remove final answer)
68
  max_steps=6,
69
  verbosity_level=1,
70
  grammar=None,
 
10
 
11
  # Below is an example of a tool that does nothing. Amaze us with your creativity !
12
  @tool
13
+ def fetch_news(company:str, count:int=5)-> list: #it's import to specify the return type
14
  #Keep this format for the description / args / args description but feel free to modify the tool
15
  """A tool that gets the latest news articles for a given company.
16
  Args:
 
64
 
65
  agent = CodeAgent(
66
  model=model,
67
+ tools=[final_answer, fetch_news, image_generation_tool, get_current_time_in_timezone], ## add your tools here (don't remove final answer)
68
  max_steps=6,
69
  verbosity_level=1,
70
  grammar=None,