The coordinator-subagent pattern: the foundation every Claude multi-agent system is built on
Coordinator receives task, delegates to specialists via tool calls Each subagent gets its own isolated context window and system prompt Subagents cannot talk to each other — everything routes throu...

Source: DEV Community
Coordinator receives task, delegates to specialists via tool calls Each subagent gets its own isolated context window and system prompt Subagents cannot talk to each other — everything routes through coordinator Same stopReason loop as single-agent, tool calls just dispatch to separate API calls 3–4x token cost vs single agent — only use when specialist quality justifies it Pattern 1 — Coordinator-subagent (pure API) User Request ↓ Coordinator Agent ←── stopReason: tool_use ↓ Route to specialist ↓ ┌──────────────────────────────────┐ │ research_agent │ writer_agent │ ← Each: isolated context, │ reviewer_agent │ any_specialist │ own system prompt, own tools └──────────────────────────────────┘ ↓ Tool result back to coordinator ↓ stopReason: end_turn → return answer pythonimport boto3 client = boto3.client("bedrock-runtime", region_name="us-east-1") subagent_tools = [ { "toolSpec": { "name": "research_agent", "description": "Research specialist. Use for finding and analyzing information.