hamsomp3 commited on
Commit
b0ed282
·
verified ·
1 Parent(s): 723403f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -4,6 +4,7 @@ import requests
4
  import pytz
5
  import yaml
6
  from tools.final_answer import FinalAnswerTool
 
7
 
8
  from Gradio_UI import GradioUI
9
 
@@ -48,6 +49,8 @@ def get_current_time_in_timezone(timezone: str) -> str:
48
 
49
 
50
  final_answer = FinalAnswerTool()
 
 
51
 
52
  # If the agent does not answer, the model is overloaded, please use another model or the following Hugging Face Endpoint that also contains qwen2.5 coder:
53
  # model_id='https://pflgm2locj2t89co.us-east-1.aws.endpoints.huggingface.cloud'
@@ -68,7 +71,7 @@ with open("prompts.yaml", 'r') as stream:
68
 
69
  agent = CodeAgent(
70
  model=model,
71
- tools=[final_answer, get_web_search], ## add your tools here (don't remove final answer)
72
  max_steps=6,
73
  verbosity_level=1,
74
  grammar=None,
 
4
  import pytz
5
  import yaml
6
  from tools.final_answer import FinalAnswerTool
7
+ from tools.visit_webpage import VisitWebpageTool
8
 
9
  from Gradio_UI import GradioUI
10
 
 
49
 
50
 
51
  final_answer = FinalAnswerTool()
52
+ visit_web_page = VisitWebpageTool()
53
+ get_web_search = DuckDuckGoSearchTool()
54
 
55
  # If the agent does not answer, the model is overloaded, please use another model or the following Hugging Face Endpoint that also contains qwen2.5 coder:
56
  # model_id='https://pflgm2locj2t89co.us-east-1.aws.endpoints.huggingface.cloud'
 
71
 
72
  agent = CodeAgent(
73
  model=model,
74
+ tools=[final_answer, get_web_search,get_current_time_in_timezone,visit_web_page], ## add your tools here (don't remove final answer)
75
  max_steps=6,
76
  verbosity_level=1,
77
  grammar=None,