by bitrouter
The self-improving LLM router that optimize your agentic workflows with every runs, works with any harnesses, any models, any loops.
# Add to your Claude Code skills
git clone https://github.com/bitrouter/bitrouterGuides for using ai agents skills like bitrouter.
Last scanned: 6/5/2026
{
"issues": [],
"status": "PASSED",
"scannedAt": "2026-06-05T08:07:54.884Z",
"npmAuditRan": true,
"pipAuditRan": true
}The self-improving LLM router that optimize your agentic workflows with every runs, works with any harnesses, any models, any loops.
You're tokenmaxxing in production. Every step of every loop bills at frontier prices — file reads, tool calls, sub-agent hops, retries. Most don't need it. BitRouter routes each call, tool, and agent to the cheapest path that still reaches the goal, and tightens that routing as the loop runs.
Cost is live today — latency and accuracy are next.
An agentic loop consumes three things. Other routers govern only the first. BitRouter makes all three routable, observable, and governed:
Optimizing a loop isn't just model selection — it's choosing the model, the tool, and the sub-agent that best serve the loop's objective at every step that gets it to its goal.
BitRouter wraps your agentic loop in a second loop. Each loop gets its own policy spec — a config file that declares how its calls, tools, and agents should route. Against that spec BitRouter runs a continuous act → observe → evaluate → learn cycle, and every step is a component it already ships:
You choose what the loop optimizes for — cost, latency, or accuracy — and it improves the longer it runs in production.
Today cost is the validated objective: on Terminal-Bench 2.1, gpt-5.5 with BitRouter cut cost 32.8% at near-parity accuracy (−1.1 pp), by offloading routine steps to a cheaper model. Latency and accuracy objectives — and more base models — are landing next.
| Base model | Cost vs baseline | Latency vs baseline | Accuracy vs baseline |
|---|---|---|---|
gpt-5.5 |
**−32.8%**¹ | coming soon | coming soon |
gpt-5.6 |
coming soon | coming soon | coming soon |
claude-opus-4.8 |
coming soon | coming soon | coming soon |
claude-sonnet-5 |
coming soon | coming soon | coming soon |
claude-fable-5 |
coming soon | coming soon | coming soon |
¹ Cost-optimization run on Terminal-Bench 2.1: −32.8% zero-cache imputed cost (audited range 28.6–32.8% by cache share) at near-parity accuracy, −1.1 pp (76.1% vs 77.3%, within single-attempt noise).
This is a mechanism study under a modified protocol, not a Terminal-Bench leaderboard submission — read the experiment limitations before citing the numbers. Full reports live in benchmarks/; complete traces, tool calls, usage, policy decisions, configs, and checksums are in the BitRouterAI/benchmarks dataset.
Every gateway below routes model calls. BitRouter is the only one that also makes tools and agents routable, and optimizes the whole loop rather than a single call.
| BitRouter | OpenRouter | LiteLLM | TensorZero | Portkey | Bifrost | |
|---|---|---|---|---|---|---|
| Routable primitives | Models + tools + agents (MCP + ACP) | Models | Models + tools (MCP) | Models | Models + tools (MCP) | Models + tools (MCP) |
| Optimizes | The loop, multi-objective (cost today) | Static routing | Static routing | The model | Static routing | Static routing |
All but OpenRouter are open-source and self-hostable; BitRouter and TensorZero are Rust.
# macOS / Linux
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/bitrouter/bitrouter/releases/latest/download/bitrouter-installer.sh | sh
# Homebrew
brew install bitrouter/tap/bitrouter
# npm
npm install -g bitrouter
cargo install bitrouter
BitRouter is a local proxy between your agent and every LLM provider. One env-var swap — no harness changes required:
- OPENAI_BASE_URL=https://api.openai.com/v1 # hardwired to one provider, no fallback
+ OPENAI_BASE_URL=http://localhost:4356/v1 # all providers, automatic failover
BitRouter runs as a local daemon — start it with your own keys or a Cloud sign-in.
Bring your own keys (BYOK) — auto-detected from the environment, no config file needed:
export OPENAI_API_KEY=sk-... # ANTHROPIC_API_KEY / GEMINI_API_KEY also work
bitrouter start # proxy running at http://localhost:4356
Or sign in to BitRouter Cloud — use browser OAuth interactively or store an existing API key in CI:
bitrouter cloud login # RFC 8628 device flow against api.bitrouter.ai
bitrouter cloud login --api-key "$BITROUTER_API_KEY" # non-interactive CI login
bitrouter start # `bitrouter` provider auto-enables once signed in
The same credential also drives a gh api-style raw client—no daemon required:
bitrouter cloud api /v1/models
bitrouter cloud api /v1/chat/completions --input request.json
Point your agent runtime at http://localhost:4356 and any available provider is live. For advanced routing rules, guardrails, or multi-account failover, scaffold a config with bitrouter init (writes ./bitrouter.yaml).
bitrouter start / stop / restart # daemon lifecycle
bitrouter route <model> # trace how a model name resolves
bitrouter key sign --user <id> # mint a scoped brvk_ API key
bitrouter cloud keys / usage / billing # manage your cloud account
bitrouter cloud api /v1/models # call Cloud APIs directly
See CLI.md for the full command reference, flags, and config resolution.
BitRouter ships an Agent Skill — /bitrouter — so AI
coding agents can install, configure, migrate to, and troubleshoot BitRouter on
their own. It lives in this repo at skills/bitrouter/, kept in sync
with the code.
bitrouter skills add bitrouter # via BitRouter's own installer
npx skills add bitrouter/bitrouter # via the generic skills CLI
Use BitRouter from any MCP client — it exposes complete, list_models, and status as MCP tools (the origin server, distinct from the MCP gateway that proxies your own MCP servers):
bitrouter mcp serve # stdio → local daemon at 127.0.0.1:4356
bitrouter mcp install --client claude # print the Claude/Cursor mcpServers config block
Add --transport http to target the multi-tenant cloud backend.
BitRouter exposes an OpenAI- and Anthropic-compatible HTTP API on http://localhost:4356, so any SDK or client works unchanged. The full endpoint reference and OpenAPI spec live in bitrouter/bitrouter-docs (rendered at bitrouter.ai).
Ready-made **policy spe
bitrouter is an open-source ai agents skill for AI coding assistants such as Claude Code, Codex CLI, and ChatGPT, built by bitrouter. The self-improving LLM router that optimize your agentic workflows with every runs, works with any harnesses, any models, any loops. It has 208 GitHub stars.
Yes. bitrouter passed SkillsLLM's automated security scan — a dependency vulnerability audit plus prompt-injection heuristics — with no high-severity issues. You can read the full report in the Security Report section on this page.
Clone the repository with "git clone https://github.com/bitrouter/bitrouter" and add it to your Claude Code skills directory (see the Installation section above).
bitrouter is primarily written in Rust. It is open-source under bitrouter on GitHub, so you can review or fork the full source.
Yes. SkillsLLM lists many other AI Agents skills you can browse and compare side by side. Open the AI Agents category from the badge at the top of this page, or use the Related Skills and comparison links further down to weigh bitrouter against similar tools.
No comments yet. Be the first to share your thoughts!