clawcu 文件 简 EN ID

文件 / 工具接入 / Hermes Agent

在 Hermes Agent 裡使用 clawcu

Hermes 用「自訂端點(Custom endpoint)」接 clawcu。下面四條命令等價於在 hermes model 嚮導裡選 Custom endpoint 後填寫地址、模型和 Key。

協議OpenAI 兼容(/v1/chat/completions)
地址https://token.clawcu.ai/v1
配置檔案~/.hermes/config.yaml

可用模型:kimi-k3(編碼綜合最強,本頁預設)、glm-5.3、deepseek-flash(最便宜、最快)。完整清單與價格以控制台 模型 頁或 GET /v1/models 為準。

準備

在控制台 API Keys 頁創建一把 Key(明文只顯示一次),設成環境變數 CLAWCU_LLM_KEY,下面的配置都從這裡讀取:

export CLAWCU_LLM_KEY=sk-你的Key

Windows(PowerShell)

$env:CLAWCU_LLM_KEY="sk-你的Key"

想長期生效,把這一行加進 ~/.zshrc / ~/.bashrc;Windows 用 setx CLAWCU_LLM_KEY sk-… 後重開終端。

安裝

官方安裝腳本(只需要 Git;Windows 用戶建議在 WSL2 裡按下面的步驟操作):

curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash
export PATH="$HOME/.local/bin:$PATH"

配置

Key 寫成 '${CLAWCU_LLM_KEY}'(單引號,原樣儲存),Hermes 運行時從環境變數讀取,配置檔案裡不出現明文:

hermes config set model.provider custom
hermes config set model.base_url https://token.clawcu.ai/v1
hermes config set model.default kimi-k3
hermes config set model.api_key '${CLAWCU_LLM_KEY}'

驗證

看到回覆 OK 就說明已經連上 clawcu:

hermes -z "Reply with exactly: OK"

日常使用

運行 hermes 進入對話;換預設模型:hermes config set model.default glm-5.3。

hermes

常見問題

安裝時提示 cua-driver 安裝失敗(缺 libXi 等)?

那是「電腦操作」組件,在沒有桌面的 Linux 伺服器上會跳過,不影響對話與編碼。

提示 401 API Key 無效?

運行 Hermes 的終端裡要有 CLAWCU_LLM_KEY;用 hermes config get model.api_key 確認存的是 ${CLAWCU_LLM_KEY} 而不是空值。

視覺、網頁摘要等輔助任務用哪個模型?

預設跟隨主模型(auxiliary.*.provider: auto);需要的話可在 config.yaml 裡單獨指定。

其他工具:Claude Code · Codex CLI · OpenCode · OpenClaw