Change provider to polza.ai
This commit is contained in:
parent
ee2848ab68
commit
52d5196a48
|
|
@ -28,87 +28,48 @@ MODELS: Dict[str, Dict[str, Any]] = {
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision"],
|
"capabilities": ["vision"],
|
||||||
},
|
},
|
||||||
"gemini-2.5-flash-lite-openrouter": {
|
"gemini-2.5-flash-lite-polza": {
|
||||||
"name": "google/gemini-2.5-flash-lite",
|
"name": "google/gemini-2.5-flash-lite",
|
||||||
"provider": "openai",
|
"provider": "openai",
|
||||||
"model_name": "google/gemini-2.5-flash-lite",
|
"model_name": "google/gemini-2.5-flash-lite",
|
||||||
"apiBase": "https://openrouter.ai/api/v1", # Добавлено /api/v1
|
"apiBase": "https://polza.ai/api/v1", # Добавлено /api/v1
|
||||||
"apiKey":
|
"apiKey": "pza_qPk0xSBItQkUs18xoBUlyBBeYiHAxasy",
|
||||||
"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",
|
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision", "reasoning"],
|
"capabilities": ["vision", "reasoning"],
|
||||||
"model_kwargs": {
|
"model_kwargs": {
|
||||||
"include_reasoning": True
|
"include_reasoning": True
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"gemini-2.5-flash-lite-routerai": {
|
"gemini-2.5-flash-polza": {
|
||||||
"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"
|
|
||||||
"model_name": "gemini-2.5-flash", # Добавлено имя модели для LangChain
|
|
||||||
"apiBase":
|
|
||||||
"https://render-service-gsu7.onrender.com/g/v1beta", # "generativelanguage.googleapis.com", # "https://render-service-gsu7.onrender.com/g/v1beta",
|
|
||||||
"apiKey": "AIzaSyDpueKFWVqknVKlQn6TdasLmJ2lvAUiBik",
|
|
||||||
"stream": True,
|
|
||||||
"capabilities": ["vision"],
|
|
||||||
},
|
|
||||||
"gemini-2.5-flash-openrouter": {
|
|
||||||
"name": "google/gemini-2.5-flash",
|
"name": "google/gemini-2.5-flash",
|
||||||
"provider": "openai",
|
"provider": "openai",
|
||||||
"model_name": "google/gemini-2.5-flash",
|
"model_name": "google/gemini-2.5-flash",
|
||||||
"apiBase": "https://openrouter.ai/api/v1", # Добавлено /api/v1
|
"apiBase": "https://polza.ai/api/v1", # Добавлено /api/v1
|
||||||
"apiKey":
|
"apiKey": "pza_qPk0xSBItQkUs18xoBUlyBBeYiHAxasy",
|
||||||
"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",
|
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision", "reasoning"],
|
"capabilities": ["vision", "reasoning"],
|
||||||
"model_kwargs": {
|
"model_kwargs": {
|
||||||
"include_reasoning": True
|
"include_reasoning": True
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"gemini-3.0-flash-openrouter": {
|
"gemini-3.0-flash-polza": {
|
||||||
"name": "google/gemini-3-flash-preview",
|
"name": "google/gemini-3-flash-preview",
|
||||||
"provider": "openai",
|
"provider": "openai",
|
||||||
"model_name": "google/gemini-3-flash-preview",
|
"model_name": "google/gemini-3-flash-preview",
|
||||||
"apiBase": "https://openrouter.ai/api/v1", # Добавлено /api/v1
|
"apiBase": "https://polza.ai/api/v1",
|
||||||
"apiKey":
|
"apiKey": "pza_qPk0xSBItQkUs18xoBUlyBBeYiHAxasy",
|
||||||
"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",
|
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision", "reasoning"],
|
"capabilities": ["vision", "reasoning"],
|
||||||
"model_kwargs": {
|
"model_kwargs": {
|
||||||
"include_reasoning": True
|
"include_reasoning": True
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"gemini-3.0-flash-routerai": {
|
"gemini-3.1-pro-polza": {
|
||||||
"name": "google/gemini-3-flash-preview",
|
|
||||||
"provider": "openai",
|
|
||||||
"model_name": "google/gemini-3-flash-preview",
|
|
||||||
"apiBase": "https://routerai.ru/api/v1",
|
|
||||||
"apiKey": "sk-QXEteDDGCbAgfyXgSlGFdU7WXc7jCbwB",
|
|
||||||
"stream": True,
|
|
||||||
"capabilities": ["vision", "reasoning"],
|
|
||||||
"model_kwargs": {
|
|
||||||
"include_reasoning": True
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"gemini-3.1-pro-openrouter": {
|
|
||||||
"name": "google/gemini-3.1-pro-preview",
|
"name": "google/gemini-3.1-pro-preview",
|
||||||
"provider": "openai",
|
"provider": "openai",
|
||||||
"model_name": "google/gemini-3.1-pro-preview",
|
"model_name": "google/gemini-3.1-pro-preview",
|
||||||
"apiBase": "https://openrouter.ai/api/v1", # Добавлено /api/v1
|
"apiBase": "https://polza.ai/api/v1",
|
||||||
"apiKey":
|
"apiKey": "pza_qPk0xSBItQkUs18xoBUlyBBeYiHAxasy",
|
||||||
"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",
|
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision", "reasoning"],
|
"capabilities": ["vision", "reasoning"],
|
||||||
"model_kwargs": {
|
"model_kwargs": {
|
||||||
|
|
@ -136,16 +97,6 @@ MODELS: Dict[str, Dict[str, Any]] = {
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision"],
|
"capabilities": ["vision"],
|
||||||
},
|
},
|
||||||
"mistral-small-latest-r": {
|
|
||||||
"name": "mistral-small-latest",
|
|
||||||
"provider": "mistralai",
|
|
||||||
"model_name":
|
|
||||||
"mistral-small-latest", # Добавлено имя модели для LangChain
|
|
||||||
"apiBase": "https://render-service-gsu7.onrender.com/m",
|
|
||||||
"apiKey": "Q0m29fvxBY0Cfdj4sjHaKqccy1NjonLW",
|
|
||||||
"stream": True,
|
|
||||||
"capabilities": ["vision"],
|
|
||||||
},
|
|
||||||
"mistral-small-latest-error": {
|
"mistral-small-latest-error": {
|
||||||
"name": "mistral-small-latest",
|
"name": "mistral-small-latest",
|
||||||
"provider": "mistralai",
|
"provider": "mistralai",
|
||||||
|
|
@ -156,64 +107,56 @@ MODELS: Dict[str, Dict[str, Any]] = {
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision"],
|
"capabilities": ["vision"],
|
||||||
},
|
},
|
||||||
"claude-sonnet-4.6-openrouter": {
|
"claude-sonnet-5-polza": {
|
||||||
"name": "anthropic/claude-sonnet-4.6",
|
|
||||||
"provider": "openai",
|
|
||||||
"model_name": "anthropic/claude-sonnet-4.6",
|
|
||||||
"apiBase": "https://openrouter.ai/api/v1", # Добавлено /api/v1
|
|
||||||
"apiKey":
|
|
||||||
"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",
|
|
||||||
"stream": True,
|
|
||||||
"capabilities": ["vision", "reasoning"],
|
|
||||||
"model_kwargs": {
|
|
||||||
"include_reasoning": True
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"claude-sonnet-5-routerai": {
|
|
||||||
"name": "anthropic/claude-sonnet-5",
|
"name": "anthropic/claude-sonnet-5",
|
||||||
"provider": "openai",
|
"provider": "openai",
|
||||||
"model_name": "anthropic/claude-sonnet-5",
|
"model_name": "anthropic/claude-sonnet-5",
|
||||||
"apiBase": "https://routerai.ru/api/v1",
|
"apiBase": "https://polza.ai/api/v1",
|
||||||
"apiKey": "sk-QXEteDDGCbAgfyXgSlGFdU7WXc7jCbwB",
|
"apiKey": "pza_qPk0xSBItQkUs18xoBUlyBBeYiHAxasy",
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision", "reasoning"],
|
"capabilities": ["vision", "reasoning"],
|
||||||
"model_kwargs": {
|
"model_kwargs": {
|
||||||
"include_reasoning": True
|
"include_reasoning": True
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"deepseek-v4-flash-openrouter": {
|
"deepseek-v4-flash-polza": {
|
||||||
"name": "deepseek/deepseek-v4-flash",
|
|
||||||
"provider": "openai",
|
|
||||||
"model_name": "deepseek/deepseek-v4-flash",
|
|
||||||
"apiBase": "https://openrouter.ai/api/v1", # Добавлено /api/v1
|
|
||||||
"apiKey":
|
|
||||||
"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",
|
|
||||||
"stream": True,
|
|
||||||
"capabilities": ["vision", "reasoning"],
|
|
||||||
"model_kwargs": {
|
|
||||||
"include_reasoning": True
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"deepseek-v4-flash-routerai": {
|
|
||||||
"name": "deepseek/deepseek-chat",
|
"name": "deepseek/deepseek-chat",
|
||||||
"provider": "openai",
|
"provider": "openai",
|
||||||
"model_name": "deepseek/deepseek-chat",
|
"model_name": "deepseek/deepseek-chat",
|
||||||
"apiBase": "https://routerai.ru/api/v1",
|
"apiBase": "https://polza.ai/api/v1",
|
||||||
"apiKey": "sk-QXEteDDGCbAgfyXgSlGFdU7WXc7jCbwB",
|
"apiKey": "pza_qPk0xSBItQkUs18xoBUlyBBeYiHAxasy",
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["vision", "reasoning"],
|
"capabilities": ["vision", "reasoning"],
|
||||||
"model_kwargs": {
|
"model_kwargs": {
|
||||||
"include_reasoning": True
|
"include_reasoning": True
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"deepseek-v3.2-exp-openrouter": {
|
"deepseek-v3.2-exp-polza": {
|
||||||
"name": "deepseek/deepseek-v3.2-exp",
|
"name": "deepseek/deepseek-v3.2-exp",
|
||||||
"provider": "openrouter",
|
"provider": "openrouter",
|
||||||
"model_name": "deepseek/deepseek-v3.2-exp",
|
"model_name": "deepseek/deepseek-v3.2-exp",
|
||||||
"apiBase": "https://openrouter.ai/api/v1",
|
"apiBase": "https://polza.ai/api/v1",
|
||||||
"apiKey": "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",
|
"apiKey": "pza_qPk0xSBItQkUs18xoBUlyBBeYiHAxasy",
|
||||||
"stream": True,
|
"stream": True,
|
||||||
"capabilities": ["chat", "reasoning", "code"]
|
"capabilities": ["chat", "reasoning", "code"]
|
||||||
|
},
|
||||||
|
"gigachat-2": {
|
||||||
|
"name": "GigaChat-2",
|
||||||
|
"provider": "custom",
|
||||||
|
"model_name": "GigaChat-2",
|
||||||
|
"apiBase": "http://localhost:8090/v1",
|
||||||
|
"apiKey": "my_super_secret_key_123",
|
||||||
|
"stream": True,
|
||||||
|
"capabilities": ["chat"]
|
||||||
|
},
|
||||||
|
"gigachat-2-max": {
|
||||||
|
"name": "GigaChat-2-Max",
|
||||||
|
"provider": "custom",
|
||||||
|
"model_name": "GigaChat-2-Max",
|
||||||
|
"apiBase": "http://localhost:8090/v1",
|
||||||
|
"apiKey": "my_super_secret_key_123",
|
||||||
|
"stream": True,
|
||||||
|
"capabilities": ["chat"]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,8 +11,8 @@ from llm_client import DEFAULT_TEMPERATURE, get_llm
|
||||||
from langchain_core.messages import SystemMessage, HumanMessage
|
from langchain_core.messages import SystemMessage, HumanMessage
|
||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
DEFAULT_SUMMARIZATION_LLM_NAME = "gemini-2.5-flash-lite-routerai" # "mistral-small-latest" # "mistral-small-latest" #"gemini-2.0-flash-r"
|
DEFAULT_SUMMARIZATION_LLM_NAME = "gemini-2.5-flash-lite-polza" # "mistral-small-latest" # "mistral-small-latest" #"gemini-2.0-flash-r"
|
||||||
DEFAULT_VOICE_LLM_NAME = "deepseek-v4-flash-routerai" # "gemini-3.0-flash-openrouter"
|
DEFAULT_VOICE_LLM_NAME = "deepseek-v4-flash-polza" # "gemini-3.0-flash-openrouter"
|
||||||
|
|
||||||
MAX_TITLE_GENERATION_CONTENT_LENGTH = 5000 # Максимальное количество символов для генерации заголовков
|
MAX_TITLE_GENERATION_CONTENT_LENGTH = 5000 # Максимальное количество символов для генерации заголовков
|
||||||
QUEUE_POLLING_INTERVAL = 4
|
QUEUE_POLLING_INTERVAL = 4
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,7 @@ numpy==2.1.0
|
||||||
matplotlib==3.8.4
|
matplotlib==3.8.4
|
||||||
pandas==2.2.2
|
pandas==2.2.2
|
||||||
|
|
||||||
|
symspellpy==6.7.7
|
||||||
|
|
||||||
# обфускация, сборка
|
# обфускация, сборка
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user