It routes to four references depending on the task: patterns.md for architecture choice (Single Agent, Orchestrator, Pipeline, Network, Supervisor, Hierarchical, Meta-Prompting), workflows.md for implementing APEX/TDD/Explore-Plan-Code/Review/Debug patterns inside an agent, templates.md for the full production frontmatter and Claude Code agent template, and anti-patterns.md for reviewing a design against common mistakes.
Agent Design
Skill for designing high-performance AI agents following 2025 patterns.
References
- patterns.md - Load when: choosing an agent architecture (Single Agent, Agent+Tools, Orchestrator, Pipeline, Network, Supervisor, Hierarchical, Meta-Prompting) or comparing their trade-offs
- workflows.md - Load when: implementing APEX, TDD, Explore-Plan-Code, Code Review, or Debugging workflows for an agent
- templates.md - Load when: writing a full agent definition (production frontmatter + sections) or a Claude Code agent template
- anti-patterns.md - Load when: reviewing an agent design for common mistakes (omniscient agent, implicit instructions, missing error handling)
Fundamental Distinction
Workflows vs Agents
| Type |
Control |
When to use |
| Workflow |
Code orchestrates LLM |
Predictable tasks, need for control |
| Agent |
LLM directs its actions |
Flexibility, adaptive decisions |
Golden rule: Start simple, add complexity if necessary.
Minimal Agent Structure
Agent:
identity: Who am I?
capabilities: What can I do?
tools: What tools do I have?
constraints: What are my limits?
workflow: How should I proceed?
For the complete production structure and the Claude Code agent template, see templates.md.
Fresh Eyes Principle
Key 2025 concept: Each sub-agent must have a "fresh" context.
❌ Bad: Pass entire history to each sub-agent
✅ Good: Give only necessary information
Orchestrator:
- Keeps complete history
- Extracts relevant context for each sub-agent
- Synthesizes results
Design Checklist
Before creating an agent
During design
After creation
For anti-patterns to avoid during design, see anti-patterns.md.
Forbidden
- Never create an agent without explicit workflow
- Never give access to all tools without necessity
- Never ignore the principle of least privilege
- Never forget security guardrails
1---2name: agent-design3description: "Use when choosing between workflow vs agent patterns, structuring orchestrator/subagent pipelines, or writing a Claude Code agent template."4allowed-tools: Read, Write5metadata:6 source: https://skillmd.com/skills/fusengine/agent-design7---89<objective>10Agent Design covers the architectural decisions behind building a high-performance AI agent: the workflow-vs-agent distinction (code-orchestrated vs LLM-directed control), the minimal agent structure (identity, capabilities, tools, constraints, workflow), and the "fresh eyes" principle -- each sub-agent gets only the context it needs, never the full orchestrator history.1112It routes to four references depending on the task: `patterns.md` for architecture choice (Single Agent, Orchestrator, Pipeline, Network, Supervisor, Hierarchical, Meta-Prompting), `workflows.md` for implementing APEX/TDD/Explore-Plan-Code/Review/Debug patterns inside an agent, `templates.md` for the full production frontmatter and Claude Code agent template, and `anti-patterns.md` for reviewing a design against common mistakes.13</objective>1415# Agent Design1617Skill for designing high-performance AI agents following 2025 patterns.1819## References2021- [patterns.md](references/patterns.md) - Load when: choosing an agent architecture (Single Agent, Agent+Tools, Orchestrator, Pipeline, Network, Supervisor, Hierarchical, Meta-Prompting) or comparing their trade-offs22- [workflows.md](references/workflows.md) - Load when: implementing APEX, TDD, Explore-Plan-Code, Code Review, or Debugging workflows for an agent23- [templates.md](references/templates.md) - Load when: writing a full agent definition (production frontmatter + sections) or a Claude Code agent template24- [anti-patterns.md](references/anti-patterns.md) - Load when: reviewing an agent design for common mistakes (omniscient agent, implicit instructions, missing error handling)2526## Fundamental Distinction2728### Workflows vs Agents2930| Type | Control | When to use |31|------|---------|-------------|32| **Workflow** | Code orchestrates LLM | Predictable tasks, need for control |33| **Agent** | LLM directs its actions | Flexibility, adaptive decisions |3435**Golden rule:** Start simple, add complexity if necessary.3637## Minimal Agent Structure3839```yaml40Agent:41 identity: Who am I?42 capabilities: What can I do?43 tools: What tools do I have?44 constraints: What are my limits?45 workflow: How should I proceed?46```4748For the complete production structure and the Claude Code agent template, see [templates.md](references/templates.md).4950## Fresh Eyes Principle5152**Key 2025 concept:** Each sub-agent must have a "fresh" context.5354```55❌ Bad: Pass entire history to each sub-agent56✅ Good: Give only necessary information5758Orchestrator:59 - Keeps complete history60 - Extracts relevant context for each sub-agent61 - Synthesizes results62```6364## Design Checklist6566### Before creating an agent6768- [ ] Is the objective clear?69- [ ] Would a simple workflow suffice?70- [ ] What tools are needed?71- [ ] What guardrails are required?7273### During design7475- [ ] Is identity well defined?76- [ ] Is workflow explicit?77- [ ] Are error cases handled?78- [ ] Are examples relevant?7980### After creation8182- [ ] Standard case tests?83- [ ] Edge case tests?84- [ ] Security tests (jailbreak)?85- [ ] Acceptable performance?8687For anti-patterns to avoid during design, see [anti-patterns.md](references/anti-patterns.md).8889## Forbidden9091- Never create an agent without explicit workflow92- Never give access to all tools without necessity93- Never ignore the principle of least privilege94- Never forget security guardrails