# Bitrouter

> Analyze this codebase's LLM usage and reduce spend with BitRouter — run estimate, audit, or optimize, and read the live observed-savings widget. Use when the user asks about LLM cost, model routing, or BitRouter policy.

- Skill: `bitrouter/bitrouter-3` (Agent Skill)
- Install (CLI): `npx skillmds@latest add bitrouter/bitrouter-3`
- Raw SKILL.md: https://api.skillmd.com/api/skills/bitrouter/bitrouter-3/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: bitrouter (https://skillmd.com/u/bitrouter)
- Updated: 2026-09-22
- Page: https://skillmd.com/skills/bitrouter/bitrouter-3

---


# BitRouter

Help the user understand and reduce their LLM spend by routing their agent's
model traffic through BitRouter. This project is analyzed in place; nothing is
uploaded, and the user's own `bitrouter.yaml` is never overwritten.

## When to use

- The user asks how much they could save on LLM/model costs.
- The user wants a routing policy, or to tighten an existing one.
- The user asks what models this codebase calls and where cheaper routing fits.

## Tools

- **`estimate`** — Scan the codebase locally and estimate the savings from
  routing through BitRouter. Writes `.bitrouter/analysis.json`. No policy file.
- **`audit`** — Estimate plus a written review of routing opportunities. Writes
  `bitrouter-audit.md` and `.bitrouter/analysis.json`. No policy file.
- **`optimize`** — Tighten the routing policy from **real metered traffic** in
  the local `bitrouter.db`. Writes an observed report and a proposed
  `bitrouter.optimized.yaml`. Degrades to a cold-start audit when there is not
  enough traffic yet.

All three default to an offline / observed-offline path — deterministic and with
no network egress. Each returns a short summary and the artifact paths.

## Command

- **`/bitrouter`** — Run the observed optimizer over the current project and
  report the observed savings headline.

## Live widget

While a session is active, a widget above the editor shows the observed savings
headline when there is metered traffic, or a cold-start hint when there is not.

## Invariants

- **Zero-write to your inputs.** The tools never modify your environment, code,
  or existing `bitrouter.yaml`. Proposals go to `bitrouter.proposed.yaml` or
  `bitrouter.optimized.yaml`.
- **Local first.** Estimate/audit scan locally; optimize reads a copy of your
  metering DB. Nothing is uploaded.

