Subagents should inherit parent's context window size (1M)
Problem
When the main session uses a model with extended context (e.g., claude-opus-4-6[1m]), spawned subagents (via the Agent tool) default to the standard 200k context window instead of inheriting the parent's 1M window.
This means subagents operate with 1/5th of the available context, limiting their usefulness for tasks that require reading large files, exploring broad codebases, or handling complex multi-step research.
Current behavior
- Main session:
claude-opus-4-6[1m]→ 1M context window - Spawned agent with
model: "opus"→ 200k context window - No way to pass the
[1m]suffix through the Agent tool'smodelparameter (enum only accepts"sonnet","opus","haiku")
Expected behavior
Subagents should inherit the parent session's context window size by default. If the parent has 1M context, agents spawned from it should also get 1M context (using the same model variant).
Alternatively, allow the [1m] suffix in the Agent tool's model parameter (e.g., model: "opus[1m]").
Workaround
None currently. The Agent tool's model enum doesn't support the [1m] modifier.
Related
- #37793 — Subagents failing because tool definitions exceed 200k (proposed solution #3 in that issue is the same ask)
Environment
- Claude Code v2.1.81
- macOS
- Claude Max subscription (1M context available)
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