chore: upgrade gemini models

This commit is contained in:
Haileyesus
2026-06-11 18:38:02 +03:00
parent afc717e69e
commit 3d948217ef
3 changed files with 11 additions and 9 deletions

View File

@@ -12,17 +12,14 @@ import {
export const GEMINI_FALLBACK_MODELS: ProviderModelsDefinition = { export const GEMINI_FALLBACK_MODELS: ProviderModelsDefinition = {
OPTIONS: [ OPTIONS: [
{ value: 'gemini-3.1-pro-preview', label: 'Gemini 3.1 Pro Preview' },
{ value: 'gemini-3-pro-preview', label: 'Gemini 3 Pro Preview' },
{ value: 'gemini-3-flash-preview', label: 'Gemini 3 Flash Preview' }, { value: 'gemini-3-flash-preview', label: 'Gemini 3 Flash Preview' },
{ value: 'gemini-3.1-flash-lite-preview', label: 'Gemini 3.1 Flash Lite Preview' },
{ value: 'gemini-2.5-flash', label: 'Gemini 2.5 Flash' }, { value: 'gemini-2.5-flash', label: 'Gemini 2.5 Flash' },
{ value: 'gemini-2.5-pro', label: 'Gemini 2.5 Pro' }, { value: 'gemini-2.5-flash-lite', label: 'Gemini 2.5 Flash Lite' },
{ value: 'gemini-2.0-flash-lite', label: 'Gemini 2.0 Flash Lite' }, { value: 'gemma-4-31b-it', label: 'Gemma 4 31B IT' },
{ value: 'gemini-2.0-flash', label: 'Gemini 2.0 Flash' }, { value: 'gemma-4-26b-a4b-it', label: 'Gemma 4 26B A4B IT' },
{ value: 'gemini-2.0-pro-exp', label: 'Gemini 2.0 Pro Experimental' },
{ value: 'gemini-2.0-flash-thinking-exp', label: 'Gemini 2.0 Flash Thinking' },
], ],
DEFAULT: 'gemini-3.1-pro-preview', DEFAULT: 'gemini-3-flash-preview',
}; };
export class GeminiProviderModels implements IProviderModels { export class GeminiProviderModels implements IProviderModels {

View File

@@ -17,7 +17,7 @@ import { readProviderSessionActiveModelChange } from '@/shared/utils.js';
export const PROVIDER_MODELS_CACHE_TTL_MS = 3 * 24 * 60 * 60 * 1000; export const PROVIDER_MODELS_CACHE_TTL_MS = 3 * 24 * 60 * 60 * 1000;
const PROVIDER_MODELS_CACHE_VERSION = 1; const PROVIDER_MODELS_CACHE_VERSION = 1;
const UNCACHED_PROVIDERS = new Set<LLMProvider>(['claude']); const UNCACHED_PROVIDERS = new Set<LLMProvider>(['claude', 'gemini']);
type ProviderModelsServiceDependencies = { type ProviderModelsServiceDependencies = {
resolveProvider?: (provider: LLMProvider) => Pick<IProvider, 'models'>; resolveProvider?: (provider: LLMProvider) => Pick<IProvider, 'models'>;

View File

@@ -279,6 +279,7 @@ export function useChatRealtimeHandlers({
if (isVisibleSession) { if (isVisibleSession) {
setCurrentSessionId(actualSessionId); setCurrentSessionId(actualSessionId);
void sessionStore.refreshFromServer(actualSessionId);
} }
if (isVisibleSession) { if (isVisibleSession) {
@@ -288,6 +289,10 @@ export function useChatRealtimeHandlers({
break; break;
} }
if (sid && isVisibleSession) {
void sessionStore.refreshFromServer(sid);
}
break; break;
} }