Skip to content

fix: make Daybreak one toggle that follows the chat's model - #204302

Merged
steipete merged 7 commits into
mainfrom
fix/daybreak-single-toggle
Nov 24, 2026
Merged

steipete merged 7 commits into
mainfrom
fix/daybreak-single-toggle

Conversation

@steipete

@steipete steipete commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Each OpenAI model supports exactly one Daybreak program: mainline models (GPT-6.2 Sol and similar) take Daybreak Blue or Standard, while cyber models (GPT-6 Cyber, GPT-5.6 Cyber) take Daybreak Red only. The chat speed menu still offered a Blue/Red chooser, so GPT-6 Cyber showed "Blue (unavailable)" next to "Red", which reads as if access were missing. Worse, a chat that turned on Blue with GPT-6.2 Sol kept daybreak_blue after switching to GPT-6 Cyber. Every send then failed with "This Daybreak program is not advertised… Select Standard", and Standard cannot run a cyber model either. New chats on an unconfigured cyber model also started at Standard.

User Impact

Daybreak is one on/off toggle per chat. The model decides Blue or Red and the toggle shows it as a caption. Cyber models show the toggle locked on with "Required by this model". Switching models carries Daybreak along, so Blue becomes Red on a cyber model (and back to Blue on a mainline model) in the same update as the model change. A chat that already stores the wrong program shows the toggle off, and turning it on repairs it in place. Runtime errors now name what the model supports and the next step.

Behavior note: choosing a cyber model turns Daybreak on, and it stays on (as Blue) when the chat switches back to a mainline model. It is visible there and can be turned off.

Why This Change Was Made

  • One UI resolver (ui/src/lib/chat/daybreak-access-program.ts) derives the program, locked state, checked state, and model-switch remap from the model's advertised availableAccessPrograms.cyber. Chat controls, chat model switches, and new-session drafts all use it.
  • The chat model switch sends model and the remapped cyberAccessProgram in one sessions.patch (also through native-runtime recovery). New-session drafts submit the model's required program.
  • The remembered Blue/Red preference (daybreakAccessProgram) is removed; legacy stored drafts and preferences still decode and drop the field. It was never part of the Gateway protocol.
  • The embedded runner and the Codex harness error text names the supported programs and says "Turn on Daybreak for this chat to use Daybreak Red" (or "Turn Daybreak off" when the model has no Daybreak program). Codes, failover reasons, and control flow are unchanged.

Out of scope, named on purpose: sessions created outside the Control UI on an unconfigured cyber model still get the server's standard default (resolveModelCyberAccessProgramDefault) and fail until params.accessPrograms.cyber is configured; that runtime default is a separate follow-up. A remap that an operator role ceiling rejects fails the model switch; restricted roles get Standard only, so this is not reachable with default roles.

Evidence

Synthetic Control UI E2E fixtures (mocked Gateway, synthetic models and chat), dark theme, 1440×900, speed popover open. Before = main at 34c8570, after = this branch.

Clean comparison

GPT-6 Cyber chat that still stores Daybreak Blue (the reported failure):

Before After
Before: Daybreak chooser on GPT-6 Cyber lists Blue (unavailable) and Red After: single Daybreak toggle shown off with the hint Required by this model

Annotated comparison

Before After
Blue/Red chooser outlined; saved Blue shows as unavailable Single Daybreak toggle outlined; stale Blue shows off and turning it on saves Red

Other states

State Before After
GPT-6.2 Sol, Daybreak on Before: toggle on with a Blue option row After: toggle on with caption Blue
GPT-6 Cyber, Red saved Before: toggle on with a Red option row After: toggle locked on with caption Red
GPT-6.2 Sol, Daybreak off Before: toggle off After: toggle off

