Fix Ollama endpoint: use http://ollama:11434
This commit is contained in:
@@ -23,7 +23,7 @@ def get_llm_response(prompt: str, provider: str, cfg: dict) -> str:
|
||||
return f"Erro de Conexão Gemini: {str(e)}"
|
||||
|
||||
elif provider == "ollama":
|
||||
ollama_host = os.getenv("OLLAMA_HOST", "http://ollama-lw4s8g4gc8gss4gkc4gg0wk4:11434")
|
||||
ollama_host = os.getenv("OLLAMA_HOST", "http://ollama:11434")
|
||||
try:
|
||||
res = requests.post(f"{ollama_host}/api/generate", json={
|
||||
"model": os.getenv("OLLAMA_MODEL", "qwen2.5-coder:1.5b"),
|
||||
|
||||
@@ -37,7 +37,7 @@ LLM_PROVIDERS = {
|
||||
"ollama": {
|
||||
"name": "Ollama (Local)",
|
||||
"type": "local",
|
||||
"endpoint": os.getenv("OLLAMA_HOST", "http://ollama-lw4s8g4gc8gss4gkc4gg0wk4:11434"),
|
||||
"endpoint": os.getenv("OLLAMA_HOST", "http://ollama:11434"),
|
||||
"models": None,
|
||||
"default": "qwen2.5-coder:1.5b"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user