Pattern Matrix/White Paper/C1

C1 · Hierarchical Delegation

Coordinate Collaboration × Hierarchy (split)
Cost High (3-15× a single agent call)
Pattern group Collaboration patterns
Summary A supervisor agent dynamically splits a task, dispatches it to N worker agents for execution, and then merges the results. This is the classic multi-agent supervisor-worker collaboration.

What problem it solves

A single agent that researches, writes the body text, produces figures, and assembles the report all at once is not specialized in any of them, and across a long workflow its context keeps growing. The more subtle problem is this: when one agent processes several subtasks in sequence, the execution details of the earlier tasks stay in its context the whole time, and by the third or fourth task its reasoning quality starts to degrade.

Hierarchical delegation replaces "one all-purpose agent" with "one supervisor plus several specialized workers." The supervisor splits the task, monitors progress, and merges the output; each worker only does the one kind of work it is good at, running in its own isolated context. This lets each segment of work be handled by an appropriate model and prompt, and it also frees the supervisor's context from execution details so it can focus on coordination. The price is that token consumption rises by a multiple, so this pattern only fits scenarios where the value of the task can cover that multiple.

Why the coordinate is "Collaboration × Hierarchy"

  • Vertical axis · Collaboration: This is genuine multi-agent role differentiation—the supervisor and the workers are different agents that carry different responsibilities, not an engineering abstraction inside a single agent. Researcher, Writer, and Visualizer each correspond to one professional capability, and this division of labor by occupational ability is the classic form of multi-agent collaboration.
  • Horizontal axis · Hierarchy: The topology is a tree. The orchestrator sits on top and several workers sit below; workers do not communicate directly, and to exchange information they must go through the supervisor. This is a natural hierarchical structure, distinct from the fan-out aggregation of Parallel, the review loop of adversarial review, and the sequential handoff chain.

Core mechanism

A single hierarchical delegation consists of three stages:

  1. Dynamic splitting: The supervisor decides, based on the specific input, how many workers to split into and what each worker does. Researching the AI industry and researching the coffee industry produce different subtask structures, so the split must be tied to the input and cannot be hardcoded.
  2. Isolated execution: Each worker runs in an isolated context, does not inherit the supervisor's history, and receives only its own system prompt, its specific task instruction, and its own tool set. Workers run in parallel wherever they can.
  3. Centralized synthesis: The supervisor looks only at the structured artifacts the workers return, not at the workers' raw trajectories, and makes its overall judgment and final merge based on these refined summaries.

The supervisor and workers usually use different models. The supervisor does the splitting and synthesis, which require deep reasoning, so it uses a strong model; the workers do specialized execution, so they use cheaper models. This is the same idea as Plan-and-Execute separating the planner from the executor, only extended from inside a single agent to across multiple agents.

The artifact a worker returns should have at least a three-field structure:

Field Purpose
verdict (success / partial / failure) Lets the supervisor judge at a glance whether this output can be used directly
top findings (3-5 items) A distillation of the worker's conclusions, covering most of the information
confidence (0-1) An arbitration signal when several workers' outputs conflict

Suitable production scenarios

  • Long-workflow tasks with clear professional division of labor: industry research report generation, investment research analysis, new-drug R&D processes, where each stage needs a different professional capability.
  • Isolated processing of batches of similar tasks: contract review, resume screening, document compliance scanning, where each item is handed independently to a worker to avoid mutual contamination and context explosion.
  • Tasks valuable enough to cover the token multiple: at least 2-3× tokens is the norm for multi-agent, and Anthropic measured complex research tasks reaching 15× in exchange for a 90% win rate; only high-value tasks are worth it.

Where it commonly goes wrong

  • The form of delegation without the spirit of isolation: the supervisor sees the worker's full execution process rather than a schema artifact, and after a few tasks its context is filled with details from earlier tasks, causing reasoning quality to fall off a cliff. Workers must reduce to a structured artifact before returning.
  • Workers communicating directly: letting worker A call worker B to save effort turns the tree structure into a mesh structure and drives up the risk of cascade failure. The essence of hierarchical delegation is a tree, and breaking the tree structure breaks the isolation.
  • No boundary on worker failure: a worker throws an uncaught exception, the supervisor receives a raw exception rather than a failure artifact, and the whole task is interrupted. Each worker needs a timeout plus exception wrapping.
  • Too many parallel workers: beyond 5 parallel workers, the supervisor has trouble making trade-offs during synthesis, and the marginal value of the 6th worker starts to decline. The complexity ceiling is not in compute but in the cognitive bandwidth of the model's synthesis.
  • Misuse in Collaboration Light scenarios: if the system has no genuine multiple roles and is only an engineering-level abstract split (for example, the same agent swapping a few prompts), hierarchical delegation should not be applied. It requires that there really be multiple agents with professional differentiation.