Behavior proof:

  • ui/src/e2e/chat-daybreak-controls.e2e.test.ts (4 cases): mainline toggle writes daybreak_blue; cyber model renders locked Red; switching GPT-6.2 Sol (Blue) → GPT-6 Cyber through the model picker sends one sessions.patch with model and cyberAccessProgram: "daybreak_red" (this case fails on main: the patch carried only the model); a stale Blue on GPT-6 Cyber renders unchecked and turning it on sends daybreak_red, after which it is locked with caption "Red" (fails on main).
  • ui/src/e2e/chat-daybreak.real-gateway.e2e.test.ts (3 cases) passed against a built, isolated Gateway with synthetic provider I/O.
  • Resolver, model-preferences, new-session model-control/preferences, draft codec, settings materialization and effort-picker browser tests pass (Chromium and WebKit for the picker).
  • src/agents/embedded-agent-runner/run/access-program.test.ts and extensions/codex/src/app-server/run-attempt.native-config.test.ts cover the new error guidance.
  • pnpm tsgo:prod, pnpm tsgo:ui, oxlint and format on touched files, stylelint on composer.css, pnpm ui:i18n:baseline/verify (no baseline drift), pnpm check:test-lines-ratchet (net −170 test lines), git diff --check.
  • Local review: autoreview (Codex engine), local change snapshot on base 34c8570, P0 threshold: scoped-clean, no findings.

Review follow-up (head 245be29):

  • ClawSweeper P2: a new draft on a Red-only model displayed the catalog default (Standard) while submission normalized to Red. Drafts now render accessProgramForSubmission(), the same value they submit, so the toggle shows locked Red before sending. The restored test commits the displayed first-use Access as daybreak_red failed before this fix and passes now. Existing chats keep the separate stale-program repair.
  • Stored data compatibility: ui/src/lib/chat/composer-draft-store-codec.test.ts loads an IndexedDB draft that still carries the retired daybreakAccessProgram, keeping cyberAccessProgram and dropping the old field. ui/src/pages/new-session/preferences.test.ts does the same for authenticated new-session preferences. No Gateway protocol, config, or server-side state changed, so there is no Doctor or upgrade migration.

CI notes (head 3598443):

  • Chat boot JS budget: the model-switch remap and stale-program repair add +451 B gzip to chat boot (1,334,559 → 1,335,010 B vs the paired base). chatBootJsGzipBytes is raised by exactly that measured cost plus 64 B headroom, with a provenance comment in scripts/check-control-ui-performance.mts. New-session boot grew +151 B and stays within its limit.
  • Fixed a test-only type import (CyberAccessProgram now comes from the gateway-protocol schema module) that broke check-test-types-core-2.
  • Not caused by this PR: with this PR's runtime and Codex changes reverted to base, the same five extensions/codex app-server tests (host credential execution, compaction model policy, parent continuation) still fail locally. test/vitest-projects-config.test.ts failed because src/shared/session-unread.test.ts (from fix(sessions): unread advances only when a run ends with a new visible reply #204281) had two owners; main fixed that in test(vitest): keep database-worker files out of the shared-core project #204316, so head 1a3e659 merges current main and the test passes locally (42/42). boot-module-boundaries, session-catalog-backoff, and signed-call-boundary pass locally. The gateway e2e shards that failed don't involve the touched code, and main's hourly full CI is red across similar shards.

Live context: the reported failure reproduced on a real Gateway (GPT-6.2 Sol with Blue → GPT-6 Cyber); this PR's flow was verified with mocked/isolated Gateways, not yet on that deployment.

Release note context: Control UI: Daybreak is now a single per-chat toggle; the model picks Blue or Red, cyber models show it locked on, and model switches carry Daybreak over instead of failing with an unavailable-program error.

Each OpenAI model supports exactly one Daybreak program: mainline models
take Daybreak Blue (or Standard), cyber models take Daybreak Red only. The
chat popover still offered a Blue/Red chooser, so GPT-6 Cyber showed
"Blue (unavailable)" next to "Red", and a chat that turned Blue on with
GPT-6.2 Sol kept daybreak_blue after switching to GPT-6 Cyber. Every send
then failed with an error that suggested selecting Standard, which a cyber
model cannot run either.

Daybreak is now one per-chat toggle in chat and new-session controls. The
model's advertised programs decide Blue or Red, shown as a caption. Models
that cannot run at Standard show the toggle locked on with "Required by this
model". A model switch sends the remapped program in the same sessions.patch,
new-session drafts submit the model's required program, and a stale saved
program renders the toggle off so turning it on repairs the chat in place.
The remembered Blue/Red preference is removed. Runtime errors in the
embedded runner and Codex harness now name the supported programs and the
next step.
@clawsweeper

