The Self-Hosted Model Playbook: From Hugging Face Download to Claude Code
You can run a coding-grade open model on your own GPU and point Claude Code at it in an afternoon: size the VRAM, budget the KV cache, serve with vLLM, put a keyed HTTPS endpoint in front, and set two environment variables. The map: seven steps, one request path One keyed HTTPS door sits between Claude Code and your GPU. Request path: Claude Code → HTTPS Proxy → Inference Engine → GPU Claude Code: Uses ANTHROPIC_BASE_URL and ANTHROPIC_AUTH_TOKEN. HTTPS Proxy: Caddy or a tunnel terminates TLS on port 443. Inference Engine: vLLM runs on 127.0.0.1 and checks the API key. GPU: Stores model weights and KV cache. Steps 1 to 5 build the right-hand side of this architecture, Step 6 adds the public door, and Step 7 sets the two variables on the left. Step 1: Pick the model for the GPU you have Start from your VRAM, not from a leaderboard: the best model is the largest one whose 4-bit weights leave room for context. Coding agents also need reliable tool calling, so favour models with a maint...