Skip to content
Development
Command

/doctor

Diagnose what is busting Claude Code's DeepSeek prefix cache

From plugin
permafrost
244 skills4 commands1 hook
> /plugin marketplace add jianzhichun/permafrost
> /plugin install permafrost@permafrost

Command definition

doctor.md
description: Diagnose what is busting Claude Code's DeepSeek prefix cache
allowed-tools: Bash(curl:*)

Diagnose the DeepSeek prefix cache for this session.

Pull the proxy's alignment report and prefix-change history:

!`curl -fsS "http://127.0.0.1:${PERMAFROST_PORT:-8787}/permafrost/doctor" 2>/dev/null || echo '{"error":"proxy not reachable — start it with: permafrost up"}'`

Also check the two environment knobs that most often break the cache under a custom endpoint:

!`echo "ANTHROPIC_BASE_URL=${ANTHROPIC_BASE_URL:-<unset>} ENABLE_TOOL_SEARCH=${ENABLE_TOOL_SEARCH:-<unset>} PERMAFROST_MODE=${PERMAFROST_MODE:-aggressive}"`

Then explain to the user, in plain language:

  • Whether the cache **anchor (tools + system) is staying frozen** or churning, and the count of resets.
  • Any **volatile content** still detected in the system prefix (dates, git status, UUIDs, hashes) and what it costs.
  • If `ENABLE_TOOL_SEARCH` is not `true` while `ANTHROPIC_BASE_URL` is a custom host, warn that Claude Code is likely re-inlining the full tool set every turn (a major buster) and that it must be set **before** launching `claude`.
  • Concrete next steps (e.g. switch to `PERMAFROST_MODE=aggressive`, set the env var, restart the session).
@jianzhichun
Ships withpermafrost

Freeze Claude Code's prompt prefix so DeepSeek's automatic cache always hits — alignment proxy + coalescing + keepalive, installable as a CC plugin. Measured 64% cheaper on real Claude Code traffic.

Stars on GitHub

Momentum

stars in total
24
Star history of jianzhichun/permafrost on GitHub, a chart by star-history.com

Other commands on permafrost.

More commands from other plugins.

build
Auto-invoked

build

Command

Implement tasks incrementally — build, test, verify, commit. Add "auto" to run the whole plan in one approved pass.

@addyosmani@addyosmaniInstall Command