mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-06 14:40:43 +00:00
docs(google): clarify gemini 3.1 pro alias
This commit is contained in:
@@ -23,6 +23,11 @@ describe("google model id helpers", () => {
|
||||
expect(normalizeGoogleModelId("gemini-3.1-flash-preview")).toBe("gemini-3-flash-preview");
|
||||
});
|
||||
|
||||
it("keeps bare Gemini 3.1 Pro as an alias for Google's preview-suffixed API id", () => {
|
||||
expect(normalizeGoogleModelId("gemini-3.1-pro")).toBe("gemini-3.1-pro-preview");
|
||||
expect(normalizeGoogleModelId("gemini-3.1-pro-preview")).toBe("gemini-3.1-pro-preview");
|
||||
});
|
||||
|
||||
it("adds the preview suffix for gemini 3.1 flash-lite", () => {
|
||||
expect(normalizeGoogleModelId("gemini-3.1-flash-lite")).toBe("gemini-3.1-flash-lite-preview");
|
||||
});
|
||||
|
||||
@@ -7,6 +7,8 @@ export function normalizeGoogleModelId(id: string): string {
|
||||
if (id === "gemini-3-flash") {
|
||||
return "gemini-3-flash-preview";
|
||||
}
|
||||
// Google exposes Gemini 3.1 Pro in the Gemini API as the preview-suffixed id.
|
||||
// Keep the bare form as a user convenience alias, not as a canonical API id.
|
||||
if (id === "gemini-3.1-pro") {
|
||||
return "gemini-3.1-pro-preview";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user