Solution skill
Struggling with predefined functions in group chat.
Complete solution
What Microsoft AutoGen users hit in practice, with the verified fix: Struggling with predefined functions in group chat.
Struggling with predefined functions in group chat.
TL;DR
[LittleLittleCloud (maintainer)]: ## Why predefined function call doesn't work in group chat The predefined function doesn't work in group chat because in autogen, a function_call is not immediately triggered after it's being proposed. Actually, in most cases, the agent that proposes a function_call usually not to be the agent that run that function. In two-agent chat, where agents take turns to speak, the function_call can be triggered flawlessly.
Use this when you run into the situation in the title.
When not to use this skill: unrelated tasks. It covers only the procedure above.
Compatibility
The steps above apply to the commands named in them. This skill does not pin a version, so if a flag looks different on your machine, check your installed version's docs first.
Details
Because once a function_call object is generated (usually by AssistantAgent), it would be sent immediately to the other agent (usually the UserProxyAgent), which has a pre-defined trigger to run a function call if the received message contains function call. While in group chat, where a dynamic chat flow applies, the original trigger way for function_call doesn't w
Context: GitHub issue microsoft/autogen#152 (closed, 22 comments): I want to have LLM's access to predefined functions. I've written those functions, and it works when there's no group chat. `llmconfig = { "functions": [ { "name": "writetofile", "description": "Use this function to write content to a file", "parameters": { "type": "object", "properties": { "filename": { "type": "string", "description": "The filename to write to", }, "content": { "type": "string", "description": "The content to write", } }, "required": ["filename", "content"], }, }, { "name": "readfrom_file", "description": "Use this function to read the content of a file", "parameters": {
Evidence
GitHub issue microsoft/autogen#152 (closed, 22 comments): I want to have LLM's access to predefined functions. I've written those functions, and it works when there's no group chat. llm_config = { "functions": [ { "name": "write_to_file", "description": "Use this function to write content to a file", "parameters": { "type": "object", "properties": { "filename": { "type": "string", "description": "The filename to write to", }, "content": { "type": "string", "description": "The content to write", } }, "required": ["filename", "content"], }, }, { "name": "read_from_file", "description": "Use this function to read the content of a file", "parameters": { Resolved: [LittleLittleCloud (maintainer)]: ## Why predefined function call doesn't work in group chat The predefined function doesn't work in group chat because in autogen, a functioncall is not immediately triggered after it's being proposed. Actually, in most cases, the agent that proposes a functioncall usually not to be the agent that run that function. In two-agent chat, where agents take turns to speak, the functioncall can be triggered flawlessly. Because once a functioncall object is generated (usually by AssistantAgent), it would be sent immediately to the other agent (usually the UserProxyAgent), which has a pre-defined trigger to run a function call if the received message contains function call. While in group chat, where a dynamic chat flow applies, the original trigger way for function_call` doesn't w
By @issueatlas · Version 2 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_gUBYy_P-SW-Tq9T4y3I3Tw" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Struggling with predefined functions in group chat. <span>— Vectle</span></a>