fix(web): model picker stays put with long names and agent options#28409

merged1
main
t3/fix-model-picker-layout-jank
opened3d agobyTtheo
View on GitHubTwo-way sync enabledPR last imported 3d ago

Problem

Users were upset about the new model picker (example video). Agents like Devin and Cline wrecked it:

  • Long model names such as Fusion (Claude Opus 5.5 Medium + SWE-2 High) stretched the trigger, and every agent option was added after it: Fusion (...) Bypass Permissions · Medium · Standard.
  • Session Mode, Provider, Speed and Auto-approve were stacked into the effort column as long lists.
  • Devin's Thinking levels were not treated as effort, so there were no effort bars.
  • The popup grew, shrank and moved as you switched between models and providers.
  • Grok listed its levels from strongest to weakest, so its effort bars were wrong.

#28307 already stopped the popup sliding sideways. The rest is fixed here.

Fix

  • The effort column shows only the reasoning levels. Every other option is one row that names its current value and opens its choices beside the column on click, tap, Enter or →. On/off options are a switch.
  • ACP thought_level options now carry role: "reasoning", so agents' own effort controls get the effort bars and the effort shortcut.
  • The trigger shows the model, effort, Fast and context window. Agent options never appear there. The model name is capped, and a cut-off name in the list shows in full on hover.
  • The docked popup has one fixed height. It shrinks only when the window is too short, and the footer stays visible. "Using ChatGPT plan" now sits inside that height.
  • Grok levels are sorted from lowest to highest.

Before / after

Devin, before and after:

Devin before Devin after

Cline (options only), before and after:

Cline before Cline after

Narrow window (the menu opens above the row) and short window (the footer stays visible):

Narrow Short

Switching Codex → Devin → Cline → Codex. The popup does not move:

Preview

📹 screen recording

Proof: a new browser test (ComposerModelEffort.browser.test.tsx) fails on main and passes here, and the Grok test fails on main too. I also checked by hand in a dev server with mock Devin- and Cline-shaped ACP agents, at desktop, 390px and 460px-tall sizes.

Follow-ups, not in this PR: show the full name for a cut-off row highlighted with the keyboard, use role for subagent and mobile effort labels, and prefer role over known ids when an agent sends both.

Council review

Rounds: 5

DelegateRound 1Round 2Round 3Round 4Round 5
Claude Opus 5.57/108/109/109/109/10
Muse Wonder Fullno scoreno scoreno scoreno scoreno score
Codex GPT-6.1 Sol7/109/109/1010/1010/10

Created with Claude Opus 5.5 in Claude Code (T3 Code).

🤖 Generated with Claude Code

Checks

1 failing · 24 successful · 13 skipped
Some checks failed

Failing1

95c66a0

Added 1 commit

  • fix(web): model picker stays put with long names and agent options95c66a0
Synced from GitHub

Approvability

Verdict: Approved at 95c66a0

Macroscope's review found this PR approvable — The picker now maintains a stable layout with long model names and agent options, while recognizing agent reasoning controls and consistently ordering Grok effort levels. The changes preserve selected defaults and remain limited to presentation and explicit user interactions.

You can add or adjust custom eligibility rules. Learn more.

Synced from GitHub

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

ProviderMetricMain baselineThis PRImpactPR ceiling
CodexTotal thread wire5.0 KiB5.0 KiB+29 B (+0.6%)6.8 KiB✅
CodexThread snapshot wire3.8 KiB3.8 KiB0 B (0.0%)4.9 KiB✅
CodexLive turn WebSocket wire1.2 KiB1.2 KiB+29 B (+2.3%)2.0 KiB✅
CodexLive turn WebSocket decoded21.5 KiB21.6 KiB+41 B (+0.2%)24.4 KiB✅
CodexLive turn messages12+1 (+100.0%)8✅
ClaudeTotal thread wire5.0 KiB5.1 KiB+6 B (+0.1%)6.8 KiB✅
ClaudeThread snapshot wire3.8 KiB3.8 KiB0 B (0.0%)4.9 KiB✅
ClaudeLive turn WebSocket wire1.3 KiB1.3 KiB+6 B (+0.5%)2.0 KiB✅
ClaudeLive turn WebSocket decoded21.9 KiB21.9 KiB0 B (0.0%)24.4 KiB✅
ClaudeLive turn messages220 (0.0%)8✅

Baseline: 54c5f25 · PR result: 95c66a0 · Source CI: success

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 108.5 KiB
  • Claude decoded thread snapshot: 108.8 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.