From 613610308cfa25abe8c67ea6eddc61638a9a765a Mon Sep 17 00:00:00 2001 From: YeonGyu-Kim Date: Sun, 1 Feb 2026 21:23:52 +0900 Subject: [PATCH] fix(cli): add -preview suffix for GitHub Copilot Gemini model names GitHub Copilot uses gemini-3-pro-preview and gemini-3-flash-preview as the official model identifiers. The CLI installer was generating config with incorrect names (gemini-3-pro, gemini-3-flash). Reported by user: the install command was creating config with wrong model names that don't work with GitHub Copilot API. --- .../__snapshots__/model-fallback.test.ts.snap | 32 +++++++++---------- src/cli/model-fallback.ts | 2 ++ 2 files changed, 18 insertions(+), 16 deletions(-) diff --git a/src/cli/__snapshots__/model-fallback.test.ts.snap b/src/cli/__snapshots__/model-fallback.test.ts.snap index aece5116..65465161 100644 --- a/src/cli/__snapshots__/model-fallback.test.ts.snap +++ b/src/cli/__snapshots__/model-fallback.test.ts.snap @@ -760,7 +760,7 @@ exports[`generateModelConfig fallback providers uses GitHub Copilot models when "variant": "medium", }, "multimodal-looker": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, "oracle": { "model": "github-copilot/gpt-5.2", @@ -777,7 +777,7 @@ exports[`generateModelConfig fallback providers uses GitHub Copilot models when }, "categories": { "artistry": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", "variant": "max", }, "deep": { @@ -798,10 +798,10 @@ exports[`generateModelConfig fallback providers uses GitHub Copilot models when "model": "github-copilot/claude-sonnet-4.5", }, "visual-engineering": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", }, "writing": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, }, } @@ -833,7 +833,7 @@ exports[`generateModelConfig fallback providers uses GitHub Copilot models with "variant": "medium", }, "multimodal-looker": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, "oracle": { "model": "github-copilot/gpt-5.2", @@ -850,7 +850,7 @@ exports[`generateModelConfig fallback providers uses GitHub Copilot models with }, "categories": { "artistry": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", "variant": "max", }, "deep": { @@ -872,10 +872,10 @@ exports[`generateModelConfig fallback providers uses GitHub Copilot models with "model": "github-copilot/claude-sonnet-4.5", }, "visual-engineering": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", }, "writing": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, }, } @@ -1090,7 +1090,7 @@ exports[`generateModelConfig mixed provider scenarios uses OpenAI + Copilot comb "variant": "medium", }, "multimodal-looker": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, "oracle": { "model": "openai/gpt-5.2", @@ -1107,7 +1107,7 @@ exports[`generateModelConfig mixed provider scenarios uses OpenAI + Copilot comb }, "categories": { "artistry": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", "variant": "max", }, "deep": { @@ -1128,10 +1128,10 @@ exports[`generateModelConfig mixed provider scenarios uses OpenAI + Copilot comb "model": "github-copilot/claude-sonnet-4.5", }, "visual-engineering": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", }, "writing": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, }, } @@ -1290,7 +1290,7 @@ exports[`generateModelConfig mixed provider scenarios uses all fallback provider "variant": "medium", }, "multimodal-looker": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, "oracle": { "model": "github-copilot/gpt-5.2", @@ -1307,7 +1307,7 @@ exports[`generateModelConfig mixed provider scenarios uses all fallback provider }, "categories": { "artistry": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", "variant": "max", }, "deep": { @@ -1328,10 +1328,10 @@ exports[`generateModelConfig mixed provider scenarios uses all fallback provider "model": "github-copilot/claude-sonnet-4.5", }, "visual-engineering": { - "model": "github-copilot/gemini-3-pro", + "model": "github-copilot/gemini-3-pro-preview", }, "writing": { - "model": "github-copilot/gemini-3-flash", + "model": "github-copilot/gemini-3-flash-preview", }, }, } diff --git a/src/cli/model-fallback.ts b/src/cli/model-fallback.ts index 08e16300..ed7faf34 100644 --- a/src/cli/model-fallback.ts +++ b/src/cli/model-fallback.ts @@ -75,6 +75,8 @@ function transformModelForProvider(provider: string, model: string): string { .replace("claude-sonnet-4-5", "claude-sonnet-4.5") .replace("claude-haiku-4-5", "claude-haiku-4.5") .replace("claude-sonnet-4", "claude-sonnet-4") + .replace("gemini-3-pro", "gemini-3-pro-preview") + .replace("gemini-3-flash", "gemini-3-flash-preview") } return model }