From 27d3ce0be05e2264becc8bf35579dda095d1b51a Mon Sep 17 00:00:00 2001 From: "penuel.li" Date: Tue, 1 Apr 2025 20:49:19 +0800 Subject: [PATCH] feat: 1. Modify the latest API path for Gemini. 2. Add the gemini-2.5-pro model. 3. Remove the no longer supported gemini-1.0-pro --- app/constant.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/constant.ts b/app/constant.ts index c1b135485..80f550a57 100644 --- a/app/constant.ts +++ b/app/constant.ts @@ -190,8 +190,7 @@ export const Azure = { export const Google = { ExampleEndpoint: "https://generativelanguage.googleapis.com/", - ChatPath: (modelName: string) => - `v1beta/models/${modelName}:streamGenerateContent`, + ChatPath: (modelName: string) => `v1beta/models/${modelName}:generateContent`, }; export const Baidu = { @@ -502,7 +501,6 @@ const openaiModels = [ ]; const googleModels = [ - "gemini-1.0-pro", // Deprecated on 2/15/2025 "gemini-1.5-pro-latest", "gemini-1.5-pro", "gemini-1.5-pro-002", @@ -518,6 +516,7 @@ const googleModels = [ "gemini-exp-1121", "gemini-exp-1206", "gemini-2.0-flash", + "gemini-2.0-flash-lite", "gemini-2.0-flash-exp", "gemini-2.0-flash-lite-preview-02-05", "gemini-2.0-flash-thinking-exp", @@ -525,6 +524,7 @@ const googleModels = [ "gemini-2.0-flash-thinking-exp-01-21", "gemini-2.0-pro-exp", "gemini-2.0-pro-exp-02-05", + "gemini-2.5-pro-exp-03-25", ]; const anthropicModels = [