Skip to content

Allow static per-subagent thinking level configuration (like agentModels model overrides) #480

Open

Description

@Hrovatin

Allow static setting of thinking level for specific subagents (as is now configurable for models)

Summary

Model selection can already be statically configured per subagent type via the agentModels.models setting (and the TUI Agent Models submenu), but thinking level cannot. Thinking is only controllable per-spawn (on the subagent tool call) or dynamically via the opt-in Dispatch Arbiter. There is no way to persistently bind a specific subagent type to a specific thinking level.

Current Behavior

  • agentModels.models is typed as Record<string, string[]> (src/core/settings-manager.ts:72) — maps agent type → ordered model fallback list, models only.
  • Agent .md frontmatter supports name, description, tools, readonly, model — no thinking field.
  • Thinking level is resolved per-spawn only (src/core/tools/subagent.ts), or globally via defaultThinkingLevel (settings-manager.ts:110), or dynamically per-spawn via the Dispatch Arbiter.
  • Net effect: you can pin a reviewer/subagent's model persistently, but not its thinking level.

Proposed Behavior

Provide a static, persistent way to configure thinking level per subagent type — parallel to how agentModels.models works — so e.g. code-reviewer can always run at high without per-call intervention. Settings-based (global + project merge) is the natural home; supporting it in agent frontmatter is a secondary option worth considering.

Acceptance Criteria

  • A subagent type can be statically assigned a thinking level via configuration, without editing agent definition files or passing it per-call.
  • Supported values match the existing set: off, minimal, low, medium, high, xhigh.
  • The statically configured level integrates with the existing thinking resolution/precedence (per-invocation thinking and the Dispatch Arbiter still take precedence over the static setting; the static setting takes precedence over the global defaultThinkingLevel).
  • Existing thinking validation is preserved (non-off fails for non-reasoning models; xhigh requires advertised support).
  • Documentation in docs/agent-models.md is updated to describe the new configuration.

Technical Notes

  • AgentModelsSettings (src/core/settings-manager.ts:72) is the closest existing config surface; could be extended (e.g. a parallel thinking map) or a new sibling setting added.
  • Thinking resolution lives in src/core/thinking.ts / src/core/tools/subagent.ts (resolveEffectiveThinkingLevel, validateThinkingLevelForModel).
  • Consider whether the TUI Agent Models submenu and dashboard Settings should expose the per-agent thinking control alongside the model list.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions