Skip to content

Commit

Permalink
patch gemini-2.0-key
Browse files Browse the repository at this point in the history
  • Loading branch information
timothycarambat committed Dec 12, 2024
1 parent 66520b4 commit f8e91e1
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export default function GeminiLLMOptions({ settings }) {
"gemini-exp-1121",
"gemini-exp-1206",
"learnlm-1.5-pro-experimental",
"gemini-2.0-flash-exp-1206",
"gemini-2.0-flash-exp",
].map((model) => {
return (
<option key={model} value={model}>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/hooks/useGetProvidersModels.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const PROVIDER_DEFAULT_MODELS = {
"gemini-exp-1121",
"gemini-exp-1206",
"learnlm-1.5-pro-experimental",
"gemini-2.0-flash-exp-1206",
"gemini-2.0-flash-exp",
],
anthropic: [
"claude-instant-1.2",
Expand Down
4 changes: 2 additions & 2 deletions server/utils/AiProviders/gemini/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class GeminiLLM {
"gemini-exp-1121",
"gemini-exp-1206",
"learnlm-1.5-pro-experimental",
"gemini-2.0-flash-exp-1206",
"gemini-2.0-flash-exp",
].includes(this.model)
? "v1beta"
: "v1",
Expand Down Expand Up @@ -120,7 +120,7 @@ class GeminiLLM {
"gemini-exp-1121",
"gemini-exp-1206",
"learnlm-1.5-pro-experimental",
"gemini-2.0-flash-exp-1206",
"gemini-2.0-flash-exp",
];
return validModels.includes(modelName);
}
Expand Down
2 changes: 1 addition & 1 deletion server/utils/AiProviders/modelMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ const MODEL_MAP = {
"gemini-exp-1121": 32_767,
"gemini-exp-1206": 32_767,
"learnlm-1.5-pro-experimental": 32_767,
"gemini-2.0-flash-exp-1206": 1_048_576,
"gemini-2.0-flash-exp": 1_048_576,
},
groq: {
"gemma2-9b-it": 8192,
Expand Down
2 changes: 1 addition & 1 deletion server/utils/helpers/updateENV.js
Original file line number Diff line number Diff line change
Expand Up @@ -733,7 +733,7 @@ function validGeminiModel(input = "") {
"gemini-exp-1121",
"gemini-exp-1206",
"learnlm-1.5-pro-experimental",
"gemini-2.0-flash-exp-1206",
"gemini-2.0-flash-exp",
];
return validModels.includes(input)
? null
Expand Down

0 comments on commit f8e91e1

Please sign in to comment.