feat: restore dedicated model selector for context condensing#11988
Draft
roomote-v0[bot] wants to merge 1 commit intomainfrom
Draft
feat: restore dedicated model selector for context condensing#11988roomote-v0[bot] wants to merge 1 commit intomainfrom
roomote-v0[bot] wants to merge 1 commit intomainfrom
Conversation
Adds a condensingApiConfigId setting that allows users to select a dedicated API configuration for context condensing operations. This restores the ability to use a cheaper/faster model (e.g. Gemini Flash) for condensing while keeping an expensive model (e.g. Claude Opus) as the active coding model. Changes: - Add condensingApiConfigId to global settings schema and ExtensionState - Add webview message handler for condensingApiConfigId - Build dedicated API handler in Task.ts for manual and auto condensing - Add API config dropdown in ContextManagementSettings UI - Update tests for new combobox count and default props Closes #11785
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Related GitHub Issue
Closes: #11785
Description
This PR attempts to address Issue #11785 by restoring the dedicated model selector for context condensing. Feedback and guidance are welcome.
Problem: The option to select a dedicated model for context condensing was removed in PR #10901. Users who rely on expensive models (e.g., Claude Opus) for coding had no way to use a cheaper model (e.g., Gemini Flash) for condensing, leading to high costs or broken workflows when manually switching models.
Solution: Adds a
condensingApiConfigIdsetting that allows users to select a dedicated API configuration for condensing operations. Key implementation details:condensingApiConfigIdtoGlobalSettingsschema andExtensionStateTask.tsgains abuildCondensingApiHandler()method that creates a separate API handler when a dedicated config is set, falling back to the task's main handler otherwise. This handler is used in all three condensing call sites (manual condense, auto condense inattemptApiRequest, and context window exceeded recovery)condensingApiConfigIdwebview message handler (same pattern asenhancementApiConfigId)The existing
transformMessagesForCondensing()safeguard that converts tool blocks to text before sending to the condensing API is preserved, which handles cross-provider compatibility concerns.Test Procedure
To manually test:
Pre-Submission Checklist
Interactively review PR in Roo Code Cloud