Skip to content

add enable reasoning button #6254

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 1 commit into from
Jun 23, 2025
Merged

Conversation

uinstinct
Copy link
Contributor

@uinstinct uinstinct commented Jun 23, 2025

Description

Show an enable reasoning button in the toolbar to force the model to use reasoning.
This is now only applicable for anthropic models.

  • Adds a new state hasReasoningEnabled in config reducer
  • Gets the initial state set on config refresh inside ParallelListeners

resolves CON-2296

Checklist

  • [] I've read the contributing guide
  • [] The relevant docs, if any, have been updated or created
  • [] The relevant tests, if any, have been updated or created

Screenshots

[ For visual changes, include screenshots. Screen recordings are particularly helpful, and appreciated! ]

feat.mp4

Tests

[ What tests were added or updated to ensure the changes work as expected? ]

@uinstinct uinstinct requested a review from a team as a code owner June 23, 2025 10:59
@uinstinct uinstinct requested review from sestinj and removed request for a team June 23, 2025 10:59
Copy link

netlify bot commented Jun 23, 2025

👷 Deploy request for continuedev pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 084f6cc

@dosubot dosubot bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Jun 23, 2025
@@ -86,6 +87,13 @@ function ParallelListeners() {
setLocalStorage("fontSize", configResult.config.ui.fontSize);
document.body.style.fontSize = `${configResult.config.ui.fontSize}px`;
}

if (
configResult.config?.selectedModelByRole.chat?.completionOptions
Copy link

Choose a reason for hiding this comment

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

Unsafe property access chain: When config is optional (accessed with ?.), selectedModelByRole is accessed without optional chaining. This can cause runtime errors if config exists but selectedModelByRole is undefined. Based on codebase patterns, selectedModelByRole should be accessed with optional chaining when config is optional. Fix: Change to configResult.config?.selectedModelByRole?.chat?.completionOptions


React with 👍 to tell me that this comment was useful, or 👎 if not (and I'll stop posting more comments like this in the future)

Copy link

recurseml bot commented Jun 23, 2025

😱 Found 1 issue. Time to roll up your sleeves! 😱

Copy link
Contributor

@sestinj sestinj left a comment

Choose a reason for hiding this comment

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

Nicely done! No comments necessary, this will be a good experiment to see how users like it

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Jun 23, 2025
@github-project-automation github-project-automation bot moved this from Todo to In Progress in Issues and PRs Jun 23, 2025
@sestinj sestinj merged commit 18c9f71 into continuedev:main Jun 23, 2025
59 of 62 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in Issues and PRs Jun 23, 2025
@github-actions github-actions bot locked and limited conversation to collaborators Jun 23, 2025
@uinstinct uinstinct deleted the reasoning-button branch June 23, 2025 18:30
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm This PR has been approved by a maintainer size:M This PR changes 30-99 lines, ignoring generated files.
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants