Skip to content

Commit b2e4623

Browse files
authored
Add new gemini models (RooCodeInc#1656)
* Update gemini models * Update changeset
1 parent 0b7fac0 commit b2e4623

File tree

2 files changed

+32
-11
lines changed

2 files changed

+32
-11
lines changed

.changeset/funny-peas-call.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"claude-dev": patch
3+
---
4+
5+
Add new gemini models

src/shared/api.ts

Lines changed: 27 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -244,8 +244,24 @@ export const openAiModelInfoSaneDefaults: ModelInfo = {
244244
// Gemini
245245
// https://ai.google.dev/gemini-api/docs/models/gemini
246246
export type GeminiModelId = keyof typeof geminiModels
247-
export const geminiDefaultModelId: GeminiModelId = "gemini-2.0-flash-thinking-exp-1219"
247+
export const geminiDefaultModelId: GeminiModelId = "gemini-2.0-flash-001"
248248
export const geminiModels = {
249+
"gemini-2.0-flash-001": {
250+
maxTokens: 8192,
251+
contextWindow: 1_048_576,
252+
supportsImages: true,
253+
supportsPromptCache: false,
254+
inputPrice: 0,
255+
outputPrice: 0,
256+
},
257+
"gemini-2.0-flash-lite-preview-02-05": {
258+
maxTokens: 8192,
259+
contextWindow: 1_048_576,
260+
supportsImages: true,
261+
supportsPromptCache: false,
262+
inputPrice: 0,
263+
outputPrice: 0,
264+
},
249265
"gemini-2.0-pro-exp-02-05": {
250266
maxTokens: 8192,
251267
contextWindow: 2_097_152,
@@ -255,7 +271,7 @@ export const geminiModels = {
255271
outputPrice: 0,
256272
},
257273
"gemini-2.0-flash-thinking-exp-01-21": {
258-
maxTokens: 65536,
274+
maxTokens: 65_536,
259275
contextWindow: 1_048_576,
260276
supportsImages: true,
261277
supportsPromptCache: false,
@@ -278,14 +294,6 @@ export const geminiModels = {
278294
inputPrice: 0,
279295
outputPrice: 0,
280296
},
281-
"gemini-exp-1206": {
282-
maxTokens: 8192,
283-
contextWindow: 2_097_152,
284-
supportsImages: true,
285-
supportsPromptCache: false,
286-
inputPrice: 0,
287-
outputPrice: 0,
288-
},
289297
"gemini-1.5-flash-002": {
290298
maxTokens: 8192,
291299
contextWindow: 1_048_576,
@@ -326,6 +334,14 @@ export const geminiModels = {
326334
inputPrice: 0,
327335
outputPrice: 0,
328336
},
337+
"gemini-exp-1206": {
338+
maxTokens: 8192,
339+
contextWindow: 2_097_152,
340+
supportsImages: true,
341+
supportsPromptCache: false,
342+
inputPrice: 0,
343+
outputPrice: 0,
344+
},
329345
} as const satisfies Record<string, ModelInfo>
330346

331347
// OpenAI Native
@@ -506,4 +522,4 @@ export const liteLlmModelInfoSaneDefaults: ModelInfo = {
506522
supportsPromptCache: false,
507523
inputPrice: 0,
508524
outputPrice: 0,
509-
}
525+
}

0 commit comments

Comments
 (0)