AgentChat Workflows
Use this sub-skill when working on existing AutoGen Python applications built with autogen_agentchat. AutoGen is in maintenance mode: recommend Microsoft Agent Framework for greenfield work, but use this guidance to support existing AutoGen maintenance, debugging, migration, and usage.
Route Here
Use this sub-skill for:
AssistantAgent, UserProxyAgent, CodeExecutorAgent, and high-level chat agent behavior.
- Team workflows with
RoundRobinGroupChat, SelectorGroupChat, Swarm, MagenticOneGroupChat, nested teams, and tools-as-agents.
TextMentionTermination, MaxMessageTermination, HandoffTermination, streaming with run_stream, Console, save/load state, and component serialization.
- Migration of v0.2-style
autogen.agentchat code to the 0.4+ layered autogen_agentchat APIs used by 0.7.x.
Route elsewhere when the user needs:
- Low-level routed agents, topics, message handlers, subscriptions, or custom runtime internals:
../core-runtime/SKILL.md.
- Concrete model clients, MCP, Docker/Jupyter/local executors, memory providers, caches, or optional provider extras:
../extensions-integrations/SKILL.md.
- AutoGen Studio, AG Bench, Magentic-One CLI,
pyautogen, or package version-boundary decisions: ../tools-studio-bench/SKILL.md.
Start Safely
- Confirm the package family and version boundary. Current AgentChat maintenance work generally targets
autogen-agentchat 0.7.x, not legacy pyautogen 0.2 APIs.
- Avoid provider calls while inspecting or debugging structure. Use replay/mock clients, constructor inspection, and bounded teams first.
- Always add
termination_condition and/or max_turns to teams unless the surrounding app has a verified stop mechanism.
- Treat agents and teams as stateful. Do not pass full history back into
run, run_stream, on_messages, or on_messages_stream on every call.
- Close or clean up concrete model clients, workbenches, and executors according to their integration-specific requirements.
Common References
- API constructors and important kwargs:
references/api-reference.md.
- Design patterns for agents, teams, tools, streaming, and no-provider testing:
references/workflows.md.
- v0.2 migration plus state and serialization guidance:
references/migration-and-state.md.
- Failure diagnosis and fixes:
references/troubleshooting.md.
- Safe smoke inspection script:
scripts/agentchat_smoke.py.
Minimal Safe Checks
Run signature-only checks without model credentials:
python scripts/agentchat_smoke.py --mode signatures
If imports fail, install or expose compatible autogen-agentchat, autogen-core, and autogen-ext packages before running application-level checks. Do not solve provider credential failures in this sub-skill; route model-client setup to ../extensions-integrations/SKILL.md.
1---2name: agentchat-workflows3description: "Maintain, debug, migrate, and write high-level AutoGen AgentChat4 applications using agents, teams, tools-as-agents, termination, handoffs,5 streaming, state, and serialization."6disable-model-invocation: true7metadata:8 source: https://skillmd.com/skills/vectorspacelab/agentchat-workflows9 disco-role: operating10license: NOASSERTION11---1213# AgentChat Workflows1415Use this sub-skill when working on existing AutoGen Python applications built with `autogen_agentchat`. AutoGen is in maintenance mode: recommend Microsoft Agent Framework for greenfield work, but use this guidance to support existing AutoGen maintenance, debugging, migration, and usage.1617## Route Here1819Use this sub-skill for:20- `AssistantAgent`, `UserProxyAgent`, `CodeExecutorAgent`, and high-level chat agent behavior.21- Team workflows with `RoundRobinGroupChat`, `SelectorGroupChat`, `Swarm`, `MagenticOneGroupChat`, nested teams, and tools-as-agents.22- `TextMentionTermination`, `MaxMessageTermination`, `HandoffTermination`, streaming with `run_stream`, `Console`, save/load state, and component serialization.23- Migration of v0.2-style `autogen.agentchat` code to the 0.4+ layered `autogen_agentchat` APIs used by 0.7.x.2425Route elsewhere when the user needs:26- Low-level routed agents, topics, message handlers, subscriptions, or custom runtime internals: `../core-runtime/SKILL.md`.27- Concrete model clients, MCP, Docker/Jupyter/local executors, memory providers, caches, or optional provider extras: `../extensions-integrations/SKILL.md`.28- AutoGen Studio, AG Bench, Magentic-One CLI, `pyautogen`, or package version-boundary decisions: `../tools-studio-bench/SKILL.md`.2930## Start Safely31321. Confirm the package family and version boundary. Current AgentChat maintenance work generally targets `autogen-agentchat` 0.7.x, not legacy `pyautogen` 0.2 APIs.332. Avoid provider calls while inspecting or debugging structure. Use replay/mock clients, constructor inspection, and bounded teams first.343. Always add `termination_condition` and/or `max_turns` to teams unless the surrounding app has a verified stop mechanism.354. Treat agents and teams as stateful. Do not pass full history back into `run`, `run_stream`, `on_messages`, or `on_messages_stream` on every call.365. Close or clean up concrete model clients, workbenches, and executors according to their integration-specific requirements.3738## Common References3940- API constructors and important kwargs: `references/api-reference.md`.41- Design patterns for agents, teams, tools, streaming, and no-provider testing: `references/workflows.md`.42- v0.2 migration plus state and serialization guidance: `references/migration-and-state.md`.43- Failure diagnosis and fixes: `references/troubleshooting.md`.44- Safe smoke inspection script: `scripts/agentchat_smoke.py`.4546## Minimal Safe Checks4748Run signature-only checks without model credentials:4950```bash51python scripts/agentchat_smoke.py --mode signatures52```5354If imports fail, install or expose compatible `autogen-agentchat`, `autogen-core`, and `autogen-ext` packages before running application-level checks. Do not solve provider credential failures in this sub-skill; route model-client setup to `../extensions-integrations/SKILL.md`.