Skip to content

Releases: alexei-led/claude-router

v1.15.0

Choose a tag to compare

@github-actions github-actions released this 22 Oct 07:38
v1.15.0
168334f

A routing mode trades cost against answer quality without new routes: cost, balanced (the default, unchanged) or quality. See Routing modes.

Added

  • cost takes the route of the tier below when its model has a lower input price, else one effort level less; quality one effort level more, else the route of the tier above. micro turns and pins keep the configured route. docs/routing-modes.md lists the route of every classifier tier and activity in each mode.
  • Choose the mode for this session with /router mode cost|balanced|quality (/router mode default clears it; a resume keeps it), for a project with { "mode": "cost" } in .claude/router.json, or for the profile with "mode" in router.json or Mode on the Policy tab. A project file with any other key is ignored with a notice.
  • modes.cost.policy and modes.quality.policy replace those policy fields while that mode is active. The built-in values are not tuned on this router.
  • The band, the Now tab and /router show the mode and its source, such as cost (session); the prompt footer names a mode other than balanced.
  • The routing decision at the start of each turn writes one router decision line to Claude Code's debug log: mode, source, the classifier's tier, the tier and reason chosen, and the route. Moves later in the turn write none.

Changed

  • The router keeps the route a turn ran instead of rebuilding it from router.json. A mode change, or a route edited mid-session, now reaches the request through the usual checks, not on the next request.
  • A cheaper route inside the same tier on the same task now waits for minDwellRequests and a passed check, as a move to a cheaper tier does.

Fixed

  • The switching cost of two routes that share a prompt cache (one model at two efforts, on an API key or a subscription) is now zero, as the configuration docs said. The estimate charged the new tokens of the next request as a switch cost, though either route writes them. A cheaper effort on the same model was therefore refused on any measured history. In balanced a tier switch between such routes, such as Opus at medium and at xhigh, now needs only the base support (upgradeBase, downgradeMass); before, the bar rose with that estimate, up to about 0.82 on a cold cache.

Known limitations

  • The Policy tab shows the base policy bars; in cost or quality the band shows the bar actually in use, such as Jev 46% < 85%.

Migration

  • router.json needs no change: without mode it runs balanced.
  • Usage records are version 2 under the same usage:v1:<session id> keys, with the mode in each cell. Records from before read as balanced. A session of an older version reads a version 2 record as empty and never deletes it. Going back to 1.14 and resuming a session that 1.15 recorded replaces that session's record with a new one: its 1.15 days are lost.
  • A project's .claude/router.json can choose the mode for anyone who runs Claude Code there, with no trust prompt. It cannot change routes, models or the classifier; keep it out of a repo you share if the choice is yours alone.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.15.0
  • Tag: v1.15.0
  • Commit: 168334f1bf2e409a3e5d59d43995af74bd25c9db

v1.14.0

Choose a tag to compare

@github-actions github-actions released this 14 Oct 09:44
v1.14.0
12f66aa

Subagents now show which model each agent ran on, who picked it, and for which period. See Understand usage and estimates.

Changed

  • SUBAGENTS on the Usage tab follows the period row instead of summing every session since the last reset, and says its scope: this session, or all projects and the dates. Each agent is a square colored by the model it ran on, filled when the router moved it off Claude Code's pick. The routed types and the pass-throughs are one row each with agents, cost and the difference against Claude Code's pick, so a row no longer wraps; a row opens to its models. Each pass-through says why Claude Code picked the model.
  • The band in a subagent's transcript names the agent's model and who picked it: ■ Haiku 5.5 · moved down by the router · Claude Code: Opus 5.5, or □ Opus 5.5 · Claude Code’s pick: the workflow sets it.
  • The Usage tab's scope line says all projects instead of all sessions: the records cover every project that uses this router install.
  • Subagent records are kept by day and by model, version 2 under the same subagents:v1:<session id> keys. Records from before this version have no date or model: Session and All add them as one line.

Added

  • SUBAGENTS on the Now tab, once this session started a subagent: how many run now, the squares, and what routing saved on them.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.14.0
  • Tag: v1.14.0
  • Commit: 12f66aa46866b254db9c9b29a3736515fcf9061b

v1.13.0

Choose a tag to compare

@github-actions github-actions released this 13 Oct 15:56
v1.13.0
9daad7d

The Now tab shows this session and today instead of the last 30 replies, a window that matched no session, hour or day. See Open the router pane.

Changed

  • SESSION replaces LAST 30 REPLIES. Its strip colors every reply of the session by tier; past 48 cells, or on a narrow pane, pairs of cells merge and the strip says how many replies a cell holds. After a restart of Claude Code the strip starts again and says since when. Its heading gives since when, the routed replies and the route switches. The switches are the ones the Usage tab counts, so a pin is not one. The replies per tier and per activity follow.
  • Pin next replaces the TIERS ladder: one button per tier with the classifier's support, ▶ on the tier that runs now. The tab is four rows shorter.

