fix(cli): send GLM traffic to the platform its key belongs to

- the provider table named the China endpoint while the key mapping and client registry named Z.AI
This commit is contained in:
Yijia-Xiao
2026-09-17 07:31:44 +00:00
parent 2ddfe4ceb5
commit 008ac655a9
2 changed files with 19 additions and 1 deletions

View File

@@ -362,7 +362,9 @@ def _llm_provider_table() -> list[tuple[str, str, str | None]]:
("xAI", "xai", "https://api.x.ai/v1"),
("DeepSeek", "deepseek", "https://api.deepseek.com"),
("Qwen", "qwen", "https://dashscope-intl.aliyuncs.com/compatible-mode/v1"),
("GLM", "glm", "https://open.bigmodel.cn/api/paas/v4/"),
# Z.AI international, the platform ZHIPU_API_KEY belongs to; the CN
# platform is the separate glm-cn key, chosen in the region prompt.
("GLM", "glm", "https://api.z.ai/api/paas/v4/"),
("MiniMax", "minimax", "https://api.minimax.io/v1"),
("OpenRouter", "openrouter", "https://openrouter.ai/api/v1"),
("Mistral", "mistral", "https://api.mistral.ai/v1"),