Key metrics

  • Coordination overhead ratio (healthy zone < 30%): the share of total tokens consumed by back-and-forth communication between the supervisor and workers. Above half means little budget is left for actual work, so make the artifacts more strictly schematized and route coordination messages through a lightweight channel.
  • Worker failure cascade rate (healthy zone < 5%): the probability that one worker's failure drags down other workers. This is the metric to suppress first; when it is high, it pulls the other three metrics down with it.
  • Artifact compliance rate (healthy zone > 95%): the share of worker returns that conform to the schema. Workers occasionally emitting free text that bypasses the schema trigger redispatch and latency.
  • Token multiple (healthy zone < 5×): the multiple of tokens multi-agent spends over single-agent. 15× is the acceptable ceiling for high-value tasks; for ordinary business 5× is already on the high side, and if it does not match, fall back to a single agent.

Minimal implementation skeleton

SupervisorAgent.execute(task):
                plan = decompose(task)              # dynamic split, tied to the input
                artifacts = parallel gather(        # concurrency cap set to 5
                    IsolatedSubAgent(worker).execute(subtask)
                    for worker, subtask in plan
                )
                return synthesize(task, artifacts)  # look only at artifacts, not raw trajectory

            IsolatedSubAgent.execute(subtask):
                local messages = [system_prompt, subtask]   # do not inherit parent history
                try: raw = wait_for(llm(messages, tools), timeout)  # failure boundary
                except: return Artifact(verdict="failure", ...)
                return reduce_to_artifact(raw)      # force reduce to verdict/findings/confidence
            

Four engineering points: each worker starts in an isolated context; workers are forced to reduce to a schema artifact; each worker uses a timeout plus exception wrapping to isolate failures; a semaphore controls the concurrency cap, and workers share no state with one another.

Enterprise deployment example

A law firm's contract review agent: in the first version the main agent dispatched sub-agents to scan 50 contracts for anomalous clauses, and when each sub-agent finished it returned its full 3,000-word detailed analysis. After receiving 150,000 words, the main agent's context completely exploded and its subsequent reasoning quality fell off a cliff. After the post-mortem the engineering team understood one thing: the main agent should not see the sub-agents' raw work process, only the conclusions—just as a law firm's PM does not ask each lawyer to report which line of each contract they read, only "3 of the 50 are anomalous, plus their list of key issues." The second version assigned an independent worker to each contract, with each worker running in an isolated context and required to reduce to a fixed-schema artifact before returning (contract_id, risk_level, top_3_concerns, recommendation, plus a contract_hash to prevent tampering). The artifacts for all 50 contracts added up to under 10,000 words, which the main agent could handle easily. The accompanying engineering discipline also included: contracts with HIGH or above risk are forced into a lawyer review queue and the agent is not allowed to clear them automatically; each worker's timeout is tightened to 180 seconds and returns a failure artifact on failure rather than blowing up the whole job; the portfolio report is written to a file as an audit trail. After the changes, all 50 contracts ran in 1 hour.

Relationship to other patterns

  • Sub-Agent Isolation (C5): the implementation core. Hierarchical delegation is the move (the supervisor dispatches workers), and sub-agent isolation is the inner skill (the worker's isolated context plus schema artifact plus failure boundary). Hierarchical delegation without isolation will inevitably suffer context explosion plus cascade failure, so the two must go together.
  • Fan-out Aggregation (C2): also one-to-many, but the division logic differs. Hierarchical delegation is one-to-many by specialty (each worker does something different), while fan-out aggregation is one-to-many by volume (multiple workers do different parts of the same kind of work at the same time).
  • Handoff Chain (C4): hierarchical delegation has a supervisor as a stable anchor, while a handoff chain has no supervisor and every leg is a peer.
  • Plan-and-Execute (Action module): hierarchical delegation is its extension at the multi-agent layer, extending "plan-execute separation inside one agent" to "separation across multiple agents."

What this pattern teaches

The essence of hierarchical delegation is not splitting a task and dispatching it, but encoding into an agent system the information-layering discipline that human pyramid organizations have accumulated over 50 years—the supervisor looking only at the refined conclusions of the layer below is the engineering vehicle for that discipline.


This page is part of the ADPS pattern white papers. Back to the pattern matrix, or see the runnable code catalog.