在 Crush、Goose、Zed 與 Aider 中使用 Unquant
再介紹四款 agent,各附一段設定範例,全部連接至同一個相容於 OpenAI 的端點。
Crush
在 ~/.config/crush/crush.json 或專案的 .crush.json 中加入以下設定;類型必須設為 openai-compat:
{
"providers": {
"unquant": {
"type": "openai-compat",
"base_url": "https://api.unquant.io/v1",
"api_key": "$UNQUANT_API_KEY",
"models": [{ "id": "glm-5.3-flash", "context_window": 262144 }]
}
}
}Goose
export GOOSE_PROVIDER=openai
export OPENAI_HOST=https://api.unquant.io
export OPENAI_BASE_PATH=v1/chat/completions
export OPENAI_API_KEY=your-unquant-key
export GOOSE_MODEL=glm-5.3-flashZed
在 Zed 的 settings.json 中新增相容於 OpenAI 的供應商,然後在 agent 面板的設定中輸入金鑰:
{
"language_models": {
"openai_compatible": {
"Unquant": {
"api_url": "https://api.unquant.io/v1",
"available_models": [{ "name": "glm-5.3-flash", "max_tokens": 262144 }]
}
}
}
}Aider
export OPENAI_API_BASE=https://api.unquant.io/v1
export OPENAI_API_KEY=your-unquant-key
aider --model openai/glm-5.3-flashopenai/ 前綴會告訴 Aider 使用你設定的 OpenAI 相容 Base URL。
延伸閱讀
- 在 VS Code 中使用 Unquant:Copilot Chat、Cline、Roo Code、Kilo Code 與 Continue將 VS Code 連接至 Unquant:透過 GitHub Copilot Chat 的自備金鑰功能,或 Cline、Roo Code、Kilo Code 與 Continue 擴充功能,分別完成各自的 OpenAI 相容設定。
- 如何在 OpenCode 中新增 Unquant在 opencode.json 中,將 Unquant 新增為 OpenCode 的 OpenAI 相容供應商,讓這款終端機程式開發 agent 使用 GLM-5.3-Flash,享有 262K 情境視窗與無限 token。
- 用於程式開發與 agent 的無審查 AI開發者為何選擇無審查模型來撰寫程式與執行 agent:處理資安工作、逆向工程或爭議性內容流程時不會遭到拒絕,還有 262K 情境視窗與無限 token,支援 agent 長時間反覆執行任務。