bstraehle commited on
Commit
1634f29
·
verified ·
1 Parent(s): 6dd9d54

Update crew.py

Browse files
Files changed (1) hide show
  1. crew.py +17 -17
crew.py CHANGED
@@ -48,12 +48,12 @@ tracer_provider = register(
48
  def run_crew(question, file_path):
49
  # Tools
50
 
51
- #web_browser_tool = StagehandTool(
52
- # api_key=os.environ["BROWSERBASE_API_KEY"],
53
- # project_id=os.environ["BROWSERBASE_PROJECT_ID"],
54
- # model_api_key="your-llm-api-key",
55
- # model_name=AvailableModel.CLAUDE_3_7_SONNET_LATEST,
56
- #)
57
 
58
  @tool("Web Search Tool")
59
  def web_search_tool(question: str) -> str:
@@ -332,16 +332,16 @@ def run_crew(question, file_path):
332
  verbose=True
333
  )
334
 
335
- #web_browser_agent = Agent(
336
- # role="Web Browser Agent",
337
- # goal="Given a question and URL, load the URL and act, extract, navigate, observe, and answer the question: {question}",
338
- # backstory="As an expert browser assistant, you load the URL and act, extract, navigate, observe to answer the question.",
339
- # allow_delegation=False,
340
- # llm=AGENT_MODEL,
341
- # max_iter=2,
342
- # tools=[web_browser_tool],
343
- # verbose=True
344
- #)
345
 
346
  image_analysis_agent = Agent(
347
  role="Image Analysis Agent",
@@ -466,7 +466,7 @@ def run_crew(question, file_path):
466
 
467
  crew = Crew(
468
  agents=[web_search_agent,
469
- #web_browser_agent,
470
  image_analysis_agent,
471
  audio_analysis_agent,
472
  video_analysis_agent,
 
48
  def run_crew(question, file_path):
49
  # Tools
50
 
51
+ web_browser_tool = StagehandTool(
52
+ api_key=os.environ["BROWSERBASE_API_KEY"],
53
+ project_id=os.environ["BROWSERBASE_PROJECT_ID"],
54
+ model_api_key="your-llm-api-key",
55
+ model_name=AvailableModel.CLAUDE_3_7_SONNET_LATEST,
56
+ )
57
 
58
  @tool("Web Search Tool")
59
  def web_search_tool(question: str) -> str:
 
332
  verbose=True
333
  )
334
 
335
+ web_browser_agent = Agent(
336
+ role="Web Browser Agent",
337
+ goal="Given a question and URL, load the URL and act, extract, navigate, observe, and answer the question: {question}",
338
+ backstory="As an expert browser assistant, you load the URL and act, extract, navigate, observe to answer the question.",
339
+ allow_delegation=False,
340
+ llm=AGENT_MODEL,
341
+ max_iter=2,
342
+ tools=[web_browser_tool],
343
+ verbose=True
344
+ )
345
 
346
  image_analysis_agent = Agent(
347
  role="Image Analysis Agent",
 
466
 
467
  crew = Crew(
468
  agents=[web_search_agent,
469
+ web_browser_agent,
470
  image_analysis_agent,
471
  audio_analysis_agent,
472
  video_analysis_agent,