Hierarchical Agent
Agents organized in a tree structure where parent agents have authority to create, assign, and supervise child agents. Each level decomposes tasks further, with control flowing top-down and results flowing bottom-up.
Structure
The manager receives a high-level goal and decomposes it into sub-tasks. Mid-level agents further decompose or directly execute. Results propagate back up the tree for aggregation.
Memory / State / Context
- Memory
- State
- Context
- Persistent working memory at higher levels of the tree
- Often ephemeral memory at worker/leaf levels
- Parent agents maintain summary of children's outputs
- No direct memory sharing between sibling agents
- Task graph tracked by parent agents
- Progress, failures, and retries managed at each level
- Parent owns the decomposition state — children own execution state
- State is hierarchical, mirroring the agent tree
- Parent agents see the global objective and full decomposition
- Child agents see only their scoped subtask
- Context narrows as you move down the tree
- Children don't see sibling tasks or the broader goal
Key Characteristics
- Scalable decomposition — complex tasks broken into manageable subtasks
- Clear accountability — each level owns its scope
- Predictable coordination — control flow is explicit and top-down
- Dynamic spawning — parents can create children at runtime based on need
- Bottleneck risk — parent agents become single points of failure
When to Use
- Tasks require multi-level decomposition
- You need clear authority and supervision chains
- Sub-tasks have different complexity levels requiring further breakdown
- Accountability and traceability matter
- The problem has a natural tree structure (project → tasks → subtasks)