Repository navigation
fix(web-shell): persist model reasoning preferences #10489
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 9 commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
14673c7
fix(web-shell): persist model reasoning preferences
callmeYe 6a9bf19
fix(web-shell): retain reasoning preview for new tasks
callmeYe 4885a6b
fix(web-shell): ignore stale reasoning provider snapshots
callmeYe 41beaa6
Merge remote-tracking branch 'origin/main' into codex/fix-webshell-re…
callmeYe 7ac6790
Merge remote-tracking branch 'origin/main' into codex/fix-webshell-re…
wenshao b5f5359
fix(web-shell): harden reasoning preference persistence
callmeYe a1b2513
fix(web-shell): correct daemon SDK test import
callmeYe 9c63c7f
Merge remote-tracking branch 'origin/main' into codex/fix-webshell-re…
callmeYe 0c456eb
Merge branch 'main' into codex/fix-webshell-reasoning-preferences
wenshao d9cf27f
Merge branch 'main' into codex/fix-webshell-reasoning-preferences
qwen-code-dev-bot 049e911
fix(web-shell): preserve reasoning across scoped session transitions
callmeYe bedaf5e
Merge remote-tracking branch 'origin/codex/fix-webshell-reasoning-pre…
callmeYe 41630dd
Merge remote-tracking branch 'origin/main' into codex/fix-webshell-re…
callmeYe 17e56a5
Merge remote-tracking branch 'origin/main' into codex/fix-webshell-re…
callmeYe 0f9d98b
Merge remote-tracking branch 'origin/main' into codex/fix-webshell-re…
callmeYe a4664e9
refactor(web-shell): consolidate reasoning preferences and tests
callmeYe 175f524
test(serve): complete workspace facade reasoning mock
callmeYe 80399bc
fix(web-shell): retain reasoning preferences across auth refresh
callmeYe 26f5826
fix(web-shell): honor reasoning preferences after model reload
callmeYe 896e360
fix(web-shell): retain session reasoning across rebuilds
callmeYe 3eebaea
fix(web-shell): reconcile reasoning settings reloads
callmeYe File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,66 @@ | ||
| # WebShell model reasoning preferences | ||
|
|
||
| ## Goal | ||
|
|
||
| WebShell keeps the selected model and reasoning preference across daemon | ||
| sessions without creating an empty session from the Welcome screen. The first | ||
| prompt remains the session-creation boundary. | ||
|
|
||
| This change uses the existing `model.reasoningEffort` setting. It does not add | ||
| a second reasoning-enabled setting and does not change provider request | ||
| mapping or the public ACP protocol. | ||
|
|
||
| ## Stored values | ||
|
|
||
| `model.reasoningEffort` has one meaning at every daemon boundary: | ||
|
|
||
| - an absent value uses the target model's default thinking behavior; | ||
| - `none` disables thinking; | ||
| - `low`, `medium`, `high`, `xhigh`, or `max` enables thinking at that tier. | ||
|
|
||
| `default` is a control command only. It removes the stored value and resets the | ||
| live session to the model default. It is never stored and is never rendered as | ||
| an effort choice. | ||
|
|
||
| The Core `ReasoningEffort` type remains the five strict tiers. `none` and | ||
| `default` are represented only by the daemon and settings boundary type. | ||
|
|
||
| ## Session lifecycle | ||
|
|
||
| Before a session exists, WebShell keeps the selected model and reasoning value | ||
| in component state. Sending the first prompt performs these operations in | ||
| order: create, attach, set model, persist reasoning, then submit the prompt. | ||
|
|
||
| For a live session, WebShell sends reasoning changes immediately with | ||
| `persist: true`. It updates its state only from the daemon's confirmed | ||
| `configOptions` response. The daemon writes the setting and live state before | ||
| returning success. | ||
|
|
||
| Turning thinking off sends `none`. Turning it on again sends `default`, which | ||
| removes `none` and uses the model default instead of restoring the old tier. | ||
|
|
||
| ## Capability reconciliation | ||
|
|
||
| Every model switch reconciles the stored selection against the target model: | ||
|
|
||
| - a supported tier and an allowed `none` value are retained; | ||
| - an unsupported tier is removed and the live override is reset; | ||
| - a toggle-only model retains only `none` when disabling is allowed; | ||
| - a model without reasoning controls removes every explicit selection; | ||
| - mandatory thinking removes `none`. | ||
|
|
||
| There is no fallback or tier clamping at this layer. Once an incompatible | ||
| selection is removed, switching back does not restore it. | ||
|
|
||
| Welcome uses model-specific workspace previews. Once a session exists, | ||
| WebShell renders reasoning controls only from that session's authoritative | ||
| `configOptions`. | ||
|
|
||
| ## UI and localization | ||
|
|
||
| Tiered models render only the real advertised tiers. Toggle-only models render | ||
| only the thinking switch: no effort heading, effort row, or Default choice is | ||
| present in the DOM. Unsupported models render no reasoning section. | ||
|
|
||
| WebShell translates the five fixed effort values itself in English and Chinese | ||
| and never renders daemon-provided English labels. |
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.