microsoft / autogen

A programming framework for agentic AI. Discord: https://aka.ms/autogen-dc. Roadmap: https://aka.ms/autogen-roadmap
https://microsoft.github.io/autogen/
Creative Commons Attribution 4.0 International
27.96k stars 4.08k forks source link

[Issue]: Question regarding agent behavior: is the User Proxy the only agent that can run functions? #3023

Open tyler-suard-parker opened 5 days ago

tyler-suard-parker commented 5 days ago

Describe the issue

I currently have my group chat set up like this:

UserProxy Search Agent 1 Search Agent 2 Search Agent 3

I have given each Search Agent specific instructions to perform a search on its own, and I have given each search agent access to a different search function. Instead of performing searches, each search agent suggests to the UserProxy which search function to run. The UserProxy of course does not have access to those search functions, so I get an error. What is going on here? How can I get my Search Agents to actually execute a search function, instead of suggesting to the UserProxy a function to call?

Steps to reproduce

Define one user proxy and one assistant agent. Allow the assistant agent to access a search function. Send a message from the user proxy to the assistant agent, telling it to search. Instead of searching, the assistant agent will send back a suggestion for the user proxy to call a function.

My code is somewhat similar to Example 1 here:

https://github.com/microsoft/autogen/blob/1582927ccd4de493be0d406ce59cb9cae729ed04/notebook/agentchats_sequential_chats.ipynb#L113

Screenshots and logs

No response

Additional Information

No response

Hk669 commented 5 days ago

the UserProxyAgent or you can use the conversableAgent that can run the functions, but any agent can use the tool call. here are the ref: https://microsoft.github.io/autogen/docs/tutorial/tool-use/

LittleLittleCloud commented 4 days ago

@Hk669 can you confirm that the user proxy is the only agent that can run a tool call? FWIW you can register the tool call executor with any conversable agent

Hk669 commented 4 days ago

Yeah, I meant the same. Thanks for the clarification @LittleLittleCloud , I think the shared resource with the above comment navigates to the tool use.