

























@@ -204,6 +204,54 @@ describe("resolveGoogleGeminiForwardCompatModel", () => {
204204});
205205});
206206207+it("resolves canonical gemini 3 flash from older Google flash templates when the exact row is missing", () => {
208+const model = resolveGoogleGeminiForwardCompatModel({
209+providerId: "google",
210+ctx: createContext({
211+provider: "google",
212+modelId: "gemini-3-flash-preview",
213+models: [
214+createTemplateModel("google", "gemini-2.5-flash", {
215+contextWindow: 1_048_576,
216+reasoning: true,
217+}),
218+],
219+}),
220+});
221+222+expect(model).toMatchObject({
223+provider: "google",
224+id: "gemini-3-flash-preview",
225+api: "google-generative-ai",
226+input: ["text", "image"],
227+contextWindow: 1_048_576,
228+reasoning: true,
229+});
230+});
231+232+it("resolves canonical Gemini CLI 3 flash from Google flash templates when the CLI row is missing", () => {
233+const model = resolveGoogleGeminiForwardCompatModel({
234+providerId: "google-gemini-cli",
235+ctx: createContext({
236+provider: "google-gemini-cli",
237+modelId: "gemini-3-flash-preview",
238+models: [
239+createTemplateModel("google", "gemini-2.5-flash", {
240+contextWindow: 1_048_576,
241+}),
242+],
243+}),
244+});
245+246+expect(model).toMatchObject({
247+provider: "google-gemini-cli",
248+id: "gemini-3-flash-preview",
249+api: "google-generative-ai",
250+input: ["text", "image"],
251+contextWindow: 1_048_576,
252+});
253+});
254+207255it("resolves Gemini latest aliases from current Google templates", () => {
208256const models = [
209257createTemplateModel("google", "gemini-3-pro-preview", { reasoning: true }),
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。