Your lightweight open-source personal agent.
Python agent-frameworkai-agentai-agentschatbotchatopsdiscord-botllm-agentsllmslocal-llmmcpmodel-context-protocolmulti-agentopenai-compatibleopenclawpersonal-ai-assistantpythonself-hostedtelegram-bot-ai-assistantwebuiworkflow-automation
fix: Use correct 'zai/' prefix for Zhipu AI models in LiteLLM
Pedro Perez43fe83755dab
diff --git a/nanobot/providers/litellm_provider.py b/nanobot/providers/litellm_provider.pyindex 42b4bf5b2..a0927c42a 100644--- a/nanobot/providers/litellm_provider.py+++ b/nanobot/providers/litellm_provider.py@@ -86,13 +86,13 @@ class LiteLLMProvider(LLMProvider):model = f"openrouter/{model}"# For Zhipu/Z.ai, ensure prefix is present- # Handle cases like "glm-4.7-flash" -> "zhipu/glm-4.7-flash"+ # Handle cases like "glm-4.7-flash" -> "zai/glm-4.7-flash"if ("glm" in model.lower() or "zhipu" in model.lower()) and not (model.startswith("zhipu/") ormodel.startswith("zai/") ormodel.startswith("openrouter/")):- model = f"zhipu/{model}"+ model = f"zai/{model}"# For vLLM, use hosted_vllm/ prefix per LiteLLM docs# Convert openai/ prefix to hosted_vllm/ if user specified it