Improved Ollama configuration: Added API_KEY and MODEL_NAME configuration options

This commit is contained in:
C H 2025-05-29 22:27:17 +02:00
parent 70919ea228
commit 578de9eb83
3 changed files with 28 additions and 1 deletions

View file

@ -31,6 +31,8 @@ interface Config {
};
OLLAMA: {
API_URL: string;
API_KEY: string;
MODEL_NAME: string;
};
DEEPSEEK: {
API_KEY: string;
@ -82,6 +84,8 @@ export const getSearxngApiEndpoint = () =>
process.env.SEARXNG_API_URL || loadConfig().API_ENDPOINTS.SEARXNG;
export const getOllamaApiEndpoint = () => loadConfig().MODELS.OLLAMA.API_URL;
export const getOllamaApiKey = () => loadConfig().MODELS.OLLAMA.API_KEY;
export const getOllamaModelName = () => loadConfig().MODELS.OLLAMA.MODEL_NAME;
export const getDeepseekApiKey = () => loadConfig().MODELS.DEEPSEEK.API_KEY;