Skip to content

Let settings choose the effort for "Create and start" - #9

Merged
ajma merged 1 commit into
mainfrom
add-agent-model-effort-settings
Oct 15, 2026
Merged

ajma merged 1 commit into
mainfrom
add-agent-model-effort-settings

Conversation

@ajma

@ajma ajma commented Oct 15, 2026

Copy link
Copy Markdown
Owner

Closes #8

Summary

An Effort select under Agent, whose levels are the chosen model's thinkingOptions.

 <PreferencesForm> (client/settings-screen.tsx)
   <SettingsSelect label="Agent" onValueChange={chooseAgent} />   # resets effort the new model lacks
+  <SettingsSelect label="Effort" />   # "Model default (Medium)", Low, Medium, High, ...
   <SettingsRow label="Agent prompt" />

Both creation paths only pass a level the model offers:

 createWorkspace (server/issues.ts) / createOnHost (client/remote-create.ts)
   agent = configured ?? host default
+  effort = offeredEffort(snapshot, agent, prefs.effort)   # null → model default
-  agents.create({ config: { provider: agent }, prompt })
+  agents.create({ config: { provider: agent, thinkingOptionId?: effort }, prompt })

The toast and the create menu now say "… at high effort". New preference key effort (default ""), so no settings version bump.

Evidence

  • Before: no Effort setting; agents.create config is always { provider }.
    After: npm run typecheck clean, npm test → 346 passed, including new tests:
settings: offers the chosen model's effort levels and saves one
  pick claude/opus → Effort options = [Model default (Low), Low, Max]; save → { effort: "max" }
settings: returns the effort to the model default when the new model lacks it
settings: keeps a saved effort the host no longer lists
server:   starts the configured effort when the model offers it → { provider, thinkingOptionId: "high" }
server:   uses the model's default effort when the model lacks it → { provider }
remote:   same two cases on another host
shared:   effortChoices / offeredEffort

Merge Danger

Door: two-way

A new optional settings key; reverting leaves an ignored effort field in saved settings.

Blast Radius: small

Only "Create and start an agent". With Effort left at Model default, agents start exactly as before.

🤖 Generated with Claude Code

The Effort select lists the chosen model's thinking options. Creation
passes thinkingOptionId only when that model offers the level, so a
stale level falls back to the model's default instead of failing after
the workspace exists.

Closes #8
@ajma
ajma merged commit 2c2e116 into main Oct 15, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Choose the effort for the agent "Create and start" starts

1 participant