Bug
In a Cursor ACP session where no model has been explicitly chosen, the model picker dropdown shows no radio selected - even though the session is actively pinned to default[] (Cursor's server-chosen Auto router pick).
Repro
- Open a Cursor session in HAPI web.
- Open the model picker.
- Observe: every row (Default, composer-2.5 · fast=true, claude-fable-5 · ..., etc.) has an empty radio.
Expected: Default is highlighted, because the launcher pins default[] via setConfigOption on spawn (cli/src/cursor/cursorAcpRemoteLauncher.ts:321-342).
Root cause
The picker is in flat mode because HAPI's ACP client doesn't declare the proprietary parameterizedModelPicker capability (the Cursor-side workaround flag discussed in the forum thread). With no parameterizedModelPicker, Cursor returns one wire id per base, so HAPI builds a flat catalog.
SessionChat.tsx only forwards `selectedModelBase` to `HappyComposer` when `cursorPicker.mode === 'dual'`:
```
selectedModelBase={
agentFlavor === 'cursor' && cursorPicker?.mode === 'dual'
? cursorSelectedBaseValue
: undefined
}
```
In flat mode the prop is `undefined`, so `HappyComposer` falls back to `model === option.value`. The session's `model` is `null` (the launcher calls `previousSetModel(undefined)` after applying `default[]`), and the Default row's value is `'auto'`, so `null === 'auto'` fails for every row.
Fix
Drop the `mode === 'dual'` gate. `resolveSessionCursorBaseSelectValue` already handles flat mode correctly via its early return (`return picker.wireId ?? 'auto'`), which yields `'auto'` when the session is on default and matches the Default row's value.
Out of scope (separate upstream conversation)
The deeper fix is for Cursor to migrate to the standard ACP `configOptions` / `thought_level` mechanism so HAPI gets the full multi-variant catalog without proprietary capability flags. Cursor has agreed to do this but no ETA. Once it lands, HAPI moves to dual mode automatically and this bug becomes invisible - but the patched flat-mode highlight remains correct.
Bug
In a Cursor ACP session where no model has been explicitly chosen, the model picker dropdown shows no radio selected - even though the session is actively pinned to
default[](Cursor's server-chosen Auto router pick).Repro
Expected:
Defaultis highlighted, because the launcher pinsdefault[]viasetConfigOptionon spawn (cli/src/cursor/cursorAcpRemoteLauncher.ts:321-342).Root cause
The picker is in flat mode because HAPI's ACP client doesn't declare the proprietary
parameterizedModelPickercapability (the Cursor-side workaround flag discussed in the forum thread). With noparameterizedModelPicker, Cursor returns one wire id per base, so HAPI builds a flat catalog.SessionChat.tsxonly forwards `selectedModelBase` to `HappyComposer` when `cursorPicker.mode === 'dual'`:```
selectedModelBase={
agentFlavor === 'cursor' && cursorPicker?.mode === 'dual'
? cursorSelectedBaseValue
: undefined
}
```
In flat mode the prop is `undefined`, so `HappyComposer` falls back to `model === option.value`. The session's `model` is `null` (the launcher calls `previousSetModel(undefined)` after applying `default[]`), and the Default row's value is `'auto'`, so `null === 'auto'` fails for every row.
Fix
Drop the `mode === 'dual'` gate. `resolveSessionCursorBaseSelectValue` already handles flat mode correctly via its early return (`return picker.wireId ?? 'auto'`), which yields `'auto'` when the session is on default and matches the Default row's value.
Out of scope (separate upstream conversation)
The deeper fix is for Cursor to migrate to the standard ACP `configOptions` / `thought_level` mechanism so HAPI gets the full multi-variant catalog without proprietary capability flags. Cursor has agreed to do this but no ETA. Once it lands, HAPI moves to dual mode automatically and this bug becomes invisible - but the patched flat-mode highlight remains correct.