Agents
Subagents for isolated, complex workflows
Agents (~/.claude/agents/*.md) are specialized subagents that run in their own context window — separate from the main conversation. They were the original approach to complex multi-step tasks before skills matured.
In practice, agents have been largely superseded by skills and direct work in the main conversation. Skills load into your existing context (preserving all accumulated understanding), while agents start fresh in isolation. The main use case for agents now is when you genuinely need isolation — long-running tasks that might pollute the main conversation, or parallel work streams.
Available Agents
Agents vs. Skills vs. Commands
| Dimension | Commands | Skills | Agents |
|---|---|---|---|
| Invocation | Explicit (/command) | Automatic (keyword match) | Explicit or automatic |
| Context | Same conversation | Same conversation | Separate context window |
| State | Shares all context | Shares all context | Starts fresh |
| Best for | Specific workflows | Domain capabilities | Isolated heavy work |
| Location | ~/.claude/commands/ | ~/.claude/skills/*/ | ~/.claude/agents/ |
The evolution from agents to skills to direct work mirrors the broader pattern: a simpler abstraction beats a heavier one. Agents are powerful but heavyweight. Skills are lighter, composable, and share context. Often the best approach is no abstraction at all — just give Claude the context directly and let it work.