v0.12 migration notes
Operator-facing summary of what changes when you upgrade pmk gateway from v0.11.x to v0.12.0.
TL;DR
✅ Zero config changes required if you already have ANTHROPIC_API_KEY set.
✅ Existing ~/.pmk/gateway.json is back-fill-compatible (apiKey field
is optional and additive).
✅ Users without an API key keep running on the claude-agent fallback —
no behavioural change.
✅ Cap defaults bumped 25k/12k/16k → 60k/30k/40k. PMK_*_CAP still
overrides per host.
What changed
Provider auto-resolution
Before (v0.11.x):
1. local `claude` binary → ClaudeAgentSdkProvider
2. ANTHROPIC_API_KEY → AnthropicApiKeyProvider
3. fail
After (v0.12.0):
1. ANTHROPIC_API_KEY (or config.apiKey) → AnthropicApiKeyProvider
2. local `claude` binary → ClaudeAgentSdkProvider (fallback)
3. fail
Why: ClaudeAgentSdkProvider spawns the local claude CLI and inherits the host's ~/.claude/ config (skills/hooks/MCP descriptions) as un-budgeted system context. On a heavy host this can add 10s of thousands of tokens to every API call. AnthropicApiKeyProvider calls the API directly with a clean system prompt — no overhead, predictable budgets.