diff --git a/packages/cli/src/commands/setup-commands.ts b/packages/cli/src/commands/setup-commands.ts index 1619a80a..0aeac724 100644 --- a/packages/cli/src/commands/setup-commands.ts +++ b/packages/cli/src/commands/setup-commands.ts @@ -95,7 +95,6 @@ function shouldShowSetupEntryMenu( llmBackend?: KtxSetupLlmBackend; anthropicApiKeyEnv?: string; anthropicApiKeyFile?: string; - llmModel?: string; vertexProject?: string; vertexLocation?: string; skipLlm?: boolean; @@ -166,7 +165,6 @@ function shouldShowSetupEntryMenu( 'llmBackend', 'anthropicApiKeyEnv', 'anthropicApiKeyFile', - 'llmModel', 'vertexProject', 'vertexLocation', 'skipLlm', @@ -229,7 +227,6 @@ export function registerSetupCommands(program: Command, context: KtxCliCommandCo .addOption( new Option('--anthropic-api-key-file ', 'File containing the Anthropic API key').hideHelp(), ) - .addOption(new Option('--llm-model ', 'LLM model ID or backend model alias').hideHelp()) .addOption(new Option('--vertex-project ', 'Google Vertex AI project ID, env:NAME, or file:/path').hideHelp()) .addOption(new Option('--vertex-location ', 'Google Vertex AI location, env:NAME, or file:/path').hideHelp()) .addOption(new Option('--skip-llm', 'Leave LLM setup incomplete for now').hideHelp().default(false)) @@ -420,7 +417,6 @@ export function registerSetupCommands(program: Command, context: KtxCliCommandCo ...(options.llmBackend ? { llmBackend: options.llmBackend } : {}), ...(options.anthropicApiKeyEnv ? { anthropicApiKeyEnv: options.anthropicApiKeyEnv } : {}), ...(options.anthropicApiKeyFile ? { anthropicApiKeyFile: options.anthropicApiKeyFile } : {}), - ...(options.llmModel ? { llmModel: options.llmModel } : {}), ...(options.vertexProject ? { vertexProject: options.vertexProject } : {}), ...(options.vertexLocation ? { vertexLocation: options.vertexLocation } : {}), skipLlm: options.skipLlm === true, diff --git a/packages/cli/src/setup.ts b/packages/cli/src/setup.ts index a991367e..46ea16ae 100644 --- a/packages/cli/src/setup.ts +++ b/packages/cli/src/setup.ts @@ -85,7 +85,6 @@ export type KtxSetupArgs = llmBackend?: KtxSetupLlmBackend; anthropicApiKeyEnv?: string; anthropicApiKeyFile?: string; - llmModel?: string; vertexProject?: string; vertexLocation?: string; skipLlm: boolean; @@ -699,7 +698,6 @@ async function runKtxSetupInner(args: KtxSetupArgs, io: KtxCliIo, deps: KtxSetup ...(args.llmBackend ? { llmBackend: args.llmBackend } : {}), ...(args.anthropicApiKeyEnv ? { anthropicApiKeyEnv: args.anthropicApiKeyEnv } : {}), ...(args.anthropicApiKeyFile ? { anthropicApiKeyFile: args.anthropicApiKeyFile } : {}), - ...(args.llmModel ? { llmModel: args.llmModel } : {}), ...(args.vertexProject ? { vertexProject: args.vertexProject } : {}), ...(args.vertexLocation ? { vertexLocation: args.vertexLocation } : {}), forcePrompt: forcePromptSteps.has('models') || runOnly === 'models', diff --git a/packages/cli/test/index.test.ts b/packages/cli/test/index.test.ts index 57ac4901..eef511fb 100644 --- a/packages/cli/test/index.test.ts +++ b/packages/cli/test/index.test.ts @@ -1136,8 +1136,6 @@ describe('runKtxCli', () => { '--no-input', '--anthropic-api-key-env', 'ANTHROPIC_API_KEY', - '--llm-model', - 'claude-sonnet-4-6', ], setupIo.io, { setup }, @@ -1151,7 +1149,6 @@ describe('runKtxCli', () => { inputMode: 'disabled', cliVersion, anthropicApiKeyEnv: 'ANTHROPIC_API_KEY', // pragma: allowlist secret - llmModel: 'claude-sonnet-4-6', skipLlm: false, }), setupIo.io, @@ -1175,8 +1172,6 @@ describe('runKtxCli', () => { 'local-gcp-project', '--vertex-location', 'us-east5', - '--llm-model', - 'claude-sonnet-4-6', ], setupIo.io, { setup }, @@ -1192,14 +1187,13 @@ describe('runKtxCli', () => { llmBackend: 'vertex', vertexProject: 'local-gcp-project', vertexLocation: 'us-east5', - llmModel: 'claude-sonnet-4-6', skipLlm: false, }), setupIo.io, ); }); - it('dispatches the provider-neutral LLM model setup flag to the setup runner', async () => { + it('rejects the removed --llm-model setup flag', async () => { const setup = vi.fn(async () => 0); const setupIo = makeIo(); @@ -1218,20 +1212,10 @@ describe('runKtxCli', () => { setupIo.io, { setup }, ), - ).resolves.toBe(0); + ).resolves.toBe(1); - expect(setup).toHaveBeenCalledWith( - expect.objectContaining({ - command: 'run', - projectDir: tempDir, - inputMode: 'disabled', - cliVersion, - llmBackend: 'claude-code', - llmModel: 'opus', - skipLlm: false, - }), - setupIo.io, - ); + expect(setup).not.toHaveBeenCalled(); + expect(setupIo.stderr()).toContain("unknown option '--llm-model'"); }); it('rejects conflicting Anthropic credential setup flags', async () => { diff --git a/packages/cli/test/setup.test.ts b/packages/cli/test/setup.test.ts index 9b8bf689..ecb20520 100644 --- a/packages/cli/test/setup.test.ts +++ b/packages/cli/test/setup.test.ts @@ -1305,7 +1305,6 @@ describe('setup status', () => { yes: true, cliVersion: '0.2.0', anthropicApiKeyEnv: 'ANTHROPIC_API_KEY', // pragma: allowlist secret - llmModel: 'claude-sonnet-4-6', skipLlm: false, skipEmbeddings: true, databaseSchemas: [], @@ -1322,7 +1321,6 @@ describe('setup status', () => { projectDir: tempDir, inputMode: 'disabled', anthropicApiKeyEnv: 'ANTHROPIC_API_KEY', // pragma: allowlist secret - llmModel: 'claude-sonnet-4-6', skipLlm: false, }), testIo.io, @@ -1347,7 +1345,6 @@ describe('setup status', () => { llmBackend: 'vertex', vertexProject: 'local-gcp-project', vertexLocation: 'us-east5', - llmModel: 'claude-sonnet-4-6', skipLlm: false, skipEmbeddings: true, databaseSchemas: [], @@ -1366,7 +1363,6 @@ describe('setup status', () => { llmBackend: 'vertex', vertexProject: 'local-gcp-project', vertexLocation: 'us-east5', - llmModel: 'claude-sonnet-4-6', skipLlm: false, }), testIo.io, @@ -1390,7 +1386,6 @@ describe('setup status', () => { yes: true, cliVersion: '0.2.0', anthropicApiKeyEnv: 'ANTHROPIC_API_KEY', // pragma: allowlist secret - llmModel: 'claude-sonnet-4-6', skipLlm: false, embeddingBackend: 'openai', embeddingApiKeyEnv: 'OPENAI_API_KEY', // pragma: allowlist secret @@ -1658,7 +1653,6 @@ describe('setup status', () => { yes: true, cliVersion: '0.2.0', anthropicApiKeyEnv: 'ANTHROPIC_API_KEY', // pragma: allowlist secret - llmModel: 'claude-sonnet-4-6', skipLlm: false, embeddingBackend: 'openai', embeddingApiKeyEnv: 'OPENAI_API_KEY', // pragma: allowlist secret @@ -2657,7 +2651,6 @@ describe('setup status', () => { yes: true, cliVersion: '0.2.0', anthropicApiKeyEnv: 'ANTHROPIC_API_KEY', // pragma: allowlist secret - llmModel: 'claude-sonnet-4-6', skipLlm: false, skipEmbeddings: false, databaseSchemas: [],