Claude Codeのエージェントを3人に分けた話 — あえて細かく分けすぎなかった理由 A practitioner's account of organizing Claude Code into just three sub-agents rather than …
- Claude Codeのサブエージェント運用において、役割を細かく分割しすぎず3体構成にとどめた事例の紹介。
- 過度な分業は文脈の分断やオーバーヘッドを招くため、粒度を抑えることで実用性を高めたという。
English summary
- A practitioner's account of organizing Claude Code into just three sub-agents rather than many specialized ones, arguing that over-fragmentation breaks context continuity and adds overhead, so a coarser split works better in practice.
AnthropicのClaude Codeでは、役割ごとにサブエージェントを定義して協調作業させる運用が広がりつつある。本記事の筆者は、自身の開発フローで採用するエージェントを敢えて3体に絞ったという経験を共有している。
背景には、エージェントを細分化しすぎると逆に効率が落ちるという実感がある。役割を10種類以上に分けると、それぞれが持つコンテキストが断片化し、引き継ぎのたびにプロンプトや前提情報を再注入する必要が出てくる。結果として、トークン消費が増える割にアウトプット品質が安定しないという問題が生じやすい。筆者は3体構成にすることで、各エージェントが十分な文脈を保持しつつ、責任範囲も明確になるバランス点を見出したと説明している。
具体的な分け方としては、設計・実装・レビューといった大きな粒度で責務を切るアプローチが採られていると見られる。これはソフトウェア開発における伝統的な役割分担とも親和性が高く、人間のチーム運用の知見をそのままLLMエージェントに転用しやすい。
Claude Codeのサブエージェント運用において、役割を細かく分割しすぎず3体構成にとどめた事例の紹介。
マルチエージェント設計の文脈では、AutoGenやLangGraph、CrewAIといったフレームワークでも同様の議論があり、「エージェントは少ないほど良い」という主張はAnthropic自身のブログ記事(Building effective agents)でも触れられている。複雑なオーケストレーションよりも、単純な構成と明確なツール定義が信頼性を生むという立場だ。Claude Codeのサブエージェント機能はYAML形式で簡潔に定義できるが、それゆえに過剰設計に陥りやすい側面もあり、本記事の知見は実務的な指針として参考になりそうだ。
Anthropic's Claude Code increasingly supports a workflow where developers define multiple sub-agents, each with a specialized role, that collaborate on tasks. In this article, the author shares an experience of deliberately limiting their setup to just three agents rather than spinning up many narrowly scoped ones.
The motivation is rooted in a practical observation: over-fragmenting agent responsibilities tends to backfire. When you split work across ten or more specialists, each agent ends up with only a fragment of the relevant context, and every handoff requires re-injecting prompts and background information. The result is higher token consumption without a corresponding gain in output quality, and sometimes a noticeable drop in coherence as instructions ricochet between agents.
By keeping the team to three, the author reports finding a sweet spot where each agent retains enough context to reason effectively while still having a clearly bounded responsibility. Although the article does not exhaustively enumerate the roles, the split appears to follow familiar coarse-grained software engineering boundaries — something like design, implementation, and review — which maps naturally onto how human engineering teams already divide labor. That alignment makes the configuration easier to reason about and to debug when something goes wrong.
This perspective resonates with broader industry discussion around multi-agent design. Frameworks such as AutoGen, LangGraph, and CrewAI all expose machinery for elaborate agent hierarchies, yet experienced practitioners increasingly caution that simpler topologies tend to be more reliable. Anthropic's own essay "Building effective agents" makes a similar point, advocating for straightforward compositions and well-defined tools over baroque orchestration. Empirically, complex agent graphs are harder to evaluate, more sensitive to prompt drift, and prone to compounding errors as control passes between participants.
Claude Code's sub-agent feature lets you declare agents concisely in YAML, which is a strength but also a temptation: the low friction of definition can encourage over-engineering. Each new agent feels nearly free to add, yet the hidden costs — context fragmentation, longer execution traces, and harder failure analysis — accumulate quickly. The author's three-agent configuration can be read as a deliberate counterweight to that tendency.
It is worth noting that the optimal number of agents is likely task-dependent. For very large codebases or pipelines spanning multiple domains, a finer breakdown may still pay off, particularly when combined with shared memory or retrieval layers that mitigate context loss. Conversely, for day-to-day feature work, a small, tightly coupled team of agents may dominate. Readers considering their own setup may want to start coarse and only introduce additional specialization when a concrete bottleneck appears, rather than designing an elaborate org chart upfront.
本ページの本文・要約は AI による自動生成です。正確性は元記事 (zenn.dev) をご確認ください。