From 99c5bf2e97a79456c309755cedaf3aeee41239c0 Mon Sep 17 00:00:00 2001 From: Adib234 <30782825+Adib234@users.noreply.github.com> Date: Fri, 21 Nov 2025 09:54:17 -0800 Subject: [PATCH] Remove useModelRouter experimental flag (#13593) --- docs/cli/model-routing.md | 17 +-- docs/cli/settings.md | 9 +- docs/get-started/configuration.md | 6 - packages/cli/src/config/config.test.ts | 122 ------------------ packages/cli/src/config/config.ts | 7 +- .../cli/src/config/settingsSchema.test.ts | 15 --- packages/cli/src/config/settingsSchema.ts | 10 -- .../src/services/BuiltinCommandLoader.test.ts | 24 ---- .../cli/src/services/BuiltinCommandLoader.ts | 2 +- .../src/ui/components/ModelDialog.test.tsx | 1 - .../cli/src/ui/hooks/useGeminiStream.test.tsx | 1 - .../cli/src/ui/hooks/useToolScheduler.test.ts | 1 - packages/core/src/config/config.test.ts | 93 ------------- packages/core/src/config/config.ts | 20 --- packages/core/src/core/client.test.ts | 1 - .../core/src/core/coreToolScheduler.test.ts | 1 - .../core/nonInteractiveToolExecutor.test.ts | 1 - .../clearcut-logger/clearcut-logger.test.ts | 2 +- packages/core/src/telemetry/loggers.test.ts | 3 - packages/core/src/tools/smart-edit.test.ts | 1 - schemas/settings.schema.json | 7 - 21 files changed, 8 insertions(+), 336 deletions(-) diff --git a/docs/cli/model-routing.md b/docs/cli/model-routing.md index 4d01434f28..d98d875421 100644 --- a/docs/cli/model-routing.md +++ b/docs/cli/model-routing.md @@ -25,18 +25,6 @@ Here's how it works: `packages/cli/src/zed-integration/zedIntegration.ts` which checks if `isInFallbackMode()` is true. -## Configuration - -Model routing is controlled by the `useModelRouter` setting in your -`settings.json` file. - -- **`"experimental.useModelRouter": true` (Default):** Enables the model - routing/fallback feature. - -- **`"experimental.useModelRouter": false`:** Disables the model - routing/fallback feature. If a model fails, the CLI will not attempt to switch - to a fallback model. - ### Model Selection Precedence The model used by Gemini CLI is determined by the following order of precedence: @@ -50,7 +38,4 @@ The model used by Gemini CLI is determined by the following order of precedence: model specified in the `model.name` property of your `settings.json` file will be used. 4. **Default Model:** If none of the above are set, the default model will be - used. The default model is determined by the `useModelRouter` setting: - - If `useModelRouter` is `true`, the default model is `"auto"`. - - If `useModelRouter` is `false`, the default model is the standard Gemini - model. + used. The default model is `auto` diff --git a/docs/cli/settings.md b/docs/cli/settings.md index 9c5784108d..01ca1afdac 100644 --- a/docs/cli/settings.md +++ b/docs/cli/settings.md @@ -106,8 +106,7 @@ they appear in the UI. ### Experimental -| UI Label | Setting | Description | Default | -| ----------------------------------- | ------------------------------------------------------- | ----------------------------------------------------------------------------- | ------- | -| Use Model Router | `experimental.useModelRouter` | Enable model routing to route requests to the best model based on complexity. | `true` | -| Enable Codebase Investigator | `experimental.codebaseInvestigatorSettings.enabled` | Enable the Codebase Investigator agent. | `true` | -| Codebase Investigator Max Num Turns | `experimental.codebaseInvestigatorSettings.maxNumTurns` | Maximum number of turns for the Codebase Investigator agent. | `10` | +| UI Label | Setting | Description | Default | +| ----------------------------------- | ------------------------------------------------------- | ------------------------------------------------------------ | ------- | +| Enable Codebase Investigator | `experimental.codebaseInvestigatorSettings.enabled` | Enable the Codebase Investigator agent. | `true` | +| Codebase Investigator Max Num Turns | `experimental.codebaseInvestigatorSettings.maxNumTurns` | Maximum number of turns for the Codebase Investigator agent. | `10` | diff --git a/docs/get-started/configuration.md b/docs/get-started/configuration.md index 33e4926ec1..e0e9412865 100644 --- a/docs/get-started/configuration.md +++ b/docs/get-started/configuration.md @@ -563,12 +563,6 @@ their corresponding top-level category object in your `settings.json` file. - **Default:** `false` - **Requires restart:** Yes -- **`experimental.useModelRouter`** (boolean): - - **Description:** Enable model routing to route requests to the best model - based on complexity. - - **Default:** `true` - - **Requires restart:** Yes - - **`experimental.codebaseInvestigatorSettings.enabled`** (boolean): - **Description:** Enable the Codebase Investigator agent. - **Default:** `true` diff --git a/packages/cli/src/config/config.test.ts b/packages/cli/src/config/config.test.ts index 020592c903..a8d0493691 100644 --- a/packages/cli/src/config/config.test.ts +++ b/packages/cli/src/config/config.test.ts @@ -9,8 +9,6 @@ import * as os from 'node:os'; import * as path from 'node:path'; import { DEFAULT_FILE_FILTERING_OPTIONS, - DEFAULT_GEMINI_MODEL, - DEFAULT_GEMINI_MODEL_AUTO, OutputFormat, SHELL_TOOL_NAME, WRITE_FILE_TOOL_NAME, @@ -1364,100 +1362,6 @@ describe('loadCliConfig model selection', () => { }); }); -describe('loadCliConfig model selection with model router', () => { - beforeEach(() => { - vi.spyOn(ExtensionManager.prototype, 'getExtensions').mockReturnValue([]); - }); - - afterEach(() => { - vi.resetAllMocks(); - }); - - it('should use auto model when useModelRouter is true and no model is provided', async () => { - process.argv = ['node', 'script.js']; - const argv = await parseArguments({} as Settings); - const config = await loadCliConfig( - { - experimental: { - useModelRouter: true, - }, - }, - 'test-session', - argv, - ); - - expect(config.getModel()).toBe(DEFAULT_GEMINI_MODEL_AUTO); - }); - - it('should use default model when useModelRouter is false and no model is provided', async () => { - process.argv = ['node', 'script.js']; - const argv = await parseArguments({} as Settings); - const config = await loadCliConfig( - { - experimental: { - useModelRouter: false, - }, - }, - 'test-session', - argv, - ); - - expect(config.getModel()).toBe(DEFAULT_GEMINI_MODEL); - }); - - it('should prioritize argv over useModelRouter', async () => { - process.argv = ['node', 'script.js', '--model', 'gemini-from-argv']; - const argv = await parseArguments({} as Settings); - const config = await loadCliConfig( - { - experimental: { - useModelRouter: true, - }, - }, - 'test-session', - argv, - ); - - expect(config.getModel()).toBe('gemini-from-argv'); - }); - - it('should prioritize settings over useModelRouter', async () => { - process.argv = ['node', 'script.js']; - const argv = await parseArguments({} as Settings); - const config = await loadCliConfig( - { - experimental: { - useModelRouter: true, - }, - model: { - name: 'gemini-from-settings', - }, - }, - 'test-session', - argv, - ); - - expect(config.getModel()).toBe('gemini-from-settings'); - }); - - it('should prioritize environment variable over useModelRouter', async () => { - process.argv = ['node', 'script.js']; - vi.stubEnv('GEMINI_MODEL', 'gemini-from-env'); - const argv = await parseArguments({} as Settings); - const config = await loadCliConfig( - { - experimental: { - useModelRouter: true, - }, - }, - 'test-session', - argv, - ); - - expect(config.getModel()).toBe('gemini-from-env'); - }); -}); - describe('loadCliConfig folderTrust', () => { beforeEach(() => { vi.resetAllMocks(); @@ -1633,32 +1537,6 @@ describe('loadCliConfig useRipgrep', () => { const config = await loadCliConfig(settings, 'test-session', argv); expect(config.getUseRipgrep()).toBe(true); }); - - describe('loadCliConfig useModelRouter', () => { - it('should be true by default when useModelRouter is not set in settings', async () => { - process.argv = ['node', 'script.js']; - const argv = await parseArguments({} as Settings); - const settings: Settings = {}; - const config = await loadCliConfig(settings, 'test-session', argv); - expect(config.getUseModelRouter()).toBe(true); - }); - - it('should be true when useModelRouter is set to true in settings', async () => { - process.argv = ['node', 'script.js']; - const argv = await parseArguments({} as Settings); - const settings: Settings = { experimental: { useModelRouter: true } }; - const config = await loadCliConfig(settings, 'test-session', argv); - expect(config.getUseModelRouter()).toBe(true); - }); - - it('should be false when useModelRouter is explicitly set to false in settings', async () => { - process.argv = ['node', 'script.js']; - const argv = await parseArguments({} as Settings); - const settings: Settings = { experimental: { useModelRouter: false } }; - const config = await loadCliConfig(settings, 'test-session', argv); - expect(config.getUseModelRouter()).toBe(false); - }); - }); }); describe('screenReader configuration', () => { diff --git a/packages/cli/src/config/config.ts b/packages/cli/src/config/config.ts index f39c981122..8bd63473ba 100755 --- a/packages/cli/src/config/config.ts +++ b/packages/cli/src/config/config.ts @@ -15,7 +15,6 @@ import { setGeminiMdFilename as setServerGeminiMdFilename, getCurrentGeminiMdFilename, ApprovalMode, - DEFAULT_GEMINI_MODEL, DEFAULT_GEMINI_MODEL_AUTO, DEFAULT_GEMINI_EMBEDDING_MODEL, DEFAULT_FILE_FILTERING_OPTIONS, @@ -580,10 +579,7 @@ export async function loadCliConfig( extraExcludes.length > 0 ? extraExcludes : undefined, ); - const useModelRouter = settings.experimental?.useModelRouter ?? true; - const defaultModel = useModelRouter - ? DEFAULT_GEMINI_MODEL_AUTO - : DEFAULT_GEMINI_MODEL; + const defaultModel = DEFAULT_GEMINI_MODEL_AUTO; const resolvedModel: string = argv.model || process.env['GEMINI_MODEL'] || @@ -674,7 +670,6 @@ export async function loadCliConfig( output: { format: (argv.outputFormat ?? settings.output?.format) as OutputFormat, }, - useModelRouter, enableMessageBusIntegration, codebaseInvestigatorSettings: settings.experimental?.codebaseInvestigatorSettings, diff --git a/packages/cli/src/config/settingsSchema.test.ts b/packages/cli/src/config/settingsSchema.test.ts index 090d56bdd5..c8350a94c1 100644 --- a/packages/cli/src/config/settingsSchema.test.ts +++ b/packages/cli/src/config/settingsSchema.test.ts @@ -345,21 +345,6 @@ describe('SettingsSchema', () => { getSettingsSchema().general.properties.previewFeatures.description, ).toBe('Enable preview features (e.g., preview models).'); }); - - it('should have useModelRouter setting in schema', () => { - expect( - getSettingsSchema().experimental.properties.useModelRouter, - ).toBeDefined(); - expect( - getSettingsSchema().experimental.properties.useModelRouter.type, - ).toBe('boolean'); - expect( - getSettingsSchema().experimental.properties.useModelRouter.category, - ).toBe('Experimental'); - expect( - getSettingsSchema().experimental.properties.useModelRouter.default, - ).toBe(true); - }); }); it('has JSON schema definitions for every referenced ref', () => { diff --git a/packages/cli/src/config/settingsSchema.ts b/packages/cli/src/config/settingsSchema.ts index 8bde95604c..2eb7958460 100644 --- a/packages/cli/src/config/settingsSchema.ts +++ b/packages/cli/src/config/settingsSchema.ts @@ -1281,16 +1281,6 @@ const SETTINGS_SCHEMA = { 'Enables extension loading/unloading within the CLI session.', showInDialog: false, }, - useModelRouter: { - type: 'boolean', - label: 'Use Model Router', - category: 'Experimental', - requiresRestart: true, - default: true, - description: - 'Enable model routing to route requests to the best model based on complexity.', - showInDialog: true, - }, codebaseInvestigatorSettings: { type: 'object', label: 'Codebase Investigator Settings', diff --git a/packages/cli/src/services/BuiltinCommandLoader.test.ts b/packages/cli/src/services/BuiltinCommandLoader.test.ts index 49792cb081..09de4b4fa8 100644 --- a/packages/cli/src/services/BuiltinCommandLoader.test.ts +++ b/packages/cli/src/services/BuiltinCommandLoader.test.ts @@ -95,7 +95,6 @@ describe('BuiltinCommandLoader', () => { vi.clearAllMocks(); mockConfig = { getFolderTrust: vi.fn().mockReturnValue(true), - getUseModelRouter: () => false, getEnableMessageBusIntegration: () => false, getEnableExtensionReloading: () => false, } as unknown as Config; @@ -168,28 +167,6 @@ describe('BuiltinCommandLoader', () => { expect(permissionsCmd).toBeUndefined(); }); - it('should include modelCommand when getUseModelRouter is true', async () => { - const mockConfigWithModelRouter = { - ...mockConfig, - getUseModelRouter: () => true, - } as unknown as Config; - const loader = new BuiltinCommandLoader(mockConfigWithModelRouter); - const commands = await loader.loadCommands(new AbortController().signal); - const modelCmd = commands.find((c) => c.name === 'model'); - expect(modelCmd).toBeDefined(); - }); - - it('should not include modelCommand when getUseModelRouter is false', async () => { - const mockConfigWithoutModelRouter = { - ...mockConfig, - getUseModelRouter: () => false, - } as unknown as Config; - const loader = new BuiltinCommandLoader(mockConfigWithoutModelRouter); - const commands = await loader.loadCommands(new AbortController().signal); - const modelCmd = commands.find((c) => c.name === 'model'); - expect(modelCmd).toBeUndefined(); - }); - it('should include policies command when message bus integration is enabled', async () => { const mockConfigWithMessageBus = { ...mockConfig, @@ -220,7 +197,6 @@ describe('BuiltinCommandLoader profile', () => { vi.resetModules(); mockConfig = { getFolderTrust: vi.fn().mockReturnValue(false), - getUseModelRouter: () => false, getCheckpointingEnabled: () => false, getEnableMessageBusIntegration: () => false, getEnableExtensionReloading: () => false, diff --git a/packages/cli/src/services/BuiltinCommandLoader.ts b/packages/cli/src/services/BuiltinCommandLoader.ts index 6e6c0a407f..3646b2d036 100644 --- a/packages/cli/src/services/BuiltinCommandLoader.ts +++ b/packages/cli/src/services/BuiltinCommandLoader.ts @@ -73,7 +73,7 @@ export class BuiltinCommandLoader implements ICommandLoader { initCommand, mcpCommand, memoryCommand, - ...(this.config?.getUseModelRouter() ? [modelCommand] : []), + modelCommand, ...(this.config?.getFolderTrust() ? [permissionsCommand] : []), privacyCommand, ...(this.config?.getEnableMessageBusIntegration() diff --git a/packages/cli/src/ui/components/ModelDialog.test.tsx b/packages/cli/src/ui/components/ModelDialog.test.tsx index 140ed9248e..a98a3caa82 100644 --- a/packages/cli/src/ui/components/ModelDialog.test.tsx +++ b/packages/cli/src/ui/components/ModelDialog.test.tsx @@ -51,7 +51,6 @@ const renderComponent = ( getDebugMode: vi.fn(() => false), getContentGeneratorConfig: vi.fn(() => ({ authType: 'mock' })), getUseSmartEdit: vi.fn(() => false), - getUseModelRouter: vi.fn(() => false), getProxy: vi.fn(() => undefined), isInteractive: vi.fn(() => false), diff --git a/packages/cli/src/ui/hooks/useGeminiStream.test.tsx b/packages/cli/src/ui/hooks/useGeminiStream.test.tsx index 6a8c864315..8411b4ba78 100644 --- a/packages/cli/src/ui/hooks/useGeminiStream.test.tsx +++ b/packages/cli/src/ui/hooks/useGeminiStream.test.tsx @@ -222,7 +222,6 @@ describe('useGeminiStream', () => { .fn() .mockReturnValue(contentGeneratorConfig), getUseSmartEdit: () => false, - getUseModelRouter: () => false, isInteractive: () => false, } as unknown as Config; mockOnDebugMessage = vi.fn(); diff --git a/packages/cli/src/ui/hooks/useToolScheduler.test.ts b/packages/cli/src/ui/hooks/useToolScheduler.test.ts index 175bf9c631..9c4bfd9b8b 100644 --- a/packages/cli/src/ui/hooks/useToolScheduler.test.ts +++ b/packages/cli/src/ui/hooks/useToolScheduler.test.ts @@ -74,7 +74,6 @@ const mockConfig = { authType: 'oauth-personal', }), getUseSmartEdit: () => false, - getUseModelRouter: () => false, getGeminiClient: () => null, // No client needed for these tests getShellExecutionConfig: () => ({ terminalWidth: 80, terminalHeight: 24 }), getEnableMessageBusIntegration: () => false, diff --git a/packages/core/src/config/config.test.ts b/packages/core/src/config/config.test.ts index 286103b85b..a3dda9371d 100644 --- a/packages/core/src/config/config.test.ts +++ b/packages/core/src/config/config.test.ts @@ -750,99 +750,6 @@ describe('Server Config (config.ts)', () => { }); }); - describe('Model Router with Auth', () => { - it('should disable model router by default for oauth-personal', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: true, - }); - await config.refreshAuth(AuthType.LOGIN_WITH_GOOGLE); - expect(config.getUseModelRouter()).toBe(true); - }); - - it('should enable model router by default for other auth types', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: true, - }); - await config.refreshAuth(AuthType.USE_GEMINI); - expect(config.getUseModelRouter()).toBe(true); - }); - - it('should disable model router for specified auth type', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: true, - disableModelRouterForAuth: [AuthType.USE_GEMINI], - }); - await config.refreshAuth(AuthType.USE_GEMINI); - expect(config.getUseModelRouter()).toBe(false); - }); - - it('should enable model router for other auth type', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: true, - disableModelRouterForAuth: [], - }); - await config.refreshAuth(AuthType.LOGIN_WITH_GOOGLE); - expect(config.getUseModelRouter()).toBe(true); - }); - - it('should keep model router disabled when useModelRouter is false', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: false, - disableModelRouterForAuth: [AuthType.USE_GEMINI], - }); - await config.refreshAuth(AuthType.LOGIN_WITH_GOOGLE); - expect(config.getUseModelRouter()).toBe(false); - }); - - it('should keep the user-chosen model after refreshAuth, even when model router is disabled for the auth type', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: true, - disableModelRouterForAuth: [AuthType.USE_GEMINI], - }); - const chosenModel = 'gemini-1.5-pro-latest'; - config.setModel(chosenModel); - - await config.refreshAuth(AuthType.USE_GEMINI); - - expect(config.getUseModelRouter()).toBe(false); - expect(config.getModel()).toBe(chosenModel); - }); - - it('should keep the user-chosen model after refreshAuth, when model router is enabled for the auth type', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: true, - disableModelRouterForAuth: [AuthType.USE_GEMINI], - }); - const chosenModel = 'gemini-1.5-pro-latest'; - config.setModel(chosenModel); - - await config.refreshAuth(AuthType.LOGIN_WITH_GOOGLE); - - expect(config.getUseModelRouter()).toBe(true); - expect(config.getModel()).toBe(chosenModel); - }); - - it('should NOT switch to auto model if cli provides specific model, even if router is enabled', async () => { - const config = new Config({ - ...baseParams, - useModelRouter: true, - model: 'gemini-flash-latest', - }); - - await config.refreshAuth(AuthType.LOGIN_WITH_GOOGLE); - - expect(config.getUseModelRouter()).toBe(true); - expect(config.getModel()).toBe('gemini-flash-latest'); - }); - }); - describe('ContinueOnFailedApiCall Configuration', () => { it('should default continueOnFailedApiCall to false when not provided', () => { const config = new Config(baseParams); diff --git a/packages/core/src/config/config.ts b/packages/core/src/config/config.ts index 6c2a962cfc..2e47e4294b 100644 --- a/packages/core/src/config/config.ts +++ b/packages/core/src/config/config.ts @@ -48,7 +48,6 @@ import { DEFAULT_GEMINI_EMBEDDING_MODEL, DEFAULT_GEMINI_FLASH_MODEL, DEFAULT_GEMINI_MODEL, - DEFAULT_GEMINI_MODEL_AUTO, DEFAULT_THINKING_MODE, } from './models.js'; import { shouldAttemptBrowserLaunch } from '../utils/browser.js'; @@ -288,7 +287,6 @@ export interface ConfigParameters { useWriteTodos?: boolean; policyEngineConfig?: PolicyEngineConfig; output?: OutputSettings; - useModelRouter?: boolean; enableMessageBusIntegration?: boolean; disableModelRouterForAuth?: AuthType[]; codebaseInvestigatorSettings?: CodebaseInvestigatorSettings; @@ -402,9 +400,6 @@ export class Config { private readonly messageBus: MessageBus; private readonly policyEngine: PolicyEngine; private readonly outputSettings: OutputSettings; - private useModelRouter: boolean; - private readonly initialUseModelRouter: boolean; - private readonly disableModelRouterForAuth?: AuthType[]; private readonly enableMessageBusIntegration: boolean; private readonly codebaseInvestigatorSettings: CodebaseInvestigatorSettings; private readonly continueOnFailedApiCall: boolean; @@ -519,9 +514,6 @@ export class Config { this.enableToolOutputTruncation = params.enableToolOutputTruncation ?? true; this.useSmartEdit = params.useSmartEdit ?? true; this.useWriteTodos = params.useWriteTodos ?? true; - this.initialUseModelRouter = params.useModelRouter ?? false; - this.useModelRouter = this.initialUseModelRouter; - this.disableModelRouterForAuth = params.disableModelRouterForAuth ?? []; this.enableHooks = params.enableHooks ?? false; // Enable MessageBus integration if: @@ -643,14 +635,6 @@ export class Config { } async refreshAuth(authMethod: AuthType) { - this.useModelRouter = this.initialUseModelRouter; - if (this.disableModelRouterForAuth?.includes(authMethod)) { - this.useModelRouter = false; - if (this.model === DEFAULT_GEMINI_MODEL_AUTO) { - this.model = DEFAULT_GEMINI_MODEL; - } - } - // Vertex and Genai have incompatible encryption and sending history with // thoughtSignature from Genai to Vertex will fail, we need to strip them if ( @@ -1341,10 +1325,6 @@ export class Config { : OutputFormat.TEXT; } - getUseModelRouter(): boolean { - return this.useModelRouter; - } - async getGitService(): Promise { if (!this.gitService) { this.gitService = new GitService(this.targetDir, this.storage); diff --git a/packages/core/src/core/client.test.ts b/packages/core/src/core/client.test.ts index e483ef1eb5..7284fe9e6f 100644 --- a/packages/core/src/core/client.test.ts +++ b/packages/core/src/core/client.test.ts @@ -216,7 +216,6 @@ describe('Gemini Client (client.ts)', () => { getChatCompression: vi.fn().mockReturnValue(undefined), getSkipNextSpeakerCheck: vi.fn().mockReturnValue(false), getUseSmartEdit: vi.fn().mockReturnValue(false), - getUseModelRouter: vi.fn().mockReturnValue(false), getShowModelInfoInChat: vi.fn().mockReturnValue(false), getContinueOnFailedApiCall: vi.fn(), getProjectRoot: vi.fn().mockReturnValue('/test/project/root'), diff --git a/packages/core/src/core/coreToolScheduler.test.ts b/packages/core/src/core/coreToolScheduler.test.ts index cbf8f5b66b..2821f182db 100644 --- a/packages/core/src/core/coreToolScheduler.test.ts +++ b/packages/core/src/core/coreToolScheduler.test.ts @@ -248,7 +248,6 @@ function createMockConfig(overrides: Partial = {}): Config { getTruncateToolOutputLines: () => DEFAULT_TRUNCATE_TOOL_OUTPUT_LINES, getToolRegistry: () => defaultToolRegistry, getUseSmartEdit: () => false, - getUseModelRouter: () => false, getGeminiClient: () => null, getEnableMessageBusIntegration: () => false, getMessageBus: () => null, diff --git a/packages/core/src/core/nonInteractiveToolExecutor.test.ts b/packages/core/src/core/nonInteractiveToolExecutor.test.ts index 5ee2b83f49..d74165ee5e 100644 --- a/packages/core/src/core/nonInteractiveToolExecutor.test.ts +++ b/packages/core/src/core/nonInteractiveToolExecutor.test.ts @@ -60,7 +60,6 @@ describe('executeToolCall', () => { DEFAULT_TRUNCATE_TOOL_OUTPUT_THRESHOLD, getTruncateToolOutputLines: () => DEFAULT_TRUNCATE_TOOL_OUTPUT_LINES, getUseSmartEdit: () => false, - getUseModelRouter: () => false, getGeminiClient: () => null, // No client needed for these tests getEnableMessageBusIntegration: () => false, getMessageBus: () => null, diff --git a/packages/core/src/telemetry/clearcut-logger/clearcut-logger.test.ts b/packages/core/src/telemetry/clearcut-logger/clearcut-logger.test.ts index fa14fcb017..ee6083c739 100644 --- a/packages/core/src/telemetry/clearcut-logger/clearcut-logger.test.ts +++ b/packages/core/src/telemetry/clearcut-logger/clearcut-logger.test.ts @@ -312,7 +312,7 @@ describe('ClearcutLogger', () => { it('logs all user settings', () => { const { logger } = setup({ - config: { useSmartEdit: true, useModelRouter: true }, + config: { useSmartEdit: true }, }); vi.stubEnv('TERM_PROGRAM', 'vscode'); diff --git a/packages/core/src/telemetry/loggers.test.ts b/packages/core/src/telemetry/loggers.test.ts index 4be2ec6eeb..282c266083 100644 --- a/packages/core/src/telemetry/loggers.test.ts +++ b/packages/core/src/telemetry/loggers.test.ts @@ -1544,7 +1544,6 @@ describe('loggers', () => { getUsageStatisticsEnabled: () => true, getContentGeneratorConfig: () => null, getUseSmartEdit: () => null, - getUseModelRouter: () => null, isInteractive: () => false, } as unknown as Config; @@ -1595,7 +1594,6 @@ describe('loggers', () => { getUsageStatisticsEnabled: () => true, getContentGeneratorConfig: () => null, getUseSmartEdit: () => null, - getUseModelRouter: () => null, isInteractive: () => false, } as unknown as Config; @@ -1648,7 +1646,6 @@ describe('loggers', () => { getUsageStatisticsEnabled: () => true, getContentGeneratorConfig: () => null, getUseSmartEdit: () => null, - getUseModelRouter: () => null, isInteractive: () => false, } as unknown as Config; diff --git a/packages/core/src/tools/smart-edit.test.ts b/packages/core/src/tools/smart-edit.test.ts index 1d3a8c822f..293d586c67 100644 --- a/packages/core/src/tools/smart-edit.test.ts +++ b/packages/core/src/tools/smart-edit.test.ts @@ -90,7 +90,6 @@ describe('SmartEditTool', () => { getSessionId: vi.fn(() => 'mock-session-id'), getContentGeneratorConfig: vi.fn(() => ({ authType: 'mock' })), getUseSmartEdit: vi.fn(() => false), - getUseModelRouter: vi.fn(() => false), getProxy: vi.fn(() => undefined), getGeminiClient: vi.fn().mockReturnValue(geminiClient), getBaseLlmClient: vi.fn().mockReturnValue(baseLlmClient), diff --git a/schemas/settings.schema.json b/schemas/settings.schema.json index 3bc6a5f7b1..ebfbe0dbf7 100644 --- a/schemas/settings.schema.json +++ b/schemas/settings.schema.json @@ -1201,13 +1201,6 @@ "default": false, "type": "boolean" }, - "useModelRouter": { - "title": "Use Model Router", - "description": "Enable model routing to route requests to the best model based on complexity.", - "markdownDescription": "Enable model routing to route requests to the best model based on complexity.\n\n- Category: `Experimental`\n- Requires restart: `yes`\n- Default: `true`", - "default": true, - "type": "boolean" - }, "codebaseInvestigatorSettings": { "title": "Codebase Investigator Settings", "description": "Configuration for Codebase Investigator.",