Added

  • last switch on the Now tab: when the route last changed, between which tiers, or between which routes inside a tier, and the activity. It includes the moves inside a turn that raise the Model changed toast.
  • What routing saved or cost against your model this session, with the switch cache writes in it, and a Usage link that opens the Usage tab on Session.
  • TODAY, once another session added to today: the same line for every session today, with a Usage link on Today.
  • WORTH A LOOK · today: the Usage tab's first finding for today, from 20 replies, with its link to Routes or Policy.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.13.0
  • Tag: v1.13.0
  • Commit: 9daad7d7830b03c082da522f8223db5ef340aef6

v1.12.0

Choose a tag to compare

@github-actions github-actions released this 13 Oct 12:07
v1.12.0
0fea7ae

The Usage tab now shows any period, not only this session and the time since the last reset. See Compare routing with your model.

Added

  • Periods on the Usage tab: Session, Today, 7d, 30d, Month and All. Press p for the next one; the choice is kept across sessions. Each session now keeps its routed usage by local calendar day in usage:v1:<session id>, for 400 days.
  • A ledger that adds up in whole cents: your model, minus cheaper models, plus stronger models, plus switch cache writes, equals routed. A line under it gives replies, turns, input, cache hit and output.
  • The period's cost by activity, model or tier (g), with each row opening to its routes or activities.
  • The cost per hour, day or week, and What if (c): the period's tokens on each model alone.
  • Worth a look, from 20 replies: the cell that carried most of the cost, switch writes that ate the saving, the cell that ran above your model. Each links to Routes or Policy. It never names a model to use.

Changed

  • Delete history replaces Reset stats. It asks once more, then deletes the usage, activity and subagent records of every session. To look at a shorter span, pick a period.
  • The plan quota leaves the pane: Claude Code shows it in /usage. Claude's readings and details move to the Now tab. The session's tool Agreement moves to the Classifier tab.
  • All adds the totals earlier versions kept without dates, with a note; the other periods start from the first dated day.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.12.0
  • Tag: v1.12.0
  • Commit: 0fea7aea77a5a30bf22b7ac219002d371a1c5b34

v1.11.0

Choose a tag to compare

@github-actions github-actions released this 13 Oct 09:25
v1.11.0
b7cf748

Clef Omni joins Clef and Clef Flash as a third Cloudflare classifier. It costs less than Clef, and in Cloudflare's benchmarks it leads the Clef family on intent classification.

Added

  • Clef Omni (clef-omni), Cloudflare's 30B mixture-of-experts model (3B active) on Workers AI, as a built-in classifier. Select its row on the Classifier tab, or set "classifier": "clef-omni". It takes the same system-one request and the same Cloudflare API token and account ID as Clef, with a 3,000 ms deadline. Cloudflare's list price is $0.15 per million input tokens, between Clef Flash ($0.038) and Clef ($0.24); output is free.
  • The user guide compares the three Clef models on price and on Cloudflare's published benchmarks. No model wins every task.

Router sends Clef Omni text only, not images, audio or video. Clef Omni has no activity probe yet, so its Classifier tab row shows no accuracy or p95 latency. Router has not measured its routing quality, and its probabilities have not been compared with Jev's.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.11.0
  • Tag: v1.11.0
  • Commit: b7cf7488e3f4f4a91328d2bd8649a5cbda3a6353

v1.10.5

Choose a tag to compare

@github-actions github-actions released this 11 Oct 11:21
v1.10.5
6cce84b

The route now follows the task while it runs, for the tier and the activity, in both directions. Before, a turn was
routed once, from its prompt, and a continuation prompt could only keep the route. A team worker whose /goal brief
read as ops ran on Haiku · high and kept it for 100+ requests of coding. See
Changes during a task.

Added

  • A turn whose own tool calls edit a code file moves at once to the tier's code route (docs for doc-only edits), shown as ↗ coding with a toast. The tools are the evidence, so no classifier support is needed and the cache cost does not hold the move back; only the cash cap on a credits-billed model can, priced at the route the context fits. It only goes up and skips pinned turns and activityRouting: off.
  • Classifier reviews inside a turn: every policy.reviewEveryRequests requests (default 4; 0 turns them off) the classifier is asked again in the background, with the turn's prompt and recent dialogue. A step never waits; the answer applies at the next step and can move the tier or the activity either way. Each review sends the classifier the same kind of text a new turn does.
  • policy.minDwellRequests (default 8) and a checkpoint for cheaper routes on the running task: a downgrade or a cheaper activity waits for that many requests after the last model change and for the last test, build, lint or type-check command since then to pass. Until then the route stays: a tier shows … down after a passed check (reason downgrade-held), a held activity keeps the running one. A check is a test runner, type checker or linter, or a launcher running one (npm test, go test, make lint), alone or after &&; a piped check (npm test | tail), ;, || true, package names and paths do not count. A cheaper activity also needs policy.downgradeMass probability.

Changed

  • A downgrade lands on the cheapest tier the answer supports as a whole, not only on the chosen tier. A split answer (micro 0.63, low 0.3) on high now moves to low instead of staying until micro alone reaches 0.9, and a cold candidate can give way to a warm tier between it and the incumbent.
  • A prompt the classifier scores as a continuation of the task no longer keeps the route by itself. It is decided like a review: up on the usual votes, down past the checkpoint. The continuation reason is gone. policy.continuationMass now only decides whether a prompt counts as the running task.

