Agent Architecture Design
Overview
Guide the selection and design of the correct agentic architecture by diagnosing the problem type, mapping it to a proven design pattern, and defining the workflow structure, tooling, and management model.
Process
Phase 1: Problem Diagnosis
Categorize the request on two axes:
|
Task-Level (single job) |
Project-Level (coordination needed) |
| Software-Shaped (working code/system) |
Single-Agent Iterative Loop |
Autonomous Pipeline or Multi-Agent System |
| Metric-Shaped (optimize a number) |
Optimization Loop |
Optimization Loop + Multi-Agent System |
Diagnosis questions:
- Is the goal working software or optimizing a metric?
- Is this a single discrete task or multiple coordinated parts?
- How much human involvement is acceptable during execution?
- What scale justifies the architecture complexity?
Phase 2: Pattern Selection
Load references/agentic-design-patterns.md for full details on each pattern. Summary:
Single-Agent Iterative Loop (Agentic IDE)
- Human = manager, Agent = worker
- Decompose the problem into small chunks (UI, API, tests)
- Agent gets a workspace (terminal, files, search)
- Best for: individual developer productivity on discrete tasks
Autonomous Pipeline (Zero-Human Loop)
- Spec In → Autonomous Zone → Eval Out
- Heavy human involvement at start (specs) and end (review), zero in the middle
- Requires robust evals — iterations happen automatically until eval passes
- Best for: zero-human-intervention software delivery
Optimization Loop (Self-Improving Agent)
- Hill climbing against a specific metric
- Agent tries paths, fails, backtracks
- Needs a clear optimization target
- Best for: reaching peak of an optimization metric through experimentation
Multi-Agent System (Hierarchical/Supervisor Pattern)
- Specialized roles with defined handoffs (Researcher → Writer → Editor → Publisher)
- Complexity lies in context management between agents
- Only justified at scale (10,000 tickets, not 10)
- Best for: seamless coordination across specialized AI workers
Phase 3: Workflow Architecture
After selecting a pattern, define the workflow structure. Load references/workflow-patterns.md for framework-specific patterns.
For each pattern, define:
- Phases — What sequential or parallel steps does the workflow execute?
- Artifacts — What does each phase produce? (specs, designs, tasks, code, reports)
- Gates — What must be true before proceeding to the next phase?
- Tooling — What tools/MCPs does each agent need?
- Context flow — How is information passed between phases/agents?
- Resumption — How does the workflow recover from interruption?
Pattern → Workflow mapping:
| Agentic Design Pattern |
Typical Workflow |
| Single-Agent Iterative Loop |
Single-phase: decompose → implement → verify |
| Autonomous Pipeline |
OpenSpec-style: validate → propose → design → implement → verify |
| Optimization Loop |
Iteration loop: hypothesize → test → measure → backtrack/advance |
| Multi-Agent System |
Role pipeline: role₁ → handoff → role₂ → handoff → roleₙ |
Phase 4: Output
Produce a design document covering:
- Diagnosis — Software or metric shaped, task or project level
- Recommended Pattern — Which agentic architecture and why
- Workflow Design — Phases, artifacts, gates, context flow
- Scaffolding Plan — Tools, MCPs, evals the agent needs
- Management Model — Human role (Manager, Observer, or Spec-Writer)
Implementation Rules
- Simple scales better — Do not recommend 3-level management if 2-level works. Simple configurations are more performant.
- Context is everything — Agents depend entirely on the context and scaffolding provided by the architect. Design the scaffolding, not just the agent.
- Human-centered → Agent-centered — For large projects, move from "human managing every agent" to "planner agent managing sub-agents" where the human observes.
- Avoid pattern-confusion — Never use an Optimization Loop to build a novel. Never use a Single-Agent Loop for a project requiring specialized multi-agent orchestration.
- Scale justifies complexity — Multi-agent orchestration is only worth it at scale. For small problems, a single well-prompted agent outperforms a complex framework.
Skill Resources
references/agentic-design-patterns.md — Detailed pattern descriptions with examples and anti-patterns
references/workflow-patterns.md — Workflow patterns from OpenSpec, Superpowers, and Compound Engineering
Related Skills
- agent-plugin-review — Review an implemented plugin against architecture best practices
1---2name: agent-architecture-design3description: Use when designing an AI agent system, selecting agentic design patterns, planning multi-phase workflows, choosing between single-agent and multi-agent architectures, or when asked "what kind of agent should I build", "how should I structure this automation", "design an agent for X", or "which agentic pattern fits this problem".4---56# Agent Architecture Design78## Overview910Guide the selection and design of the correct agentic architecture by diagnosing the problem type, mapping it to a proven design pattern, and defining the workflow structure, tooling, and management model.1112## Process1314### Phase 1: Problem Diagnosis1516Categorize the request on two axes:1718| | Task-Level (single job) | Project-Level (coordination needed) |19|---|---|---|20| **Software-Shaped** (working code/system) | Single-Agent Iterative Loop | Autonomous Pipeline or Multi-Agent System |21| **Metric-Shaped** (optimize a number) | Optimization Loop | Optimization Loop + Multi-Agent System |2223**Diagnosis questions:**241. Is the goal working software or optimizing a metric?252. Is this a single discrete task or multiple coordinated parts?263. How much human involvement is acceptable during execution?274. What scale justifies the architecture complexity?2829### Phase 2: Pattern Selection3031Load `references/agentic-design-patterns.md` for full details on each pattern. Summary:3233**Single-Agent Iterative Loop** (Agentic IDE)34- Human = manager, Agent = worker35- Decompose the problem into small chunks (UI, API, tests)36- Agent gets a workspace (terminal, files, search)37- Best for: individual developer productivity on discrete tasks3839**Autonomous Pipeline** (Zero-Human Loop)40- Spec In → Autonomous Zone → Eval Out41- Heavy human involvement at start (specs) and end (review), zero in the middle42- Requires robust evals — iterations happen automatically until eval passes43- Best for: zero-human-intervention software delivery4445**Optimization Loop** (Self-Improving Agent)46- Hill climbing against a specific metric47- Agent tries paths, fails, backtracks48- Needs a clear optimization target49- Best for: reaching peak of an optimization metric through experimentation5051**Multi-Agent System** (Hierarchical/Supervisor Pattern)52- Specialized roles with defined handoffs (Researcher → Writer → Editor → Publisher)53- Complexity lies in context management between agents54- Only justified at scale (10,000 tickets, not 10)55- Best for: seamless coordination across specialized AI workers5657### Phase 3: Workflow Architecture5859After selecting a pattern, define the workflow structure. Load `references/workflow-patterns.md` for framework-specific patterns.6061**For each pattern, define:**62631. **Phases** — What sequential or parallel steps does the workflow execute?642. **Artifacts** — What does each phase produce? (specs, designs, tasks, code, reports)653. **Gates** — What must be true before proceeding to the next phase?664. **Tooling** — What tools/MCPs does each agent need?675. **Context flow** — How is information passed between phases/agents?686. **Resumption** — How does the workflow recover from interruption?6970**Pattern → Workflow mapping:**7172| Agentic Design Pattern | Typical Workflow |73|---|---|74| Single-Agent Iterative Loop | Single-phase: decompose → implement → verify |75| Autonomous Pipeline | OpenSpec-style: validate → propose → design → implement → verify |76| Optimization Loop | Iteration loop: hypothesize → test → measure → backtrack/advance |77| Multi-Agent System | Role pipeline: role₁ → handoff → role₂ → handoff → roleₙ |7879### Phase 4: Output8081Produce a design document covering:82831. **Diagnosis** — Software or metric shaped, task or project level842. **Recommended Pattern** — Which agentic architecture and why853. **Workflow Design** — Phases, artifacts, gates, context flow864. **Scaffolding Plan** — Tools, MCPs, evals the agent needs875. **Management Model** — Human role (Manager, Observer, or Spec-Writer)8889## Implementation Rules90911. **Simple scales better** — Do not recommend 3-level management if 2-level works. Simple configurations are more performant.922. **Context is everything** — Agents depend entirely on the context and scaffolding provided by the architect. Design the scaffolding, not just the agent.933. **Human-centered → Agent-centered** — For large projects, move from "human managing every agent" to "planner agent managing sub-agents" where the human observes.944. **Avoid pattern-confusion** — Never use an Optimization Loop to build a novel. Never use a Single-Agent Loop for a project requiring specialized multi-agent orchestration.955. **Scale justifies complexity** — Multi-agent orchestration is only worth it at scale. For small problems, a single well-prompted agent outperforms a complex framework.9697## Skill Resources9899- `references/agentic-design-patterns.md` — Detailed pattern descriptions with examples and anti-patterns100- `references/workflow-patterns.md` — Workflow patterns from OpenSpec, Superpowers, and Compound Engineering101102## Related Skills103104- **agent-plugin-review** — Review an implemented plugin against architecture best practices