06. Multi-Agent Systems
Agent Delegation
Delegation transfers ownership of a subtask to another agent with scoped authority, a clear contract, and a report-back path — while the delegator keeps accountability for the overall goal. It is stronger than a tool call and the building block behind supervisor–worker designs.
What you will learn
- Define delegation vs a plain tool call
- Write a delegation contract (I/O, authority, deadline)
- Walk the specify → assign → execute → report → accept loop
- Know when to recall, rework, or escalate
- Answer interview questions with short, solid answers
Definition
Agent delegation is the act of assigning a subgoal to another agent (the delegate) with explicit authority, inputs, success criteria, and a deadline — then accepting, reworking, or escalating the returned result. The delegator remains accountable for the parent goal.
Delegation is a control relationship, not just a message. If there is no authority boundary, no contract, and no accept/reject step, you only have a chat handoff.
Introduction
This lesson (#4 in Multi-Agent Systems) follows Communication, Collaboration and Coordination. Those define how agents talk; delegation defines how responsibility moves.
Next: Supervisor and Worker Agents — a common organizational form of delegation.
Why delegation matters
- Specialize work without one mega-agent doing everything
- Isolate permissions (delegate only gets needed tools)
- Parallelize independent subgoals safely
- Create auditable ownership of subtasks
Delegation vs tool call
Do not call every function a “delegate.” Tools are actions; delegates are agents that may plan and use tools themselves.
- Tool call - name + args; runtime executes; observation returns
- Delegation - subgoal + authority; delegate may call many tools
- Use a tool when the step is atomic and deterministic enough
- Use a delegate when the subtask needs reasoning, multi-step work, or a different role prompt
Delegation lifecycle
Drive the lifecycle from the orchestrator/code — counters and validators — not only from free-form prompts.
- Specify - goal, inputs, output schema, constraints
- Assign - choose delegate, grant tool allowlist + budget
- Execute - delegate runs; optional progress heartbeats
- Report - structured success, partial, or error payload
- Accept / rework / escalate - delegator decides under max attempts
The delegation contract
- Objective - one measurable subgoal sentence
- Inputs - artifacts, IDs, context the delegate may see
- Outputs - schema the delegator will validate
- Authority - allowed tools / actions / spend
- Deadline - wall clock or token budget + on-timeout behavior
- Non-goals - what the delegate must not do
Authority, recall, and escalation
- Least privilege - grant only tools required for the subgoal
- Recall - delegator may cancel an in-flight task on policy breach
- Rework - return with critique; count against max attempts
- Escalate - human or higher supervisor when stuck or high-risk
- No silent expansion - delegate must not widen scope without ask
Failure modes
- Vague briefs - “handle support” with no schema; fix the contract
- Authority leaks - refund tools on a research delegate
- Abandoned tasks - no timeout; always set deadlines
- Ping-pong rework - uncapped reject loops
- Accountability fog - who owns the parent goal? keep it on the delegator
Program / implementation notes
Model DelegationJob { id, parent_goal_id, assignee, contract, status, attempts }. Transitions belong in code.
- Log assign, report, accept/reject with agent ids
- Prefer artifact refs in contracts over huge pasted context
- Next: Supervisor and Worker Agents
Advantages and limitations
- Advantage: clear ownership of subtasks and permissions
- Advantage: scales specialists without bloating one prompt
- Advantage: natural fit for supervisor–worker topologies
- Limitation: contract design overhead
- Limitation: latency from assign/report round-trips
- Limitation: bad briefs amplify downstream errors
Key points
- Delegation assigns a subgoal with authority; accountability stays with the delegator.
- Stronger than a tool call: the delegate has its own policy loop.
- Lifecycle: specify → assign → execute → report → accept/rework/escalate.
- Contracts need objective, I/O schema, authority, deadline, non-goals.
- Least privilege, recall, and max rework attempts are mandatory.
- Supervisor–worker is a common organization of delegation.
FAQs
Is handoff the same as delegation?
Handoff is transferring the conversation or artifact. Delegation also transfers authority for a subgoal under a contract with report-back.
Can a delegate re-delegate?
Yes, if the contract allows nested authority. Cap depth and budgets so trees do not explode.
Who is accountable if the delegate fails?
The delegator remains accountable for the parent goal; the delegate is responsible for the subgoal under the contract.
When should I not delegate?
When the step is a single safe tool call, or when writing a clear contract would cost more than doing the work in one agent.
Interview questions
- What is agent delegation?
Answer Assigning a subgoal to another agent with scoped authority and a contract, while the delegator keeps accountability for the overall goal.
- How does delegation differ from a tool call?
Answer A tool call executes one action. A delegate runs its own decision loop and may use many tools to finish a subgoal.
- What belongs in a delegation contract?
Answer Objective, inputs, output schema, tool authority, deadline/budget, and explicit non-goals.
- What is recall in delegation?
Answer The delegator cancels or revokes an in-flight delegated task — typically on timeout, policy breach, or priority change.
- Name a delegation failure mode.
Answer Vague briefs without schemas causing wrong work — or uncapped rework ping-pong between delegator and delegate.
- How does this relate to supervisor–worker?
Answer A supervisor is a delegator that repeatedly assigns and integrates worker results; workers are long-lived delegates for specialized subgoals.
Related topics
Practice task
Complete each numbered practice step in a notebook or doc before opening the next lesson.
- Write a delegation contract for “summarize this PDF for legal review” (objective, I/O, authority, deadline, non-goals).
- List tools the delegate may and must not receive.
- Define accept / rework / escalate rules with max 2 rework attempts.
- Mark one step in your product that should stay a tool call, not a delegate.
- Answer interview questions 1, 2, and 3 in two sentences each.