Fixed

  • Replies after an in-turn move are labelled with the activity they ran on, not the turn's first label; the classifier's answer stays as recorded for the stats.

The review interval, the dwell and the checkpoint are starting values, not tuned on data.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.10.5
  • Tag: v1.10.5
  • Commit: 6cce84b16ab793b14c50555d0ba3d594ab503aaa

v1.10.3

Choose a tag to compare

@github-actions github-actions released this 11 Oct 07:30
v1.10.3
a289b4e

Fixed

  • Activity stats kept across sessions (classifier vs tools, runs, activity moves) no longer lose counts when two sessions finish turns at the same moment, and a session that read them before Reset stats can no longer write them back. Each session now keeps its own activity:stats:v1:<session id> record, summed on read like the other counts. The single key earlier versions shared still counts until the next Reset stats deletes it. After running this version, 1.10.2 or earlier shows only the counts in that shared key.
  • A one-turn pin is no longer lost when the turn is interrupted before its route is set, and a pin pressed again while a pinned turn chooses its model now serves the next turn.
  • A subagent spawn keeps core's model when the router cannot read the settings, since they may limit the models through availableModels.
  • An agent definition file that could not be read is read again at the next spawn of its type, instead of passing that type through for the rest of the session.
  • The Now tab's Why line gives a sentence, not a raw key, for a turn routing did not choose, routing off, a model fallback by Claude Code, and an interrupted turn.
  • The Classifier tab names the host a request actually reaches: user info before @ in an endpoint is not shown as the host, and an endpoint on [::1] shows as this machine.
  • scripts/migrate-config.mjs refuses to write through a symlink, writes the converted file beside router.json and renames it into place, and removes its backup after a failed write, so the next run starts clean.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.10.3
  • Tag: v1.10.3
  • Commit: a289b4ef35bde595d18f3a0cd615e7346f5ae01e

v1.10.2

Choose a tag to compare

@github-actions github-actions released this 11 Oct 05:22
v1.10.2
7e886ca

Fixed

  • Different npm test failures that share a runner header no longer trigger a false model escalation. Repeated-failure matching fingerprints the full normalized error output instead of its first 120 characters. Test names, case, whitespace, and numeric error values stay distinct; empty errors are ignored. Known source positions and runner timings remain comparable across retries.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.10.2
  • Tag: v1.10.2
  • Commit: 7e886ca6ebbf3b207e2a8482afcbff4697e88145

v1.10.1

Choose a tag to compare

@github-actions github-actions released this 11 Oct 05:13
v1.10.1
f73713e

Removed

  • shadow mode, from both activityRouting and subagentRouting. Each now takes off or on. A router.json that still sets "shadow" is read as not setting the key, so the default, on, runs; the next save from the pane drops it. To keep the base routes, set off. /router activities takes off or on. Gone with it: the Shadow line on the Now tab, the (shadow) label on the band, the "if activity routing were on" estimate and the Shadow counts on the Usage and Classifier tabs, and the shadow section of SUBAGENTS.
  • Counts kept across sessions drop their shadow figures and keep the rest. After running this version, 1.10.0 or earlier resets the activity counts kept across sessions.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.10.1
  • Tag: v1.10.1
  • Commit: f73713edcdac2b94e83951a9ec8ff354befee03d

v1.10.0

Choose a tag to compare

@github-actions github-actions released this 10 Oct 18:43
v1.10.0
60e6fc2

Changed

  • The pane has five tabs: Now, Routes, Policy, Classifier, Usage (1–5). The old Routing tab is split in two, and each tab now answers one question.
  • Routes is one grid of tiers by activities. Each cell shows the model it runs: · for the tier's model, ° for a built-in default, ● for an unsaved edit. Select a cell to edit it. remove is now Use tier model, and Restore default puts a built-in override back. 5 distinct routes · 3 caches now reads 3 prompt caches in use: one per model, with what a cold cache costs.
  • Policy writes each control as a sentence, such as Going down after 2 ▾ agreeing turns, shows the default beside a changed value, and says when the credits cap has no effect.
  • Now leads with the next turn's model and why. The letter row under the replies strip (eeccoo…) is gone; replies are counted per tier and per activity instead, such as coding 12 · exploring 4.
  • Classifier compares the classifiers in one table (where the prompt goes, probe, p95 wait, status) and flags a deadline shorter than the real wait. The counts across sessions moved here from Usage.
  • Usage opens with the answer, such as Routing saved $1.84 (22%) this session vs Opus 5.5 · xhigh. Claude's readings fold to one line behind details.

Fixed

  • The Now picture in the docs showed 0 switches next to a strip with three tier changes.

Package

  • Name: @alexeiled/claude-router
  • Version: 1.10.0
  • Tag: v1.10.0
  • Commit: 60e6fc218d521d5a781427e50ac28ed681548c3f