Fix harness default model states in onboarding#2156
Merged
Conversation
baxen
approved these changes
Jul 20, 2026
wpfleger96
added a commit
that referenced
this pull request
Jul 20, 2026
…vider * origin/main: (111 commits) fix: skip membership lookup for open relays (#2107) fix(desktop): make invite QR downloadable (#2168) Archive managed agents when deleted (#2135) perf(relay): cache Git pack hydration (#2169) chore(deps): update rust crate rustls to v0.23.42 (#2151) chore(deps): update dependency @tanstack/react-virtual to v3.14.6 (#2153) Add Agent Config Core: harness capability model behind agent config surfaces (#2158) chore(deps): update all non-major dependencies (#2152) chore(deps): update rust crate getrandom to v0.4.3 (#2150) fix(relay): bound and observe Git read operations (#2167) fix(desktop): derive default clone URL for relay-hosted repos (#2166) fix(desktop): mask composer rounded corners (#2165) feat(desktop): add PR merge conflict recovery (#2164) fix(desktop): mask scrolled content behind channel and thread composers (#2163) feat(desktop): add inline PR diff comments (#2162) feat(desktop): add commit-scoped PR review decisions (#2161) fix(desktop): batch project work item queries (#2160) feat(desktop): make missing project checkouts actionable (#2159) Fix harness default model states in onboarding (#2156) relay: gate push enqueue on live leases; batch matcher pipeline (T1b/T1a-repair/T2b) (#2145) ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR is a narrow safety/presentation patch for onboarding’s default model configuration, split out before the larger Agent Config Core work.
It fixes the field-test issue where Claude Code / Codex could look unconfigured even though the harness had a valid default, and it prevents stale model choices from one harness from appearing as “custom” models in another harness.
Concretely:
defaultmodel entries are merged into one canonical default row, so users do not see two different “default” choices for the same behavior.gpt-5.5[low]cannot survive into Claude Code as a custom model.BUZZ_AGENT_THINKING_EFFORTpath.Why this PR exists
While testing onboarding, Morgan noticed this confusing path:
The underlying behavior was not completely broken: Claude Code and Codex can run with their own harness defaults. The product problem was that Buzz rendered those unset-but-valid defaults as if the user still needed to choose something.
Then, while testing Codex, we found a second issue:
gpt-5.5[low].Before this PR, the old Codex model could appear under Claude Code as:
Custom model…gpt-5.5[low]That is misleading. The model belonged to the old harness context and should not carry forward silently.
What we learned
This PR exposed a larger architecture issue: the existing shared config UI is still shaped around the Buzz Agent / Goose model of:
That shape does not map cleanly onto every harness.
Claude Code
Claude Code effort is real, but not through Buzz Agent’s generic env var.
Local CLI / adapter inspection showed:
--effort <level>.id: "effort"thought_levelSo the current generic
BUZZ_AGENT_THINKING_EFFORTfield is not the correct way to configure Claude Code effort.Codex
Codex model discovery can return model IDs that already include effort, such as:
gpt-5.5[low]gpt-5.5[medium]gpt-5.5[high]So showing a separate generic Effort field next to those choices creates two controls for what is effectively one Codex decision.
Clearing rule
We settled on this policy for the future config core:
Meaning:
gpt-5.5[low].This PR implements the immediate onboarding-safe version of that policy.
What changed in this PR
Model defaults now render honestly
usePersonaModelDiscoverynow preserves the harness default/current model as a displayable default row.Examples:
Default model (gpt-5.5[high])when Codex reports a current/default model.Default modelwhen a harness supports a default but does not report the concrete current model.Loading models…while discovery is still pending.Duplicate default rows are merged
Some harnesses expose a literal model option with ID
default. Buzz also needs an empty-value default row meaning “let the harness choose.”Those are the same user intent. This PR absorbs harness
defaultcatalog entries into the canonical empty-value default row, so the user sees one default choice instead of two.Harness switching clears dependent state immediately
Onboarding now clears stale dependent values as soon as selected harness context changes, rather than waiting for model discovery to eventually prove the old model is invalid.
This prevents stale model flashes/races while the next harness catalog is loading.
Generic Effort is hidden for Claude Code and Codex
This is intentional and temporary.
configOptions, notBUZZ_AGENT_THINKING_EFFORT.Showing the generic Buzz Agent effort control for those harnesses would imply Buzz is applying a setting it is not actually applying correctly.
What this PR intentionally does not do
This PR does not implement the full Agent Config Core.
It does not:
effortconfig option.Those are follow-up steps in the broader Harness / Provider / Model plan.
Follow-up plan
The next architectural step should be an Agent Config Core: one source of truth that maps:
into a field model that answers:
A suggested future policy shape:
The important distinction is that future agents should not add a vague
clearInvalidModelboolean. Changing context and failing async discovery are different events and should have different behavior.How to review
Things to look for:
defaultentries.Verification
Ran after rebasing onto latest
origin/main:cd desktop && pnpm typecheckcd desktop && node --import ./test-loader.mjs --experimental-strip-types --test src/features/agents/ui/agentConfigControls.test.mjs src/features/agents/ui/usePersonaModelDiscovery.test.mjscd desktop && pnpm exec playwright test tests/e2e/onboarding-agent-defaults.spec.ts --project=smoke --grep "authenticated Claude|multiple CLI harnesses|changing setup-page"Also passed during push:
check-push-orgbranch-skewdesktop-checkdesktop-testmobile-testdesktop-tauri-testrust-teststest