[Bug]: Documentation for agent groupchat contains bug when groupchat llm_config is used that have functions and tools registered to it #2147
Labels
documentation
Improvements or additions to documentation
Describe the Bug
https://github.com/microsoft/autogen/issues/960#issuecomment-2017254431 from the URL provided. I mentioned that the known issue of groupchat llm_config is used in the both the documentation https://microsoft.github.io/autogen/docs/notebooks/agentchat_groupchat_RAG/#construct-agents and the sample notebook 'agent_groupchat_RAG.ipynb' and easily reproduces the error of the known issue based on the outstanding issue of issues #274, #252, #960, and #152 regarding function calling in groupchats using pyautogen==0.2.2.
As stated, this is confusing to the end user trying to use the documentation and sample notebook to learn the autogen framework.
The correct behavior should be that no error is produced when the groupchat uses the llm_config and as per @ekzhu and @afourney "Don't share llm_config among different agents. You can share the config list, but LLM configs get modified as you register functions"
My solution was to copy the llm_config and pop out the function and tools registration, which worked fine for the agent groupchat when calling the 'call_rag_chat' function, but instead, both the sample and the documentation need to show separate llm_config being used for the groupchat when functions and tools are being used.
Steps to reproduce
using autogen version 0.2.20, run the sample notebook 'agent_groupchat_RAG.ipynb' and call the function 'call_rag_chat'.
Model Used
mistral 7B instruct v2
Expected Behavior
No error message should occur, if the llm_config is passed to the groupchat, there should be check that it has functions or tools registered to it, if so, create a new instance of the llm_config without the functions and tools registered and this will automatically fix it but for demonstration purposes just add another llm_config called 'llm_config_groupchat' that is associated with the config_list, that way it doesn't have any registered functions or tools with it.
Screenshots and logs
No response
Additional Information
autogen 0.2.20
ubuntu 22.04
python 3.11.1
The text was updated successfully, but these errors were encountered: