Skip to content

Commit cf0fe63

Browse files
fix google model name and add gemini 1.5 flash (#1778)
1 parent ef4f8f3 commit cf0fe63

File tree

3 files changed

+24
-6
lines changed

3 files changed

+24
-6
lines changed

Diff for: lib/chat-setting-limits.ts

+7
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,13 @@ export const CHAT_SETTING_LIMITS: Record<LLMID, ChatSettingLimits> = {
4141
},
4242

4343
// GOOGLE MODELS
44+
45+
"gemini-1.5-flash": {
46+
MIN_TEMPERATURE: 0.0,
47+
MAX_TEMPERATURE: 1.0,
48+
MAX_TOKEN_OUTPUT_LENGTH: 8192,
49+
MAX_CONTEXT_LENGTH: 1040384
50+
},
4451
"gemini-1.5-pro-latest": {
4552
MIN_TEMPERATURE: 0.0,
4653
MAX_TEMPERATURE: 1.0,

Diff for: lib/models/llm/google-llm-list.ts

+15-5
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,24 @@ const GOOGLE_PLATORM_LINK = "https://ai.google.dev/"
44

55
// Google Models (UPDATED 12/22/23) -----------------------------
66

7-
// Gemini Flash (UPDATED 05/28/24)
8-
const GEMINI_FLASH: LLM = {
7+
// Gemini 1.5 Flash
8+
const GEMINI_1_5_FLASH: LLM = {
9+
modelId: "gemini-1.5-flash",
10+
modelName: "Gemini 1.5 Flash",
11+
provider: "google",
12+
hostedId: "gemini-1.5-flash",
13+
platformLink: GOOGLE_PLATORM_LINK,
14+
imageInput: true
15+
}
16+
17+
// Gemini 1.5 Pro (UPDATED 05/28/24)
18+
const GEMINI_1_5_PRO: LLM = {
919
modelId: "gemini-1.5-pro-latest",
10-
modelName: "Gemini Flash",
20+
modelName: "Gemini 1.5 Pro",
1121
provider: "google",
1222
hostedId: "gemini-1.5-pro-latest",
1323
platformLink: GOOGLE_PLATORM_LINK,
14-
imageInput: false
24+
imageInput: true
1525
}
1626

1727
// Gemini Pro (UPDATED 12/22/23)
@@ -34,4 +44,4 @@ const GEMINI_PRO_VISION: LLM = {
3444
imageInput: true
3545
}
3646

37-
export const GOOGLE_LLM_LIST: LLM[] = [GEMINI_PRO, GEMINI_PRO_VISION, GEMINI_FLASH]
47+
export const GOOGLE_LLM_LIST: LLM[] = [GEMINI_PRO, GEMINI_PRO_VISION, GEMINI_1_5_PRO, GEMINI_1_5_FLASH]

Diff for: types/llms.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@ export type OpenAILLMID =
2020
export type GoogleLLMID =
2121
| "gemini-pro" // Gemini Pro
2222
| "gemini-pro-vision" // Gemini Pro Vision
23-
| "gemini-1.5-pro-latest"
23+
| "gemini-1.5-pro-latest" // Gemini 1.5 Pro
24+
| "gemini-1.5-flash" // Gemini 1.5 Flash
2425

2526
// Anthropic Models
2627
export type AnthropicLLMID =

0 commit comments

Comments
 (0)