clawsweeper Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 24, 2026 •

Copy link
Copy Markdown
Contributor
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-24T02:38:07.746118Z 842fde1 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: web-ui App: web-ui agents Agent runtime and tooling extensions: codex size: XL labels Nov 24, 2026
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. P2 Normal backlog priority with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 24, 2026
@clawsweeper

clawsweeper Bot commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge.

What this changes

This PR replaces the Blue/Red chooser with a model-aware Daybreak toggle and remaps access when switching models.

Example: Switch a chat using Daybreak Blue to a model requiring Daybreak Red.

  • Before: The model changes while daybreak_blue remains saved, causing subsequent sends to fail.
  • After: One sessions.patch changes both the model and cyberAccessProgram to daybreak_red.

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) Useful, focused repair with inspected visual evidence, one concrete presentation defect, and incomplete behavioral and upgrade proof.
Proof confidence 🦪 silver shellfish (2/6) Real behavior proof is not required for maintainer- or bot-authored pull requests.
Patch quality 🦐 gold shrimp (3/6) 1 actionable review finding remain.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Changing to a model requiring another Daybreak program leaves the chat unable to send and gives misleading recovery guidance.
Reason: The maintainer-approved direction repairs a demonstrated workflow through existing capability and session owners.

Merge readiness

⛔ Blocked before merge - 2 items remain

Keep open: this PR addresses a concrete model-switch failure with approved direction, but introduces a mismatch between the displayed and submitted Daybreak setting in new drafts.

Priority: P2
Reviewed head: 8eeebf83cf5b3d6ef73fcc7dda96705bd41be613

Before merge

  • Display the normalized required program in new drafts (P2) - For a new draft whose model advertises only daybreak_red but defaults to standard—the fixture added in model-control.test.ts—this returns Red for submission while renderProps still supplies Standard from accessProgramDefault. The control consequently renders unchecked and enabled, yet prepareDraftSubmission later calls initializeAccessProgram and sends Red without another toggle action. Render the normalized draft submission value before sending so the visible setting matches the request; retain the separate stale-selection repair behavior for existing chats.
  • Add data-model compatibility proof - The review found that existing stored data may not work after upgrade. Show that existing data still loads and works with this change.

Findings

  • [P2] Display the normalized required program in new drafts — ui/src/pages/new-session/model-target.ts:83-88

Tests

  • Missing end-to-end proof: Provide redacted running-Gateway output showing Blue-to-Red model switching followed by a successful send, and a latest-stable upgrade/reload preserving existing drafts and active preferences.
Agent review details

How this fits together

The Control UI derives access controls from account-scoped model capabilities and sends session settings to the Gateway; embedded and Codex runtimes enforce the advertised programs before inference.

flowchart LR
  A[Account model catalog] --> B[Daybreak resolver]
  B --> C[Chat controls]
  B --> D[New session draft]
  C --> E[Gateway session settings]
  D --> E
  E --> F[Runtime access guard]
  F --> G[Provider request]
Loading

Technical review

Best possible solution:

Keep the shared resolver and atomic session patch, and use the same normalized access value for draft rendering and submission.

Do we have a high-confidence way to reproduce the issue?

Current-main source leaves the saved program unchanged during model switches, and the PR's Red-only draft fixture exposes the new display/submission divergence without executing target code.

Is this the best way to solve the issue?

The shared capability resolver and existing session mutation owner are appropriate, but draft presentation must consume the normalized value that submission uses.

Full review comments:

  • [P2] Display the normalized required program in new drafts — ui/src/pages/new-session/model-target.ts:83-88
    For a new draft whose model advertises only daybreak_red but defaults to standard—the fixture added in model-control.test.ts—this returns Red for submission while renderProps still supplies Standard from accessProgramDefault. The control consequently renders unchecked and enabled, yet prepareDraftSubmission later calls initializeAccessProgram and sends Red without another toggle action. Render the normalized draft submission value before sending so the visible setting matches the request; retain the separate stale-selection repair behavior for existing chats.
    Confidence: 0.98

