Task tool model parameter is ignored for built-in subagent types

Resolved 💬 3 comments Opened Jan 22, 2026 by ThanosKitsios Closed Jan 22, 2026

Description

The Task tool model parameter does not work when spawning built-in subagent types like general-purpose. Subagents inherit the parent model regardless of what model is specified.

Steps to Reproduce

  1. Run Claude Code with Opus as the parent model
  2. Spawn a subagent with explicit model parameter:
  1. Check billing/usage dashboard

Expected Behavior

Subagent should use Sonnet model as specified.

Actual Behavior

Subagent uses Opus (parent model). Billing shows zero Sonnet usage despite multiple agents spawned with model: sonnet.

Workarounds Attempted

  • Custom agent file in .claude/agents/ with model: sonnet - not recognized without restart
  • Environment variable CLAUDE_CODE_SUBAGENT_MODEL - requires session restart, defeats purpose of runtime parameter

Impact

  • Users cannot control subagent costs at runtime
  • Documentation implies this should work
  • Significant cost difference between Opus and Sonnet for batch operations

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