Agent tool: `model` override silently ignored when subagents spawn as background teammate sessions — workers inherit saved /model and /effort defaults

Status Closed — duplicate
Maintainer reply None cached
Activity 1 comment · opened Aug 12, 2026 · closed Aug 20, 2026

Summary

The Agent tool's documented model parameter ("Optional model override for this agent. Takes precedence over the agent definition's model frontmatter") is silently ignored when subagents are spawned as background teammate sessions. The spawned workers instead inherit the user's saved /model and /effort defaults, with no error or warning.

Environment

  • Claude Code v2.1.228, macOS (darwin 25.5.0)
  • Main session model: Fable 5 (claude-fable-5), set via /model and saved as default for new sessions; /effort xhigh likewise saved as default
  • Subscription: Max

Reproduction

  1. Save a premium model as the default for new sessions via /model (here: Fable 5), and an effort tier via /effort (here: xhigh).
  2. Have the main session dispatch a worker: Agent(subagent_type: "general-purpose", model: "opus", name: "worker-1", prompt: ...).
  3. Observe the spawn result is the async/teammate form — "Spawned successfully… agent_id: worker-1@session-…; the agent is now running and will receive instructions via mailbox" — rather than a blocking run that returns the agent's result.
  4. Inspect the worker: its session banner shows the saved default (Fable 5 with xhigh effort), not the dispatched model.

Evidence from an affected session

Five separate Agent dispatches in one session, every one carrying model: "opus" explicitly. Transcript grep over the session file:

$ grep -o '"model":"[^"]*"' <session>.jsonl | sort | uniq -c
 657 "model":"claude-fable-5"
  11 "model":"opus"

Zero turns on any claude-opus-* model id anywhere in the file; the 11 literal "opus" strings are the dispatch parameters themselves (tool_use inputs), not executed turns. One worker's pane confirmed the Fable 5 / xhigh banner directly.

Expected

Per the tool schema, the per-call model override should determine the spawned agent's model (it is documented to take precedence over agent-definition frontmatter, and to be ignored only for subagent_type: "fork").

Impact

Orchestration patterns that keep a premium model in the main loop and fan implementation out to a cheaper model silently bill the entire worker fleet at the premium default — in the affected session, five long-running implementation workers plus a reviewer agent all ran Fable at xhigh; one worker consumed ~481k tokens in a single turn. Because the failure is silent, nothing surfaces it except inspecting a worker's banner or transcript.

Notes

  • Only observed on the named/teammate spawn path ("will receive instructions via mailbox"). Classic blocking Agent runs were not exercised in the affected session, so they may or may not be affected.
  • The effort inheritance may be by design (there is no per-call effort parameter on the Agent tool), but the model override is explicitly documented.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