Overall correctness: patch is incorrect
Overall confidence: 0.94

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against f1debfde108a.

Provenance checked

  • Remembered color and persisted preferences changes intended behavior with a stated reason (3e1eff7: Preserve authenticated Access choices across chats and drafts independently of model-default policy.)
  • Native switch activation and save completion keeps the original intent (22e1e87: Prevent repeated activation before session and preference writes settle while retaining keyboard focus.)
  • Model-switch confirmation and session ownership keeps the original intent (f464b6e: Confirm consequential model changes and record accepted changes without entering model conversation context.)
  • Runtime Access rejection keeps the original intent (ad9b7ae: Preserve explicit Access intent and enforce role and account grants rather than silently downgrading requests.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

Acceptance criteria:

  • pnpm --dir ui test src/pages/new-session/model-control.test.ts
  • pnpm --dir ui test src/pages/chat/components/chat-model-preferences.test.tsx
  • pnpm tsgo:ui
  • git diff --check
  • Verify that a Red-only new draft displays Daybreak checked and locked before submission and submits daybreak_red.

What I checked:

  • Pinned change and current main: The introduced diff adds model/access remapping; fetched main still patches only model and runtime, so the central repair remains necessary. (ui/src/pages/chat/chat-session.ts:407, 8eeebf83cf5b)
  • Draft display/submission divergence: Submission normalizes a Red-only model to daybreak_red, while renderProps still supplies the saved value or catalog default; initializeAccessProgram runs during submission preparation. (ui/src/pages/new-session/model-target.ts:88, 8eeebf83cf5b)
  • Visual evidence inspected: The four prepared screenshots show the stale Blue chooser becoming one unchecked toggle with a required-model hint; they use a mocked Gateway and do not demonstrate a successful model switch and subsequent inference. (8eeebf83cf5b)
  • Persisted preference boundary: The PR removes daybreakAccessProgram from IndexedDB modelSelection and authenticated new-session preferences while retaining cyberAccessProgram; the supplied evidence contains no latest-stable upgrade/reload scenario. (ui/src/lib/chat/composer-draft-store-codec.ts:113, 8eeebf83cf5b)
  • Original preference intent: fix(ui): preserve Daybreak choices across chats #185039 established authenticated, agent-scoped remembered Access choices; this PR explicitly replaces remembered color with model-derived color while retaining the active selection. (ui/src/pages/new-session/model-selection.ts:117, 3e1eff7f703c)
  • Accepted behavior tradeoff: The maintainer-authored direction explicitly accepts that selecting a cyber model enables Daybreak and switching back preserves it as Blue; it also scopes non-Control-UI runtime defaults to a separate follow-up. (8eeebf83cf5b)

Likely related people:

  • Peter Steinberger: Raw commit 22e1e87 adds ui/src/pages/chat/components/chat-access-program-control.tsx:29 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 22e1e87fc6f9; files: ui/src/pages/chat/components/chat-access-program-control.tsx)
  • Vyctor H. Brzezowski: Raw commit 3e1eff7 adds ui/src/pages/chat/components/chat-access-program-control.tsx:10 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 3e1eff7f703c; files: ui/src/pages/chat/components/chat-access-program-control.tsx)

PR surface

Source -106, Tests -64, Docs +4. Total -166 across 35 files. Added test files: 1.

View PR surface stats
Area Files Added Removed Net
Source 24 211 317 -106
Tests 10 398 462 -64
Docs 1 12 8 +4
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 35 621 787 -166

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Review metrics

Metric Value Why it matters
Production versus test changes Production +211/−317; tests +398/−462 Removing the chooser and remembered-color plumbing reduces production code; the remaining growth serves shared resolution and model-switch repair.

Labels

Label changes:

  • add P2: This fixes a specific model/access workflow failure, with one bounded draft presentation defect remaining.
  • add rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🦐 gold shrimp.
  • add status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.

