Skip to content

fix(web): allow switching away from Ultrathink without manual prompt editing#1307

Merged
juliusmarminge merged 2 commits intopingdotgg:mainfrom
Marve10s:fix/ultrathink-effort-switching
Mar 28, 2026
Merged

fix(web): allow switching away from Ultrathink without manual prompt editing#1307
juliusmarminge merged 2 commits intopingdotgg:mainfrom
Marve10s:fix/ultrathink-effort-switching

Conversation

@Marve10s
Copy link
Copy Markdown
Contributor

@Marve10s Marve10s commented Mar 22, 2026

Summary

  • When Ultrathink was active, the effort dropdown was fully disabled and showed "Remove Ultrathink from the prompt to change effort." — forcing the user to manually edit the prompt to switch effort levels.
  • Now selecting a different effort level automatically strips the Ultrathink: prefix from the prompt and applies the new effort.
  • The radio group correctly highlights "Ultrathink" when it's active via the prompt.

Test plan

  • Select Claude Opus/Sonnet, choose Ultrathink from effort dropdown — prompt gets Ultrathink: prefix
  • While Ultrathink is active, select a different effort (e.g. High) — Ultrathink: prefix is removed, effort switches
  • Re-select Ultrathink — prefix is added back
  • Verify compact composer controls menu behaves the same way

Note

Allow switching effort away from Ultrathink when set via prompt prefix

  • When a prompt starts with Ultrathink:, users can now select a different effort level; the prefix is stripped from the prompt automatically instead of being blocked.
  • Effort controls are only disabled when ultrathink appears in the prompt body text (not the prefix), showing the warning: "Your prompt contains 'ultrathink' in the text. Remove it to change effort."
  • getSelectedTraits in TraitsPicker.tsx now distinguishes between a prefix-controlled Ultrathink and ultrathink in body text via a new ultrathinkInBodyText flag.
  • Behavioral Change: previously, any prompt-controlled Ultrathink state disabled effort controls entirely; now only body-text occurrences block switching.

Macroscope summarized f4ab8ff.


Note

Medium Risk
Medium risk because it changes how effort selection mutates the user prompt and model options; mistakes could unexpectedly rewrite prompts or apply the wrong effort.

Overview
Effort selection in TraitsPicker now allows switching away from prompt-prefixed Ultrathink: by automatically stripping the prefix and persisting the newly selected effort, instead of disabling the control.

The UI now distinguishes between Ultrathink enabled via the prefix vs occurrences of "ultrathink" in the prompt body text (ultrathinkInBodyText): only body-text cases disable effort changes and show a warning, and the radio group correctly highlights Ultrathink when the prefix is active. Browser tests for both TraitsPicker and CompactComposerControlsMenu were updated and expanded to cover the new warning behavior.

Written by Cursor Bugbot for commit f4ab8ff. This will update automatically on new commits. Configure here.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Mar 22, 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: df6e9345-bfc1-4b7c-9cfd-979e0f7d794a

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

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.

@github-actions github-actions bot added size:S 10-29 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list. labels Mar 22, 2026
@Marve10s Marve10s force-pushed the fix/ultrathink-effort-switching branch from 2fd7aff to 8a2887b Compare March 22, 2026 15:50
@juliusmarminge
Copy link
Copy Markdown
Member

screenshot/video w/ before/after pls

also, i considered this but the ultrathink can be anywhere in the prompt and i didn't wanna do a eager find-replace and mutate the users prompt, but aybe i was wrong

@Marve10s
Copy link
Copy Markdown
Contributor Author

Marve10s commented Mar 24, 2026

@juliusmarminge here you go:

Before :

zen_Bfbs8zBqAN.mp4

After :

uFhXkFyU9R.mp4

Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

@Marve10s Marve10s force-pushed the fix/ultrathink-effort-switching branch 2 times, most recently from c5d225d to ad80210 Compare March 25, 2026 08:40
…editing

When Ultrathink was active, the effort dropdown was fully disabled,
requiring the user to manually remove the "Ultrathink:" prefix from the
prompt. Now selecting a different effort level automatically strips the
prefix and applies the new effort.

If "ultrathink" also appears in the user's body text, the controls stay
disabled with a warning to remove it manually, preventing prompt mangling.
@Marve10s Marve10s force-pushed the fix/ultrathink-effort-switching branch from ad80210 to 530bc42 Compare March 26, 2026 13:45
Copy link
Copy Markdown
Member

@juliusmarminge juliusmarminge left a comment

Choose a reason for hiding this comment

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

good tradeoff. thanks

@juliusmarminge juliusmarminge merged commit 61f9830 into pingdotgg:main Mar 28, 2026
10 checks passed
AustinKelsay pushed a commit to AustinKelsay/t3code-custom that referenced this pull request Mar 29, 2026
Chrono-byte pushed a commit to Chrono-byte/t3code that referenced this pull request Mar 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S 10-29 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants