The core concept of Sub-agents is the 'expert hybrid' model, whereby multiple highly specialized AI sub-agents work in concert rather than relying on a single general-purpose AI. each sub-agent is pre-configured for a specific area of development (e.g., code review, testing, debugging, etc.), with a separate set of system hints and tools. This design brings three major advantages: 1) increased task accuracy as each agent focuses on a single domain in an isolated context; 2) avoidance of the 'phantom' problem when a generic AI handles complex tasks; and 3) automation of the workflow, with a chain of task triggers via a hook system. Developers can use these agents in combination as if they were forming a team of professionals, breaking down large development tasks to different 'experts' and significantly improving the quality and speed of code generation, review and testing.
This answer comes from the articleSub-agents: Tools for adding and managing AI sub-agents for Claude CodeThe