Closed Omotade-MY closed 4 months ago
Just set yield_messages=False
in get_completion method
This issue is stale because it has been open for 30 days with no activity. Please upgrade to the latest version and test it again.
This issue was closed because it has been inactive for 14 days since being marked as stale. If the issue still persists, please reopen.
I tried running the example notebook on browsing agent and it worked fine. However, in the notebook the demo_gradio() method ws used to start the agent. But I want to run the agent in a script so I used the
get_completion()
method by calling on the agent instance but it keeps returning a generator object. What should I do to get the response.Below is the code I ran and the output
` def agency_agent(task): """
`task_2 = "'https://relevanceai.com/pricing/', Extract the pricing info"
`
Here is the output I got:
Files folder '/opt/anaconda3/envs/fastapis/lib/python3.10/site-packages/agency_swarm/agents/BrowsingAgent/files' is not a directory. Skipping... Schemas folder path is not a directory. Skipping... /opt/anaconda3/envs/fastapis/lib/python3.10/site-packages/agency_swarm/agents/BrowsingAgent/schemas Error parsing tool file ClickElement.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file GoBack.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file ExportFile.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file Scroll.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file ReadURL.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file SendKeys.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file WebPageSummarizer.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file SelectDropdown.py: invalid syntax (<string>, line 1). Skipping... Error parsing tool file SolveCaptcha.py: invalid syntax (<string>, line 1). Skipping... Updating agent... Report Manager Updating agent... BrowsingAgent <generator object Thread.get_completion at 0x7fc0ff97bf40>