Agents
Setup guide

Claude Code with an uncensored model

To run Claude Code with an uncensored model, point ANTHROPIC_BASE_URL at an API that serves abliterated models in the Anthropic Messages format.

Updated
FormatAnthropic Messages
Endpoint/v1/messages
Configured in~/.claude/settings.json
Switch with/model and /effort
Context1,048,576

Which model to use in Claude Code

ModelUse it forModel id
Kimi K3.1 ProHard multi-file and security workkimi-k3.1-pro-uncensored
DeepSeek V4.1 FlashEveryday work, and the default heredeepseek-v4.1-flash-1017-uncensored
GLM-5.3A second opinion, text onlyglm-5.3-uncensored
GLM-5.3 FlashBulk edits and many subagentsglm-5.3-flash-uncensored

Set it up

  1. Install Claude Code
    Shell
    curl -fsSL https://claude.ai/install.sh | bash
    PowerShell
    irm https://claude.ai/install.ps1 | iex
  2. Set your API key

    Create a key at Silk Compute, export it, and add the line to ~/.zshrc or ~/.bashrc.

    Shell
    export SILK_API_KEY="sk-..."
  3. Add the models

    Paste this into ~/.claude/settings.json, or add these keys to the settings already there.

    ~/.claude/settings.json
    {
      "apiKeyHelper": "echo $SILK_API_KEY",
      "env": {
        "ANTHROPIC_BASE_URL": "https://api.silkcompute.com",
        "ANTHROPIC_DEFAULT_MODEL": "deepseek-v4.1-flash-1017-uncensored",
        "ANTHROPIC_DEFAULT_FABLE_MODEL": "kimi-k3.1-pro-uncensored",
        "ANTHROPIC_DEFAULT_OPUS_MODEL": "kimi-k3.1-pro-uncensored",
        "ANTHROPIC_DEFAULT_SONNET_MODEL": "deepseek-v4.1-flash-1017-uncensored",
        "ANTHROPIC_DEFAULT_HAIKU_MODEL": "deepseek-v4.1-flash-1017-uncensored",
        "CLAUDE_CODE_MAX_CONTEXT_TOKENS": "1048576"
      },
      "modelPicker": {
        "replaceBuiltInOptions": true,
        "options": [
          { "model": "kimi-k3.1-pro-uncensored", "label": "Kimi K3.1 Pro" },
          {
            "model": "deepseek-v4.1-flash-1017-uncensored",
            "label": "DeepSeek V4.1 Flash 1017"
          },
          {
            "model": "deepseek-v4.1-flash-1017-fast-uncensored",
            "label": "DeepSeek V4.1 Flash 1017 Fast"
          },
          { "model": "glm-5.3-uncensored", "label": "GLM-5.3" },
          { "model": "glm-5.3-flash-uncensored", "label": "GLM-5.3 Flash" },
          { "model": "hy4-uncensored", "label": "Hy4" }
        ]
      }
    }
  4. Run it
    Shell
    claude

    Switch models with /model and reasoning effort with /effort.

  5. Check the key

    A list of models means the key works, and a 401 means SILK_API_KEY is empty or wrong.

    Shell
    curl -s https://api.silkcompute.com/models -H "Authorization: Bearer $SILK_API_KEY"

What each setting does

SettingWhat it does
apiKeyHelperLets you "run your own command to produce the credential", so the key stays out of the file (settings reference).
ANTHROPIC_BASE_URLSends every request to https://api.silkcompute.com instead of Anthropic (environment variables).
ANTHROPIC_DEFAULT_MODELThe model a new session starts on.
ANTHROPIC_DEFAULT_OPUS_MODEL
ANTHROPIC_DEFAULT_FABLE_MODEL
Points the opus and fable aliases at Kimi K3.1 Pro.
ANTHROPIC_DEFAULT_SONNET_MODEL
ANTHROPIC_DEFAULT_HAIKU_MODEL
Points sonnet and haiku at DeepSeek V4.1 Flash 1017, so subagents get a model the API serves.
CLAUDE_CODE_MAX_CONTEXT_TOKENSSets the context to 1,048,576 tokens.
modelPickerLists these models in /model.

Limits

  • Anthropic server tools such as web search are not available.
  • Kimi K3.1 Pro can't take video, because the Anthropic format carries none.
  • The model list also adds Hy4, which is not ranked here.

Other APIs that work with Claude Code

Three of the seven APIs for coding agents document the Anthropic Messages format Claude Code needs.

With a local model

Ollama "supports a subset of the Anthropic Messages API" (Ollama docs), and its guide points ANTHROPIC_BASE_URL at http://localhost:11434 (Claude Code on Ollama). Load one of the local abliterated models there, and expect less from it on large codebases.

Silk Compute's own guide is at silkcompute.com/docs/claude-code.