Subagents

Delegation with its own context for work that can be separated; the benefit depends on independence, coordination, and cost.
Updated 6 Oct 2026

A subagent receives a bounded part of the work, its own context, and an expected result. Unlike a tool call, it can make several decisions and use tools in its own loop before returning a conclusion to the parent agent.

Delegation

During a repository review, the parent agent can ask one subagent to inspect the authentication module and another to review the configuration parser.

Parallel delegation and return The main agent delegates two independent repository reviews. Subagent A reviews the authentication module and Subagent B reviews the configuration parser in separate contexts, then both return findings to the main agent. Main agent Delegate and combine results Subagent A Review authentication moduleSeparate context Subagent B Review configuration parserSeparate context Main agent Delegate and combine results Independent tasksFindings return Parallel delegation and return The main agent delegates two independent repository reviews. Subagent A reviews the authentication module and Subagent B reviews the configuration parser in separate contexts, then both return findings to the main agent. Main agent Delegate and combine results Subagent A Review authentication moduleSeparate context Subagent B Review configuration parserSeparate context Main agent Delegate and combine results
Figure 1. The parent delegates two independent reviews with separate context, then brings both results back together.

Each delegation should make clear:

  • The objective of the review.
  • The files, constraints, or evidence it needs.
  • The result it should return.

If the tasks are independent, they can run in parallel. The parent then receives the findings, removes duplicates, and decides which issues need action.

Returning the complete transcript is rarely necessary. Conclusions, relevant evidence, affected files, and open questions are normally enough to integrate the work.

Separate context

A subagent can work without copying the parent’s full conversation. This reduces irrelevant context and keeps intermediate searches or results out of the coordinating agent’s context.

The trade-off is that a constraint that exists only in the parent conversation can be lost. If a review must be read-only, that rule needs to be part of the delegation or of instructions the subagent actually inherits.

Parallelism and conflicts

Parallel work fits read-only tasks and clearly separated modules best. Two agents editing the same file can create conflicts, while a task that continually depends on discoveries from another usually works better sequentially.

Each subagent adds its own inferences and context. It can reduce elapsed time when several independent tasks progress at once, while increasing total usage. That trade-off matters when deciding whether delegation is worth the additional coordination.

References