跳至主要內容
所有用戶端
Terminal Agent · 29k★1M Context · ZDR

Crush (Charm)

Charm 推出的 LSP 終端編程智能體(charmbracelet/crush),透過 ~/.config/crush/crushrc 或 Catwalk 直連 bf16.ai 1M 免審查模型。

基礎網址
https://api.bf16.ai/v1
協定
openai-completions

適用對象
在 macOS、Linux 或 Windows 終端使用 Charm Crush、追求高速 1M 上下文與嚴格零留存的開發者。

架構原理與接入優勢

Charm Crush TUI configured via ~/.config/crush/crushrc and Catwalk connecting to api.bf16.ai 1M uncensored models
Crush uses a native Bash-powered crushrc (`provider add bf16 --type completions`) and Catwalk’s provider registry to stream 1M-context reasoning and tool calls directly from api.bf16.ai.

Crush (charmbracelet/crush, 29k+ ★) is Charm’s cross-platform terminal coding agent with built-in LSP diagnostics, multi-session project contexts, mid-session model switching, and MCP tool support.

Modern Crush uses a built-in Bash interpreter (`~/.config/crush/crushrc` or per-project `./.crushrc`) so you can register `bf16` with a single `provider add bf16 --type completions` block and pull your key cleanly from `$BF16_API_KEY` or a password manager.

We have also submitted a native `bf16` provider with automated catalog sync to Charm’s Catwalk database (`charmbracelet/catwalk#790`) — pairing GLM-5.3 Flagship as large model and DeepSeek V4.1 Flash as small model with 1M context and `low`/`medium`/`high`/`max` reasoning effort.

指令預設顯示 $BF16_API_KEY。登入並建立金鑰後會自動填入你的真實金鑰。

一鍵快速配置

Append bf16.ai Provider & 1M Models to ~/.config/crush/crushrc

Creates ~/.config/crush/crushrc (preserving existing lines), registers bf16 with GLM-5.3 Flagship and DeepSeek V4.1 Flash, and verifies your API key.

export BF16_API_KEY="sk-bf16-v1-..."
mkdir -p "$HOME/.config/crush"
cat <<'EOF' >> "$HOME/.config/crush/crushrc"

# bf16.ai — Uncensored 1M-context models (Strict ZDR)
provider add bf16 --type completions --base-url "https://api.bf16.ai/v1" --api-key "$BF16_API_KEY"
model add bf16/zai-org/glm-5.3-uncensored --name "GLM-5.3 Flagship (Uncensored)" --context-window 1048576
model add bf16/deepseek/deepseek-v4.1-flash-uncensored --name "DeepSeek V4.1 Flash (Uncensored)" --context-window 1048576
EOF
curl https://api.bf16.ai/v1/models -H "Authorization: Bearer $BF16_API_KEY"
  1. 1

    設定你的 bf16.ai API 金鑰

    Create an API key at bf16.ai/dashboard/keys and export `BF16_API_KEY` in `~/.zshrc` or `~/.bashrc` so Crush’s `crushrc` reads it securely at startup.

    export BF16_API_KEY="sk-bf16-v1-..."
  2. 2

    填入 bf16.ai 端點與 1M 免審查模型

    使用頁面提供的 Base URL 與 API 金鑰,即可立即存取全系 1M 上下文免審查模型(含零留存政策)。

    ~/.config/crush/crushrc
    provider add bf16 \
      --type completions \
      --base-url "https://api.bf16.ai/v1" \
      --api-key "$BF16_API_KEY"
    
    model add bf16/zai-org/glm-5.3-uncensored \
      --name "GLM-5.3 Flagship (Uncensored)" \
      --context-window 1048576
    
    model add bf16/deepseek/deepseek-v4.1-flash-uncensored \
      --name "DeepSeek V4.1 Flash (Uncensored)" \
      --context-window 1048576
  3. 3

    Launch Crush & Switch to bf16.ai

    Start `crush` in any Git repository, open the model picker, and select GLM-5.3 Flagship or DeepSeek V4.1 Flash under `bf16`.

    crush
Crush — ~/.config/crush/crushrc · provider add bf16
介面與設定檔欄位對照
~/.config/crush/crushrc (or ./.crushrc in project root)

關鍵參數核對清單

Provider Command
provider add bf16 --type completions
Base URL
https://api.bf16.ai/v1
API Key Env
$BF16_API_KEY
Recommended Models
zai-org/glm-5.3-uncensored (Large) · deepseek/deepseek-v4.1-flash-uncensored (Small)

1,048,576 context window · toggleable reasoning_effort

Crush executes crushrc via its embedded Bash engine on macOS, Linux, and Windows — identical config syntax everywhere.

推薦模型分層配置

架構規劃使用旗艦模型,高頻子任務與螢幕截圖使用 Flash 模型以節省開銷。

工作流角色模型 ID選型說明USD / 1M Tokens
Crush Large Model (Primary Reasoning & Refactoring)zai-org/glm-5.3-uncensored1M context, 131K max output, deterministic LSP-assisted edits, and zero refusals on security or low-level systems code.$1.35 in / $0.25 cached / $4.20 out
Crush Small Model (Fast Search, Summaries & Vision)deepseek/deepseek-v4.1-flash-uncensored1M context at ~155 tok/s with image support and $0.045/1M cached prompt reads.$0.26 in / $0.045 cached / $1.00 out
Long-Context Multimodal Analysismoonshotai/kimi-k3.1-pro-uncensoredFrontier 1M multimodal model for cross-file architectural audits and screenshot debugging.$1.95 in / $0.28 cached / $6.90 out

如何確認設定成功

  • 發送測試訊息後,可在 bf16.ai 控制台請求紀錄中即時查看計費與狀態。
  • curl https://api.bf16.ai/v1/models -H "Authorization: Bearer $BF16_API_KEY"

生產環境護欄與預算隔離

  • Avoid hardcoding raw `sk-bf16-...` keys inside project-local `./.crushrc` files; always reference `$BF16_API_KEY` or a secret manager CLI.
  • Use DeepSeek V4.1 Flash as your Crush small model for fast title generation and file summarization while reserving GLM-5.3 Flagship for complex edits.

常見錯誤

現象
連線測試出現 404 或驗證失敗。
原因
端點網址多加或漏寫了 /v1 後綴。
解法
請嚴格對照本頁顯示的 Base URL 複製貼上。

還沒安裝?

brew install charmbracelet/tap/crush
官方文件