Replies: 1 comment
-
|
This kind of error is usually a mismatch between the model name/config in Litellm and what’s actually available or exposed at your backend, especially when you’re aggregating via Litellm. A few things worth checking based on how we’ve deployed local Ollama models behind aggregators:
Let me know if you see the model in |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
openclaw.json中关于ollama本地模型直接调用("baseUrl": "http://127.0.0.1:11434",)LiteLLM聚合的配置如下("baseUrl": "http://127.0.0.1:4000/v1",),
直接指定ollama的qwen3.5:9b,在web界面及tg bot是可以对话的,但是模型切换到litellm 就报错(⚠️ Something went wrong while processing your request. Please try again, or use /new to start a fresh session.),但终端执行命令curl http://127.0.0.1:4000/v1/chat/completions -H "Content-Type: application/json" -H "Authorization: Bearer sk-litellm-zsy-2026" -d '{"model": "LiteLLM","messages": [{"role": "user","content": "介绍一下你自己"}]}' 就没问题,是哪里配置不对吗?:
"ollama": {
"baseUrl": "http://127.0.0.1:11434",
"apiKey": "sk-litellm-zsy-2026",
"api": "ollama",
"models": [
{
"id": "ollama/qwen3.5:9b",
"name": "qwen3.5:9b",
"reasoning": false,
"input": [
"text",
"image"
],
"cost": {
"input": 0,
"output": 0,
"cacheRead": 0,
"cacheWrite": 0
},
"contextWindow": 262144,
"maxTokens": 8192
}
]
},
"litellm": {
"baseUrl": "http://127.0.0.1:4000/v1",
"apiKey": "sk-litellm-zsy-2026",
"api": "openai-completions",
"models": [
{
"id": "LiteLLM",
"name": "LiteLLM 聚合节点",
"api": "openai-completions",
"reasoning": false,
"input": [
"text",
"image"
],
"cost": {
"input": 0,
"output": 0,
"cacheRead": 0,
"cacheWrite": 0
},
"contextWindow": 128000,
"maxTokens": 8192
}
]
}
LiteLLM的配置文件config.yaml写的是api_base: http://127.0.0.1:11434:
model_list:
litellm_params:
#model: ollama/qwen3.5:9b
#model: ollama/deepseek-v3.1:671b-cloud
#model: ollama/deepseek-r1:14b
model: ollama/qwen3.5:9b
api_base: http://127.0.0.1:11434
model_info:
id: ollama-local
router_settings:
routing_strategy: least-busy
num_retries: 1
retry_after: 5
cooldown_time: 60
litellm_settings:
request_timeout: 900
drop_params: true
general_settings:
master_key: "sk-litellm-zsy-2026"
database_url: "postgresql://postgres:Lit22sdf23@localhost:5432/litellm_db"
api
Beta Was this translation helpful? Give feedback.
All reactions