Skip to content

feat(tui): argument auto-completion for /effort #3731

Description

@aheritier

Extend the argument-completion hook (shipped in #3728) to /effort: pressing Tab after /effort lists the current model's supported thinking levels.

Decision: show ONLY the model's supported levels. Unsupported levels hard-fail on submit (SetAgentThinkingLevel rejects them), so they are never offered as completions.

Approach (from the command-argument-autocomplete plan, Stream A — two stacked PRs):

  • PR A1: extract the supported-levels resolution into LocalRuntime.CurrentAgentThinkingLevels(ctx), exposed via App.CurrentAgentThinkingLevels(ctx) (returns nil on remote runtimes / non-reasoning models). Behavior-neutral; single source of truth shared with the effort setter.
  • PR A2: effortCandidates + attachEffortCompletion targeting the session.effort command, wired in BuildCommandCategories; tests mirroring the existing commands_test.go / command_test.go patterns (stub source + fresh-on-each-call); docs (docs/features/tui/index.md, docs/guides/thinking/index.md) + CHANGELOG.

Tracked follow-up to #3730.

Metadata

Metadata

Assignees

Labels

area/modelsLLM model integrations and model providersarea/tuiFor features/issues/fixes related to the TUIgood first issueGood for newcomers

Fields

No fields configured for Enhancement.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions