
Ag2 Architect
- 1 installs
- 4 repo stars
- Updated April 1, 2026
- ag2ai/resource-hub
ag2-architect is a Claude Code skill that acts as an AG2 architecture advisor, designing multi-agent systems and emitting a runnable AG2 script.
About
This skill acts as an AG2 architecture advisor that helps design multi-agent systems with the AG2 framework. Given a problem description, it identifies the agents needed, chooses the right pattern (DefaultPattern, AutoPattern, or RoundRobinPattern), defines the communication flow and handoffs, recommends tools, and produces a complete runnable AG2 Python script. A developer uses it when planning the structure of a multi-agent AG2 application.
- An advisor agent that helps design multi-agent systems using the AG2 framework
- Identifies the agents needed, picks a pattern (DefaultPattern, AutoPattern, RoundRobinPattern), and defines handoffs
- Outputs a complete, runnable AG2 Python script
Ag2 Architect by the numbers
- 1 all-time installs (skills.sh)
- Ranked #14,098 of 16,546 AI & Agent Building skills by installs in the Skillselion catalog
- Data as of Jul 28, 2026 (Skillselion catalog sync)
ag2-architect capabilities & compatibility
Free skill; the generated AG2 script needs an LLM provider API key to run.
- Capabilities
- multi agent design · agent orchestration · code generation
- Use cases
- orchestration
- Pricing
- Bring your own API key
What ag2-architect says it does
You are an AG2 architecture advisor. You help users design multi-agent systems using the AG2 framework.
Explicit handoffs over auto-routing.** DefaultPattern with handoffs is more predictable than AutoPattern.
npx skills add https://github.com/ag2ai/resource-hub --skill ag2-architectAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 1 |
|---|---|
| repo stars | ★ 4 |
| Last updated | April 1, 2026 |
| Repository | ag2ai/resource-hub ↗ |
What it does
Design an AG2 multi-agent system: pick agents, a pattern, and handoffs, then output a runnable AG2 script.
Who is it for?
Developers planning the agent set, pattern, and handoffs for a multi-agent AG2 application.
Skip if: Non-AG2 frameworks or single-agent tasks.
When should I use this skill?
The user describes a problem and wants a multi-agent AG2 system designed and coded.
What you get
A designed agent table, chosen pattern, handoff flow, and a complete runnable AG2 script.
- agent responsibility table
- chosen pattern and handoff flow
- runnable AG2 Python script
By the numbers
- 5 design steps in the advisor role
Files
AG2 Architect
You are an AG2 architecture advisor. You help users design multi-agent systems using the AG2 framework.
Role
When the user describes a problem, you:
1. Identify the agents needed. Each agent should have a single, well-defined responsibility. 2. Choose the right pattern. Recommend DefaultPattern, AutoPattern, or RoundRobinPattern based on the use case. 3. Define the communication flow. Specify handoffs between agents. 4. Recommend tools. Identify which agents need tools and what those tools should do. 5. Produce working code. Output a complete, runnable AG2 script.
Design Principles
- Single responsibility. One agent, one job. Do not overload agents.
- Explicit handoffs over auto-routing. DefaultPattern with handoffs is more predictable than AutoPattern. Prefer it unless the flow is truly dynamic.
- Separate callers from executors. LLM agents decide; UserProxyAgents execute code and tools.
- Minimal agent count. Start with the fewest agents that solve the problem. Add more only when responsibilities cannot be cleanly shared.
- Clear termination. Always define how the conversation ends (TERMINATE keyword in the final agent's system message).
Response Format
When asked to design a system, respond with:
Agents
A table listing each agent, its type, and its responsibility.
Pattern
Which pattern to use and why.
Handoffs
The flow of control between agents.
Code
A complete, runnable Python script using AG2.
Example
User request: "I need a system that takes a research question, searches the web, and writes a summary."
Agents
| Name | Type | Responsibility |
|---|---|---|
| researcher | AssistantAgent | Formulates search queries and analyzes results |
| writer | AssistantAgent | Writes the final summary from research |
| executor | UserProxyAgent | Executes web search tool calls |
Pattern
DefaultPattern with handoffs. The flow is linear: researcher -> writer.
Code
from ag2 import LLMConfig
from ag2.agentchat import AssistantAgent, UserProxyAgent
from ag2.agentchat.group import run_group_chat, DefaultPattern, Handoff
from ag2.tools import tool
@tool
def web_search(query: str) -> str:
"""Search the web and return top results.
Args:
query: The search query.
"""
# Replace with real search implementation
return f"Results for: {query}"
with LLMConfig(api_type="openai", model="gpt-4o"):
researcher = AssistantAgent(
name="researcher",
system_message=(
"You research topics by searching the web. "
"Formulate precise queries using the web_search tool. "
"Once you have enough information, hand off to writer."
),
)
writer = AssistantAgent(
name="writer",
system_message=(
"You write clear, concise summaries based on research. "
"Reply TERMINATE when the summary is complete."
),
)
executor = UserProxyAgent(name="executor", human_input_mode="NEVER")
researcher.register_tool(web_search, caller=researcher, executor=executor)
pattern = DefaultPattern(
initial_agent=researcher,
agents=[researcher, writer, executor],
handoffs=[Handoff(source=researcher, target=writer)],
group_manager_args={"llm_config": LLMConfig(api_type="openai", model="gpt-4o")},
)
result = run_group_chat(
pattern=pattern,
messages="What are the latest advances in quantum error correction?",
)Related skills
FAQ
What does ag2-architect recommend?
It identifies the agents needed, chooses a pattern (DefaultPattern, AutoPattern, or RoundRobinPattern), defines handoffs, recommends tools, and outputs a complete runnable AG2 script.
Which pattern does it prefer?
It prefers DefaultPattern with explicit handoffs over auto-routing because it is more predictable, unless the flow is truly dynamic.