Skip to content

Persist follow-up reasoning through the model override path - #3267

Merged
ymichael merged 2 commits into
mainfrom
slopcop/issue-3257
Sep 10, 2026
Merged

ymichael merged 2 commits into
mainfrom
slopcop/issue-3257

Conversation

@bb-slop-cop

@bb-slop-cop bb-slop-cop Bot commented Sep 8, 2026 •

Copy link
Copy Markdown
Contributor

Human comments

What was wrong

After selecting High reasoning and sending a follow-up in a thread with a saved Max override, the turn used High but reload could restore Max. Explicit sends already repaired stale model overrides; reasoning overrides were left unchanged. See #3257.

What changed

Extend the existing model override recovery path to reasoning in direct sends and queued dispatch. Picker changes remain local until submission; queue timing and retry behavior are unchanged. This replaces the previous save-on-selection approach. No client, wire, protocol, schema, or CLI changes are needed.

The final diff is 6 files, 48 additions and 11 deletions. Tests extend existing fixtures without renaming files.

How you verified

  • Fail-before regression demonstrated stale Max after explicitly choosing High; existing regression cases now cover changed and unchanged models.
  • Focused/adjacent server tests: 128 passed across override recovery/policy, send/queue dispatch, retries, and public thread data. Existing direct/queued tests assert the recorded model and reasoning.
  • Adjacent app tests: 97 passed in the implementation worktree.
  • Turbo build/typecheck/lint for @bb/app and @bb/server, formatting, and diff checks passed. App lint has existing warnings; server has no lint task.
  • Live isolated browser QA: an unsent selection stayed local; sent High persisted in server defaults and after reload. The issue's exact immediate post-send reset was not reproduced in the Codex fixture.

Fixes #3257

AGENT GENERATED

@ymichael ymichael changed the title Persist follow-up reasoning overrides Persist follow-up reasoning through the model override path Sep 10, 2026
@ymichael
ymichael merged commit cac2d51 into main Sep 10, 2026
16 checks passed
@ymichael
ymichael deleted the slopcop/issue-3257 branch September 10, 2026 17:34
ymichael added a commit that referenced this pull request Sep 11, 2026
## Human comments

## What was wrong

After a Fast Codex turn, disabling Fast and sending another message
saved `default` in BB but omitted `serviceTier` from Codex's request.
Omission leaves the provider's existing tier unchanged. Separately,
dispatching a queued message did not invalidate execution defaults, so
an untouched picker could keep showing Fast after a default-tier message
started.

## What changed

- Serialize explicit `default` as `null` on Codex's downstream JSON-RPC
wire; retain `fast` and preserve omission when no tier is supplied.
- Refresh execution defaults on `client/turn/requested`, cancel older
reads, and prevent canceled responses from overwriting the last-known
cache.
- Preserve local unsent choices, queued execution snapshots, queue
ordering, and existing failure/retry behavior.

Unlike the selection-time save proposed in #3403, this follows the
lifecycle established by #3267: picker changes remain local until
submission/dispatch. Switching threads without sending still restores
the last recorded defaults. No new persistent override, database
migration, SDK/CLI surface, or server/daemon wire change; no
`HOST_DAEMON_PROTOCOL_VERSION` bump is needed.

The accepted-turn cache work shares one handler with prompt-history
invalidation. The raw boot budget increases deliberately by 128 bytes
(1,723,617 → 1,723,745): pristine main measures exactly 1,723,617 bytes,
and the simplified fix measures 1,723,707 (+90). This accommodates the
measured eager cache logic; compressed and dependency budgets are
unchanged.

## How you verified

Reproduced on pristine `origin/main` at
`b04091eca67bb463cce16b9bfa318660bd20ab69` using dev-browser, a fresh
isolated database, and `pnpm start:worktree` in a persistent BB
terminal. The exact unsent-toggle/navigation behavior reproduces, while
direct-send BB persistence already works.

Recorded real Codex 0.153.3 JSON-RPC traffic from browser-submitted
turns:

| Step | Before | After |
| --- | --- | --- |
| Fast turn | `turn/start` sends `serviceTier: "fast"`; Codex reports
`"priority"` | Same |
| Disable Fast and send | `turn/start` omits `serviceTier`; last
reported setting remains `"priority"` | Sends `serviceTier: null`; Codex
emits `thread/settings/updated` with `serviceTier: "default"` |

This verifies provider configuration, not billing or measured latency.
Raw recordings and screenshots remain local because they include machine
and model-catalog details.

The real queued lifecycle also passed: queue default during Fast work,
reload while waiting, leave the picker untouched, then observe it switch
off when the queued message automatically dispatches. Before the cache
fix it stayed on despite the server reporting default. Codex→Pi→Codex
selection hides Fast for the unsupported provider.

- Five provider regressions failed against the original converter; the
same focused suite passes 42 tests after the fix. Full Codex suite: 272
passed.
- Two cache regressions failed before and pass after: accepted-turn
refresh and canceled-response persistence. Selected app suites: 155
distinct tests passed, including preservation of unsent selections.
- Adjacent server suites: 60 passed, including direct/busy sends, queued
snapshots, dispatch, errors, retries, and override recovery. Final
dispatch suite: 26 passed.
- Turbo app/server/provider typechecks, applicable builds and lint
passed. Changed-file formatting, lint, and `git diff --check` passed.
App lint retains 190 existing warnings; builds retain chunk-size/timing
warnings.
- Native Electron and iOS Safari were not tested. Bridge tests cover
start/resume/fork reset; live provider proof covers subsequent turns.

CI follow-up: reproduced the raw bundle-budget failure locally,
consolidated duplicate accepted-turn handlers, and compared a
pristine-main build. The correction passed 110 focused
cache/selection/bundle-budget tests; the explicit bundle checker, app
build/typecheck/lint, formatting, and diff checks were rerun.

Fixes #3403

> AGENT GENERATED
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.

Persist follow-up composer effort selections to the thread

2 participants