diff --git a/.vscode/launch.json b/.vscode/launch.json index 925c6e3..6159103 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -13,7 +13,7 @@ "FLASK_ENV": "development", "FLASK_DEBUG": "1" }, - "justMyCode": true, + "justMyCode": false, "console": "integratedTerminal" }, { diff --git a/app/llm_client.py b/app/llm_client.py index 258cecc..c6c8ddd 100644 --- a/app/llm_client.py +++ b/app/llm_client.py @@ -41,6 +41,19 @@ MODELS: Dict[str, Dict[str, Any]] = { "include_reasoning": True } }, + "gemini-2.5-flash-lite-routerai": { + "name": "google/gemini-2.5-flash-lite", + "provider": "openai", + "model_name": "google/gemini-2.5-flash-lite", + "apiBase": "https://routerai.ru/api/v1", # Добавлено /api/v1 + "apiKey": + "sk-QXEteDDGCbAgfyXgSlGFdU7WXc7jCbwB", + "stream": True, + "capabilities": ["vision", "reasoning"], + "model_kwargs": { + "include_reasoning": True + } + }, "gemini-2.5-flash-r": { "name": "gemini-2.5-flash-r", "provider": "openai", # Изменено на "openai" diff --git a/app/title_generator.py b/app/title_generator.py index ec8696f..cbdb4bc 100644 --- a/app/title_generator.py +++ b/app/title_generator.py @@ -11,8 +11,8 @@ from llm_client import DEFAULT_TEMPERATURE, get_llm from langchain_core.messages import SystemMessage, HumanMessage import uuid -DEFAULT_SUMMARIZATION_LLM_NAME = "gemini-2.5-flash-lite-openrouter" # "mistral-small-latest" # "mistral-small-latest" #"gemini-2.0-flash-r" -DEFAULT_VOICE_LLM_NAME = "deepseek-v4-flash-openrouter" # "gemini-3.0-flash-openrouter" +DEFAULT_SUMMARIZATION_LLM_NAME = "gemini-2.5-flash-lite-routerai" # "mistral-small-latest" # "mistral-small-latest" #"gemini-2.0-flash-r" +DEFAULT_VOICE_LLM_NAME = "deepseek-v4-flash-routerai" # "gemini-3.0-flash-openrouter" MAX_TITLE_GENERATION_CONTENT_LENGTH = 5000 # Максимальное количество символов для генерации заголовков QUEUE_POLLING_INTERVAL = 4