1. Install Node.js (Skip if installed)
Ensure Node.js version ≥ 18.0- Windows
- macOS
- Ubuntu / Debian
Uninstall Other Proxy Clients (Optional)
Check installation:2. Install Claude Code
3. Get API Key
4. Configure Environment Variables
Basic Configuration Example
- Mac / Linux
- Windows CMD
- Windows PowerShell
Dual Model Configuration
Claude Code uses a dual-threaded model architecture by default:-
Main Thread Model: Configured via
ANTHROPIC_MODELenvironment variable- Used for primary code generation, conversations, and complex task processing
-
Secondary Thread Model: Configured via
ANTHROPIC_DEFAULT_HAIKU_MODELenvironment variable- Purpose: Lightweight / fast-task model
- Use cases:
- Background tasks (file monitoring, linter checks, etc.)
- Quick responses (simple questions, completion suggestions)
- Low-priority auxiliary tasks
Basic Configuration (Dual Model, Recommended)
- Mac / Linux
- Windows CMD
- Windows PowerShell
Single Model Configuration (Optional)
If you only need to use a single model, there are two configuration methods: Method 1: Configure both environment variables to the same model Set bothANTHROPIC_MODEL and ANTHROPIC_DEFAULT_HAIKU_MODEL to the same model (for example, both use kimi-k2-250905):
- Mac / Linux
- Windows CMD
- Windows PowerShell
ANTHROPIC_DEFAULT_HAIKU_MODEL (i.e., claude-haiku-4-5-20251001).