{"version":"2.1.335","anchor":"session-info-gains-subagentmodel-field","canonical_anchor":"desktop-repository-settings-can-set-claude-code-subagent-mod","heading":"CLAUDE_CODE_SUBAGENT_MODEL is limited in desktop repository settings and reported to hosts","tier":"notice","area":"Subagents","scope":"individual","heads_up":true,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.335\/e\/session-info-gains-subagentmodel-field","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.335","markdown":"### CLAUDE_CODE_SUBAGENT_MODEL is limited in desktop repository settings and reported to hosts\n\nDesktop Code tab repository settings can set CLAUDE_CODE_SUBAGENT_MODEL only to known model values, and hosts can now read the chosen subagent model\n\n**What**\n\n`CLAUDE_CODE_SUBAGENT_MODEL` is the environment variable that picks the model for subagents, the helpers Claude Code starts to handle parts of a task. Two changes affect it.\n\n- Desktop repository settings: when settings are applied for the desktop Code tab (`firstPartyCodeTab`), the value is accepted only if it is empty, `inherit`, `haiku`, `sonnet`, `opus`, or a claude-haiku, claude-sonnet or claude-opus model id. It is refused if a policy forces the model. Refused values are logged with the reason \"desktop repository model\".\n\n- Session info: an optional, internal field `subagentModel` now reports the model ID that `CLAUDE_CODE_SUBAGENT_MODEL` names, for a host that starts another session.\n\n**Why**\n\nA repository opened in the desktop Code tab can no longer point subagents at an arbitrary value or override a model your policy forces. Desktop and other host apps that start sessions can now see which subagent model is in use.\n\n- Area: Subagents\n- Names: `subagentModel`, `CLAUDE_CODE_SUBAGENT_MODEL`\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 2\/5\n- Scope: individual\n- Heads-up: yes"}