Label justifications:

  • P2: This fixes a specific model/access workflow failure, with one bounded draft presentation defect remaining.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🦐 gold shrimp.
  • status: ⏳ waiting on author: ClawSweeper has contributor-facing work open and is waiting for author action.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed November 23, 2026, 8:01 PM ET / November 24, 2026, 01:01 UTC.

@openclaw-barnacle openclaw-barnacle Bot added the scripts Repository scripts label Nov 24, 2026
A new draft on a model that requires Daybreak Red displayed the catalog default (Standard) while submission normalized to Red. Drafts now render the same normalized program they submit. Adds a legacy stored-draft decode test for the retired remembered color.

@THE-NAVVV THE-NAVVV left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

​

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1a3e659af4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

A new draft that starts on a Red-only model shows and submits Daybreak Red, but the model switch remapped from the raw catalog default (Standard), so switching to a mainline model dropped Daybreak. The switch now remaps from the same normalized program the draft displays and submits, carrying it over as Blue.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a5a4f5a4f5

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread ui/src/pages/chat/chat-session.ts Resolved
When Daybreak was on only through the current model's configured default, switching to a model with the same program but a Standard default wrote nothing and Daybreak turned off. Chat and new-session model switches now store the destination's program whenever Daybreak stays on and that exact program is not already stored.
@steipete
steipete enabled auto-merge (squash) November 24, 2026 02:02
@steipete
steipete disabled auto-merge November 24, 2026 02:35
@steipete
steipete merged commit 5a4cb12 into main Nov 24, 2026
229 of 249 checks passed
@steipete
steipete deleted the fix/daybreak-single-toggle branch November 24, 2026 03:40
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via explicitly authorized admin squash with attributed pre-existing CI failures.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 24, 2026
…#204302)

* fix(ui): make Daybreak one toggle that follows the model

Each OpenAI model supports exactly one Daybreak program: mainline models
take Daybreak Blue (or Standard), cyber models take Daybreak Red only. The
chat popover still offered a Blue/Red chooser, so GPT-6 Cyber showed
"Blue (unavailable)" next to "Red", and a chat that turned Blue on with
GPT-6.2 Sol kept daybreak_blue after switching to GPT-6 Cyber. Every send
then failed with an error that suggested selecting Standard, which a cyber
model cannot run either.

Daybreak is now one per-chat toggle in chat and new-session controls. The
model's advertised programs decide Blue or Red, shown as a caption. Models
that cannot run at Standard show the toggle locked on with "Required by this
model". A model switch sends the remapped program in the same sessions.patch,
new-session drafts submit the model's required program, and a stale saved
program renders the toggle off so turning it on repairs the chat in place.
The remembered Blue/Red preference is removed. Runtime errors in the
embedded runner and Codex harness now name the supported programs and the
next step.

* fix(ui): resolve Daybreak test type import and record chat boot cost

* fix(ui): show the Daybreak program a new draft will submit

A new draft on a model that requires Daybreak Red displayed the catalog default (Standard) while submission normalized to Red. Drafts now render the same normalized program they submit. Adds a legacy stored-draft decode test for the retired remembered color.

* fix(ui): carry a draft's required Daybreak program across model switches

A new draft that starts on a Red-only model shows and submits Daybreak Red, but the model switch remapped from the raw catalog default (Standard), so switching to a mainline model dropped Daybreak. The switch now remaps from the same normalized program the draft displays and submits, carrying it over as Blue.

* fix(ui): keep an inherited Daybreak program on across model switches

