Skip to content

feat(js/plugins): added new gemini 2.0 flash thinking exp models #2201

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions js/plugins/googleai/src/gemini.ts
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,23 @@ export const gemini20ProExp0205 = modelRef({
configSchema: GeminiConfigSchema,
});

export const gemini20FlashThinkingExp0121 = modelRef({
name: 'googleai/gemini-2.0-flash-thinking-exp-01-21',
info: {
label: 'Google AI - Gemini 2.0 Flash Thinking Experimental 01-21',
versions: [],
supports: {
multiturn: true,
media: true,
tools: true,
toolChoice: true,
systemRole: true,
constrained: 'no-tools',
},
},
configSchema: GeminiConfigSchema,
});

export const SUPPORTED_V1_MODELS = {
'gemini-1.0-pro': gemini10Pro,
};
Expand All @@ -219,6 +236,7 @@ export const SUPPORTED_V15_MODELS = {
'gemini-1.5-flash-8b': gemini15Flash8b,
'gemini-2.0-flash': gemini20Flash,
'gemini-2.0-pro-exp-02-05': gemini20ProExp0205,
'gemini-2.0-flash-thinking-exp-01-21': gemini20FlashThinkingExp0121,
};

export const GENERIC_GEMINI_MODEL = modelRef({
Expand Down
2 changes: 2 additions & 0 deletions js/plugins/googleai/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
gemini15Flash8b,
gemini15Pro,
gemini20Flash,
gemini20FlashThinkingExp0121,
gemini20ProExp0205,
type GeminiConfig,
type GeminiVersionString,
Expand All @@ -44,6 +45,7 @@ export {
gemini15Flash8b,
gemini15Pro,
gemini20Flash,
gemini20FlashThinkingExp0121,
gemini20ProExp0205,
textEmbedding004,
textEmbeddingGecko001,
Expand Down
18 changes: 18 additions & 0 deletions js/plugins/vertexai/src/gemini.ts
Original file line number Diff line number Diff line change
Expand Up @@ -374,6 +374,23 @@ export const gemini20ProExp0205 = modelRef({
configSchema: GeminiConfigSchema,
});

export const gemini20FlashThinkingExp0121 = modelRef({
name: 'vertexai/gemini-2.0-flash-thinking-exp-01-21',
info: {
label: 'Vertex AI - Gemini 2.0 Flash Thinking Experimental 01-21',
versions: [],
supports: {
multiturn: true,
media: true,
tools: true,
toolChoice: true,
systemRole: true,
constrained: 'no-tools',
},
},
configSchema: GeminiConfigSchema,
});

export const GENERIC_GEMINI_MODEL = modelRef({
name: 'vertexai/gemini',
configSchema: GeminiConfigSchema,
Expand All @@ -399,6 +416,7 @@ export const SUPPORTED_V15_MODELS = {
'gemini-2.0-flash-001': gemini20Flash001,
'gemini-2.0-flash-lite-preview-02-05': gemini20FlashLitePreview0205,
'gemini-2.0-pro-exp-02-05': gemini20ProExp0205,
'gemini-2.0-flash-thinking-exp-01-21': gemini20FlashThinkingExp0121,
};

export const SUPPORTED_GEMINI_MODELS = {
Expand Down
2 changes: 2 additions & 0 deletions js/plugins/vertexai/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ import {
gemini15Pro,
gemini20Flash001,
gemini20FlashLitePreview0205,
gemini20FlashThinkingExp0121,
gemini20ProExp0205,
type GeminiConfig,
} from './gemini.js';
Expand All @@ -62,6 +63,7 @@ export {
gemini15Pro,
gemini20Flash001,
gemini20FlashLitePreview0205,
gemini20FlashThinkingExp0121,
gemini20ProExp0205,
imagen2,
imagen3,
Expand Down
Loading