Skip to content

feat(web): persist model, thinking and fast mode in new threads#1121

Open
maria-rcks wants to merge 3 commits intopingdotgg:mainfrom
maria-rcks:feat/sticky-codex-composer-settings
Open

feat(web): persist model, thinking and fast mode in new threads#1121
maria-rcks wants to merge 3 commits intopingdotgg:mainfrom
maria-rcks:feat/sticky-codex-composer-settings

Conversation

@maria-rcks
Copy link
Collaborator

@maria-rcks maria-rcks commented Mar 15, 2026

What Changed

  • persist the last used Codex model, thinking effort, and fast mode in local browser state
  • use those values as the defaults for new threads
  • keep explicit thread choices from being overwritten by the sticky defaults

Why

When you changed these in one thread and opened another, they reset.

This keeps the last used Codex settings sticky across thread switching and app reloads, without changing plan mode or access mode.

I and some people may prefer models in medium over high and only would want to use high in some threads

Closes #384

Supersedes #1004
Supersedes #1056

Checklist

  • This PR is small and focused
  • I explained what changed and why
  • I included before/after screenshots for any UI changes
  • I included a video for animation/interaction changes
151224.mp4

(sorry for the crappy demo, the macbook its on its way)

Note

Persist model, reasoning effort, and fast mode across new threads in the composer

  • Adds a new useStickyComposerSettings hook that reads and writes composer settings (model, effort, codexFastMode) to localStorage, with schema validation and model slug normalization.
  • Updates useHandleNewThread to initialize new draft threads with the persisted sticky settings, falling back to the provider default effort when no sticky value exists.
  • Updates ChatView to write back to sticky settings whenever the user selects a Codex model, changes reasoning effort, or toggles fast mode.
  • Extends composerDraftStore with hasEffortOverride and hasCodexFastModeOverride flags so drafts are retained even when the overridden values are defaults (e.g. effort null or fast mode false).
  • Behavioral Change: calling setEffort or setCodexFastMode now always creates/retains a draft entry due to the new override flags, where previously a null/false value would skip draft creation.

Macroscope summarized ae19079.

@coderabbitai
Copy link

coderabbitai bot commented Mar 15, 2026

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 3effbeba-013c-4a46-bb5c-9aed7cd17d9a

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Tip

You can validate your CodeRabbit configuration file in your editor.

If your editor has YAML language server, you can enable auto-completion and validation by adding # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json at the top of your CodeRabbit configuration file.

@github-actions github-actions bot added size:L 100-499 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. labels Mar 15, 2026
@maria-rcks maria-rcks changed the title feat(web): persist sticky codex model settings feat(web): persist model, thinking and fast mode in new threads Mar 15, 2026
@zortos293
Copy link
Contributor

Very needed QOL feature. It’s very annoying having to switch models every time you start a new thread.

@maskdotdev
Copy link
Contributor

maskdotdev commented Mar 15, 2026

Updating fast mode in newer threads affects the mode in older threads see below:

Edit: Looked a bit deeper, it seems older threads only stay isolated if they have an explicit per thread override in the draft store. If they do not, they inherit the shared sticky value

pr1121-review-compressed-noaudio.mp4

@maria-rcks
Copy link
Collaborator Author

@maskdotdev lmk if its fixed now

@maskdotdev
Copy link
Contributor

@maskdotdev lmk if its fixed now

awesome work! its fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(settings): ability to change default thinking level

3 participants