When Daybreak was on only through the current model's configured default, switching to a model with the same program but a Standard default wrote nothing and Daybreak turned off. Chat and new-session model switches now store the destination's program whenever Daybreak stays on and that exact program is not already stored.
tideclaw-bot pushed a commit that referenced this pull request Nov 28, 2026
…l UI (#204325)

* fix(agents): default Access to a model's only advertised program

Cyber models advertise only Daybreak Red and reject Standard, but the runtime default fell back to Standard whenever no accessPrograms.cyber was configured, so unconfigured cyber-model turns outside the Control UI failed with invalid_access_program. The default now follows the selected account's advertised programs from the prepared model catalog for both the catalog projection and the physical request.

* test(agents): satisfy test typecheck for Access default contracts

* test(agents): give the overflow-compaction runtime fixture its isCurrent contract

* fix(agents): read advertised Access programs only on routes that send one

Dispatch now skips the prepared-catalog account read for providers and routes that never send an Access program, so non-OpenAI turns do no extra account-catalog work. The default resolver and dispatch share one route predicate.

(cherry picked from commit 862c71e)

Release adaptation: Keep stable's Daybreak toggle and separate Access selector wording; document the advertised single-program default and stale-choice error without importing the UI behavior from #204302. Include eccac8a (#204461), which keeps the attempt lookup private and tests the dispatch wrapper. Role, current-account, and entitlement checks are unchanged.

Later same-file changes not needed: a1ba2bc (#204545) is newer Control UI behavior; d2699a8 (#204847) adds separate participation limits; f00839d adds MCP requester propagation; 26f82df (#205687) adds streaming preflight progress; 41dc731 (#195479) retains transcript targets across catalog reloads; 4ff18a0 changes project-move prompt inputs. None is a dependency of the Access default.

Co-authored-by: RomneyDa <[email protected]>
tideclaw-bot pushed a commit that referenced this pull request Nov 30, 2026
Release adaptation: Use the advertised program at the stable chat switch and draft submission owners; keep the account fence, existing settings field, confirmation path and native guards. Do not import the toggle/persistence redesign.

Pinned companion audit: No pinned #204302 or source-SHA follow-up cites this fix. Later switch, persistence, and visual changes are not prerequisites for the same-account remap.

(cherry picked from commit 5a4cb12)

Co-authored-by: RomneyDa <[email protected]>
tideclaw-bot pushed a commit that referenced this pull request Nov 30, 2026
* fix(ui): make Daybreak one toggle that follows the model

Each OpenAI model supports exactly one Daybreak program: mainline models
take Daybreak Blue (or Standard), cyber models take Daybreak Red only. The
chat popover still offered a Blue/Red chooser, so GPT-6 Cyber showed
"Blue (unavailable)" next to "Red", and a chat that turned Blue on with
GPT-6.2 Sol kept daybreak_blue after switching to GPT-6 Cyber. Every send
then failed with an error that suggested selecting Standard, which a cyber
model cannot run either.

Daybreak is now one per-chat toggle in chat and new-session controls. The
model's advertised programs decide Blue or Red, shown as a caption. Models
that cannot run at Standard show the toggle locked on with "Required by this
model". A model switch sends the remapped program in the same sessions.patch,
new-session drafts submit the model's required program, and a stale saved
program renders the toggle off so turning it on repairs the chat in place.
The remembered Blue/Red preference is removed. Runtime errors in the
embedded runner and Codex harness now name the supported programs and the
next step.

* fix(ui): resolve Daybreak test type import and record chat boot cost

* fix(ui): show the Daybreak program a new draft will submit

A new draft on a model that requires Daybreak Red displayed the catalog default (Standard) while submission normalized to Red. Drafts now render the same normalized program they submit. Adds a legacy stored-draft decode test for the retired remembered color.

* fix(ui): carry a draft's required Daybreak program across model switches

A new draft that starts on a Red-only model shows and submits Daybreak Red, but the model switch remapped from the raw catalog default (Standard), so switching to a mainline model dropped Daybreak. The switch now remaps from the same normalized program the draft displays and submits, carrying it over as Blue.

* fix(ui): keep an inherited Daybreak program on across model switches

When Daybreak was on only through the current model's configured default, switching to a model with the same program but a Standard default wrote nothing and Daybreak turned off. Chat and new-session model switches now store the destination's program whenever Daybreak stays on and that exact program is not already stored.

(cherry picked from commit 5a4cb12)

Release adaptation: Preserve the beta release chat-boot budget and its existing single-program default documentation; do not import main-only budget increases.

Co-authored-by: RomneyDa <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling app: web-ui App: web-ui docs Improvements or additions to documentation extensions: codex P2 Normal backlog priority with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. scripts Repository scripts size: XL status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants