Hanokh commited on
Commit
76ad7de
·
verified ·
1 Parent(s): 00b1b2b

updated to use tools

Browse files
Files changed (1) hide show
  1. app.py +6 -1
app.py CHANGED
@@ -81,7 +81,12 @@ def run_and_submit_all( profile: gr.OAuthProfile | None):
81
 
82
  # 1. Instantiate Agent ( modify this part to create your agent)
83
  try:
84
- agent = BasicAgent()
 
 
 
 
 
85
  except Exception as e:
86
  print(f"Error instantiating agent: {e}")
87
  return f"Error initializing agent: {e}", None
 
81
 
82
  # 1. Instantiate Agent ( modify this part to create your agent)
83
  try:
84
+ tools = {
85
+ "math": MathTool(),
86
+ "google": GoogleSearchTool(api_key="YOUR_KEY", engine_id="YOUR_CX"),
87
+ "wiki": WikipediaTool()
88
+ }
89
+ agent = BasicAgent(tools)
90
  except Exception as e:
91
  print(f"Error instantiating agent: {e}")
92
  return f"Error initializing agent: {e}", None