The AI Proxy for Claude Code
PromptBus routes every Claude Code request to the cheapest capable model automatically. Simple questions use Haiku. Complex work stays on Sonnet. Savings add up without you noticing.
▲ ~ npx promptbus install
✓ Claude Code configured
▲ ~ promptbus start
✓ Proxy on :4701 · Dashboard :4702
Start coding. Savings happen automatically.How it works
PromptBus sits transparently between Claude Code and the API. Every request is classified and routed to the optimal model.
Claude Code sends request to PromptBus proxy
PromptBus classifies task and routes to best model
Request reaches cheapest capable model automatically
What's in PromptBus?
Everything you need to optimize AI costs, nothing you don't.
Zero Configuration
Install and start. PromptBus automatically intercepts Claude Code traffic with no config changes needed.
Installation guideSafety-First Routing
Under 60% confidence? Request passes through unmodified. No downgrade means no quality loss, ever.
Architecture overviewMicrosecond Overhead
Keyword-based classification adds zero measurable latency to your requests. No extra API calls needed.
How classification worksCustom Routing Rules
Configure routing rules via YAML or the dashboard UI. Per-project policies, effort levels, and confidence floors.
Configuration guideFull Dashboard
Monitor routing decisions, track cost savings, edit rules, search logs, and export data from a local web UI.
Dashboard docsOpen Source, MIT
Audit the code, customize the rules, self-host. No accounts, no telemetry, no vendor lock-in. Free forever.
View on GitHubBuilt for efficiency
Lightweight, local, and transparent.
Dashboard
Real-time insights
Monitor routing decisions, track cost savings, and edit rules from a clean web interface at localhost:4702.
| Time | Type | Requested | Routed To | Effort | Action | Latency |
|---|---|---|---|---|---|---|
| 12:34:56 | read explain | sonnet-5 | haiku-4-5 | Low | ↓ Rerouted | 1.2s |
| 12:35:12 | small edit | sonnet-5 | sonnet-5 | Medium | → Passthrough | 3.4s |
| 12:35:45 | debug loop | sonnet-5 | sonnet-5 | High | → Passthrough | 8.1s |
| 12:36:20 | test generation | sonnet-5 | sonnet-5 | Medium | → Passthrough | 5.7s |
| 12:36:58 | read explain | sonnet-5 | haiku-4-5 | Low | ↓ Rerouted | 0.9s |
| 12:37:30 | multi file refactor | sonnet-5 | sonnet-5 | High | → Passthrough | 12.3s |
Get started in seconds
Three commands and you're saving money on every request.
Install
One command installs the proxy and configures Claude Code to route through it automatically.
Start
The proxy runs locally on port 4701. The dashboard is available at localhost:4702.
Ship
Every request is classified and routed to the optimal model. No workflow changes needed.
Start saving today
Free. Open source. No account required. Install PromptBus in under a minute and optimize your API costs automatically.