@alexeiled/claude-router 1.6.1 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +1 -1
- package/CHANGELOG.md +32 -0
- package/README.md +14 -4
- package/docs/activity-routing.md +254 -0
- package/docs/architecture.md +9 -3
- package/docs/configuration.md +56 -44
- package/docs/evaluation.md +32 -5
- package/docs/native-router.md +16 -13
- package/docs/router-band.svg +78 -80
- package/docs/router-pane-classifier.svg +7 -7
- package/docs/router-pane-now.svg +9 -9
- package/docs/router-pane-routing.svg +73 -87
- package/docs/router-pane-usage.svg +123 -0
- package/docs/user-guide.md +77 -53
- package/hooks/native-router.mjs +215 -36
- package/lib/activity-stats.mjs +1 -1
- package/lib/band.mjs +82 -55
- package/lib/config.mjs +49 -32
- package/lib/cost.mjs +21 -6
- package/lib/display.mjs +68 -4
- package/lib/panel.mjs +350 -64
- package/lib/route.mjs +8 -2
- package/lib/savings.mjs +237 -0
- package/lib/view.mjs +9 -1
- package/package.json +1 -1
- package/types/index.d.ts +32 -0
package/docs/evaluation.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Evaluation
|
|
2
2
|
|
|
3
|
-
The native Mod has no measured savings result. The pane reports Claude's own usage and configured-price scenarios.
|
|
3
|
+
The native Mod has no measured savings result. The pane reports Claude's own usage and configured-price scenarios. Its one counterfactual is [routing vs your model](#routing-vs-your-model), an estimate at configured list prices, not a bill or a measured saving.
|
|
4
4
|
|
|
5
5
|
This page separates an older gateway experiment from a shadow replay of native policy. Neither result measures answer quality or proves lower real spend. [Activity routing](#activity-routing) adds two checks of the activity label, with no savings result either.
|
|
6
6
|
|
|
@@ -54,9 +54,9 @@ The script writes aggregate counts, reason histograms, route transitions, and sh
|
|
|
54
54
|
|
|
55
55
|
## Activity routing
|
|
56
56
|
|
|
57
|
-
Activity routing has no measured result. The replay above predates it and covers tiers only. The pane counts turns, requests, switches, and the turns `on` would route differently, with a configured list-price estimate of those turns' next requests, not a measured saving. Two checks look at the classifier's activity label.
|
|
57
|
+
Activity routing has no measured result. The replay above predates it and covers tiers only. It is `on` by default since 1.7, with defaults chosen from Anthropic's published benchmarks and a list-price replay of one developer's sessions; [Activity routing](activity-routing.md#what-the-estimates-mean) gives that replay and its limits. The pane counts turns, requests, switches, and the turns `on` would route differently, with a configured list-price estimate of those turns' next requests, not a measured saving. Two checks look at the classifier's activity label.
|
|
58
58
|
|
|
59
|
-
The figures
|
|
59
|
+
The figures plan §11 tracks (tool agreement of at least 80% on `code` against `ops` and `explore`, a negative would-route estimate in `shadow`, the number of activity switches) are read from the Usage tab's **ACROSS SESSIONS** block, which shows the counts kept since the last reset: **Code/ops/explore** for the tool agreement on turns the classifier answered `code`, `ops` or `explore`, **Agreement** and **Mismatch** for all of them, **Shadow** for the would-route count and estimate, **Activity moves** for activity switches inside a tier. `/router` without a UI surface prints both agreements. The underlying counts are the `activity:stats:v1` store described in [Architecture](architecture.md).
|
|
60
60
|
|
|
61
61
|
### Tool agreement
|
|
62
62
|
|
|
@@ -96,16 +96,43 @@ node scripts/probe-activity.mjs [classifier]
|
|
|
96
96
|
|
|
97
97
|
The script sends each prompt to one classifier as the router would ask it, with activity routing forced to `shadow`. It reads credentials as `probe-classifier.mjs` does and needs a classifier you can reach. The run is billed on a paid classifier, and it is run by hand, not in CI. It writes accuracy, an expected-by-answered confusion matrix, p50 and p95 latency against the classifier's deadline, and error counts to `experiments/mod-router/results/activity-probe-<classifier>.json`. For Ollama the latency covers both requests. It never prints a key.
|
|
98
98
|
|
|
99
|
-
|
|
99
|
+
Five probe results are checked in, all run on 2026-10-10 with the synthetic set above: Jev against the live typesafe.ai API, OpenAI against the live Decisions API, Clef and Clef Flash against the live Cloudflare API, Ollama with `qwen3.5:9b` on an Apple M2 Pro laptop:
|
|
100
100
|
|
|
101
101
|
| Classifier | Correct | p50 latency | p95 latency | Result file |
|
|
102
102
|
| ---------- | -------: | ----------: | ----------: | ---------------------------------------------------------------------------------------------------- |
|
|
103
103
|
| Jev | 70 of 70 | 260 ms | 299 ms | [`activity-probe-jev.json`](../experiments/mod-router/results/activity-probe-jev.json) |
|
|
104
|
+
| OpenAI | 70 of 70 | 161 ms | 286 ms | [`activity-probe-openai.json`](../experiments/mod-router/results/activity-probe-openai.json) |
|
|
104
105
|
| Clef | 69 of 70 | 444 ms | 883 ms | [`activity-probe-clef.json`](../experiments/mod-router/results/activity-probe-clef.json) |
|
|
105
106
|
| Clef Flash | 69 of 70 | 470 ms | 874 ms | [`activity-probe-clef-flash.json`](../experiments/mod-router/results/activity-probe-clef-flash.json) |
|
|
106
107
|
| Ollama | 66 of 70 | 2986 ms | 3483 ms | [`activity-probe-ollama.json`](../experiments/mod-router/results/activity-probe-ollama.json) |
|
|
107
108
|
|
|
108
|
-
Ollama's latency covers both requests and stays inside its 5000 ms deadline; on slower hardware the activity step is skipped when less than 300 ms remain. They measure the label on synthetic prompts, not routing quality or savings.
|
|
109
|
+
Ollama's latency covers both requests and stays inside its 5000 ms deadline; on slower hardware the activity step is skipped when less than 300 ms remain. They measure the label on synthetic prompts, not routing quality or savings. The activity question costs little time: 30 alternating pairs of the same prompts, with and without it, gave Jev p50 259 ms both ways and p95 300 ms without, 306 ms with; OpenAI p50 163 ms and 162 ms, p95 296 ms and 349 ms. OpenAI's first request of a run took about 2.3 s of its 3000 ms deadline. The pane shows no probe accuracy. `policy.activityMass` was not tuned on any classifier; run the probe before you trust it with a new one.
|
|
110
|
+
|
|
111
|
+
## Routing vs your model
|
|
112
|
+
|
|
113
|
+
The Usage tab compares what routed replies cost with what the same tokens would cost on your model, the session's model and effort before routing. It answers "at list prices, did routing spend more or less than my own model for this work". It does not answer whether the answers were as good.
|
|
114
|
+
|
|
115
|
+
Method, per main reply that routing chose:
|
|
116
|
+
|
|
117
|
+
- **Routed** prices the usage Claude reported (uncached input, cache read, cache write, output) on the model that served it.
|
|
118
|
+
- **Yours** prices the same tokens on your model. While this reply and the one before it ran on your route, it is the reply's own usage, so a session on your model differs by exactly $0.00. Otherwise your model keeps one cache that never switched: it reads the previous prompt, up to this one less its uncached input, inside the cache lifetime, unless a compaction shrank the history or your model or effort changed since, and never less than the API actually read; it writes the rest. Output tokens are the same.
|
|
119
|
+
- **Parts**: the served model on your cache against yours is the model price, under cheaper models when negative and stronger than yours when positive; routed against the served model on your cache is the cache the switches cost, never negative. They sum to the difference. The pane rounds to cents and gives the remainder only to a part that is not zero: a surplus to the switch part, else the stronger part, else the cheaper part toward $0.00; a shortfall comes off the stronger part, down to $0.00, then the cheaper part. The shown parts add up, none changes sign, and none appears from rounding alone.
|
|
120
|
+
- **Prices**: `router.json` list prices through `ratesAt`, so Haiku 5.5 above 100,000 prompt tokens is priced at 5x. Claude Code reports no 5m/1h split to a Mod, so cache writes use the lifetime Claude Code 2.1.296 gives the main conversation by its own rule: one hour on a Claude plan unless an environment variable or the `promptCacheTtl` setting says otherwise, five minutes with an API key.
|
|
121
|
+
|
|
122
|
+
Checks:
|
|
123
|
+
|
|
124
|
+
- Unit tests (`test/savings.test.mjs`) cover a session that saves, one that costs more with Haiku as your model, equal routes at exactly 0, cache expiry at 5m and 1h, a compaction, a change of your model or effort, the 100K surcharge, an unpriced model, and a corrupted store. `test/hook-routing.test.mjs` covers two sessions finishing turns at the same moment.
|
|
125
|
+
- A one-off replay, not checked in, of this machine's main-conversation transcripts from 2026-10-01 to 2026-10-10 (nine sessions with 10 or more replies) gave $0.00 for every session that ran only on the model it was compared with: three on Opus 5.5, one on Haiku 5.5. Every main-conversation cache write in them was a one-hour write, which is what the lifetime rule gives on this Max plan.
|
|
126
|
+
- A live Claude Code 2.1.296 session on 2026-10-10, Opus 5.5 at `high` with turns pinned to Haiku 5.5, showed **Routed replies $0.48** beside **Cost $0.480 reported by Claude** for the same 16 replies; its last Haiku reply had a 114K-token prompt, which agrees only at the 5x rate. A Haiku 5.5 session with a pinned Opus turn showed $0.45 routed against $0.446 reported.
|
|
127
|
+
|
|
128
|
+
Limits:
|
|
129
|
+
|
|
130
|
+
- Output length is held the same. A stronger model may write less, or finish in fewer tool steps; a cheaper one may need more. The readout cannot see either.
|
|
131
|
+
- Answer quality is not measured. A saving bought with worse answers would read the same.
|
|
132
|
+
- Your model's cache is simulated, and a five-minute session that the lifetime rule takes for one hour (a plan subscriber billed as overage) would read too much cache on your side.
|
|
133
|
+
- A route that changes only the effort costs the same per token; it shows only its cache writes.
|
|
134
|
+
- Subagents, classifier charges and replies with routing off are not counted. On a Claude plan the dollars stand for quota, not cash.
|
|
135
|
+
- The saved column keeps one record per session, so sessions finishing turns at the same moment both count. Claude Code's store has no atomic update, which leaves these gaps: the same session open in two Claude Code processes at once can lose one's turn; a turn finishing in another process during **Reset stats** can be lost; a session's total from before a reset comes back if its first saved reply has the same millisecond as the reset, or if the system clock moved back across the reset; and the activity counts across sessions are still one shared record, where two sessions finishing turns at the same moment can lose one turn's counts. The router reads every session's record at session start and when the pane opens, so that read grows with the number of sessions since the last reset.
|
|
109
136
|
|
|
110
137
|
## Historical method and limits
|
|
111
138
|
|
package/docs/native-router.md
CHANGED
|
@@ -10,7 +10,7 @@ The classifier receives the current prompt and at most six preceding user or ass
|
|
|
10
10
|
|
|
11
11
|
The default tiers are defined in [Configuration](configuration.md#built-in-defaults). Policy uses vote hysteresis, repeated tool errors, context fit, model availability, and switching-cost estimates. The [architecture](architecture.md#request-flow) explains the event boundary and failure handling.
|
|
12
12
|
|
|
13
|
-
The activity is what the turn produces: `code`, `debug`, `explore`, `plan`, `review`, `ops`, or `docs`. A route is the tier's route with the activity's override on top. In `
|
|
13
|
+
The activity is what the turn produces: `code`, `debug`, `explore`, `plan`, `review`, `ops`, or `docs`. A route is the tier's own route, the base route, with the activity's override on top. In `on`, the default since 1.7, it applies the overrides. In `shadow` the router shows and records the activity and what `on` would route, and keeps the base route. The activity question reuses the same prompt and dialogue; no other text is sent. With `off` the classifier is asked for the tier only. [Route by activity](user-guide.md#route-by-activity) explains the modes, [Activity routing](activity-routing.md) the default matrix and its evidence, and [Configuration](configuration.md#activity-routing) the schema.
|
|
14
14
|
|
|
15
15
|
## Controls and session modes
|
|
16
16
|
|
|
@@ -29,7 +29,7 @@ Mode belongs to a Claude Code session. Clear starts a new session with routing o
|
|
|
29
29
|
|
|
30
30
|
## Router pane
|
|
31
31
|
|
|
32
|
-
The status band is one line above the prompt: a tier meter, the activity, the route, a short reason, classifier support, and context and cache use. Segments drop by priority when the band is narrow: classifier support first, then context and cache, then the activity, then the reason.
|
|
32
|
+
The status band is one line above the prompt: a tier meter, the activity, the route, a short reason, classifier support, and context and cache use. Segments drop by priority when the band is narrow: classifier support first, then context and cache, then the activity, then the reason. Hovering reveals pins, **Turn off**, and a two-row view; while routing is off, **Turn on** sits on the band itself, so the band carries one routing control at a time. A fresh session that starts with routing off because of its model shows `<model> is not a routing tier` on the band until the mode changes. The band yields to surveys and does not describe subagent transcripts. A model change between turns raises a toast. A pin, or a step that changes only the effort, such as `medium` to `high` on the defaults, raises none. While the classifier runs, the turn's spinner says `Choosing model`. In Manual mode or when routing is unavailable, the prompt footer carries `routing off` or `routing unavailable`. The **Router** button opens the pane. The pane has four tabs, Now, Routing, Classifier, and Usage, with the routing on/off pair at the top of every tab. The [user guide](user-guide.md#open-the-router-pane) describes each tab.
|
|
33
33
|
|
|
34
34
|
| Reading | Meaning and limits |
|
|
35
35
|
| ---------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
@@ -38,8 +38,9 @@ The status band is one line above the prompt: a tier meter, the activity, the ro
|
|
|
38
38
|
| Activity | The classifier's activity choice with its share and the two next-best answers. Empty with routing off, a pin, or no answer. |
|
|
39
39
|
| Route (activity) | With `on`: the route for the tier and activity, marked `(override)` with the base route beside it, or `(base)`. With `shadow`: what `on` would use, and the route in use (`shadow; same route` when they agree). |
|
|
40
40
|
| Replies | The tier that served each of the last 30 main-conversation replies; a dot where the router did not choose. A second row of letters names each reply's activity: `c` code, `d` debug, `e` explore, `p` plan, `r` review, `o` ops, `w` docs. |
|
|
41
|
+
| Routing vs your model (Usage) | Routed replies at configured list prices against the same tokens on your model (the session's model and effort), this session and since the last reset (each session against its own model); the difference split into cheaper models, stronger than yours, and cache writes from switches. `too early` below 10 replies. Output length is held the same; answer quality is not measured. |
|
|
41
42
|
| Activity stats (Usage) | Counts for this session: turns, requests and share per activity; switches by tier and by activity; tool agreement; in `shadow`, turns `on` would route differently with their summed next-request estimate at configured list prices. |
|
|
42
|
-
| Across sessions (Usage) | The counts kept since the last reset: labelled turns, tool agreement on the classifier's raw answer, overall and for `code`, `ops` and `explore`, the two largest mismatches,
|
|
43
|
+
| Across sessions (Usage) | The counts kept since the last reset: labelled turns, tool agreement on the classifier's raw answer, overall and for `code`, `ops` and `explore`, the two largest mismatches, activity moves inside a tier taken and refused, and the shadow readout. `/router` text shows the agreement. |
|
|
43
44
|
| Cost | Claude Code's native usage value. A plan's list-price estimates are not subscription cash charges. |
|
|
44
45
|
| Context bar | Maximum available observed and local estimated context, compared with the routed model's window. The fit rule reserves 20%. |
|
|
45
46
|
| Observed / estimated input | Claude's local context reading and the router's best current context estimate. `unknown` blocks a move to a smaller window. |
|
|
@@ -51,20 +52,21 @@ The status band is one line above the prompt: a tier meter, the activity, the ro
|
|
|
51
52
|
| Conservative payback | Conditional later-turn estimate based on configured cache prices, future reads, and the last output size. It is not measured savings. |
|
|
52
53
|
| Cache read benefit | Estimated price difference for observed cache reads before cache writes. It is not net savings. |
|
|
53
54
|
|
|
54
|
-
|
|
55
|
+
The router keeps no bill. Routing vs your model is a configured-price estimate, not a measured saving, and leaves out classifier charges. See [Evaluation](evaluation.md) for what the available trace can support.
|
|
55
56
|
|
|
56
57
|
## Routing and classifier settings
|
|
57
58
|
|
|
58
|
-
The Routing tab edits each tier's model alias and effort, the baseline tier, the activity overrides and mode, and
|
|
59
|
+
The Routing tab edits each tier's model alias and effort, the baseline tier, the activity overrides and mode, and four policy controls as one draft. The draft does not affect the active turn, survives a tab change or closing the pane, and is dropped at a new session. **Save** validates the whole file with the same loader the Mod starts with, writes `router.json` for future turns, and keeps unrelated keys. A route, activity override, or policy value equal to the built-in default is removed from the file, so later default changes still reach it. The Classifier tab writes the classifier choice and its deadline at once. **Undo** reverts the settings the last pane write changed, from any tab, until the next write or a new session.
|
|
59
60
|
|
|
60
|
-
| Control
|
|
61
|
-
|
|
|
62
|
-
| Deadline
|
|
63
|
-
| Votes to go down
|
|
64
|
-
| Payback horizon
|
|
65
|
-
| Credits cap
|
|
61
|
+
| Control | Values in the pane | Effect |
|
|
62
|
+
| ------------------ | ---------------------------------- | ---------------------------------------------------------------------------------------- |
|
|
63
|
+
| Deadline | 500, 1,000, 1,500, 3,000, 5,000 ms | The active classifier's total advice time, including any transient retry. Saved at once. |
|
|
64
|
+
| Votes to go down | 1, 2, 3 | Consecutive votes for a downgrade; one before a history's first measured reply. |
|
|
65
|
+
| Payback horizon | 1, 3, 5, 10 turns | Later turns included in downgrade economics. |
|
|
66
|
+
| Credits cap | $0.50, $1, $2, $5 | Largest estimated cold write on a `credits` model. |
|
|
67
|
+
| Activity threshold | 50%, 60%, 70%, 80% | `policy.activityMass`: the least probability at which an activity applies. |
|
|
66
68
|
|
|
67
|
-
Under the routes, **ACTIVITIES**
|
|
69
|
+
Under the routes, **ACTIVITIES** starts with the **Activity routing** selector, `off · shadow · on`, and a hint for the mode. Below it is the effective matrix of the draft: one row per distinct set of cells, `·` where a cell uses the base route, routes abbreviated such as `S·high` for Sonnet · high, and the count of distinct routes, each counted as its own cache. Until the mode is `on` the count carries `once activity routing is on`. **OVERRIDES** reads `in use`, or in yellow `not in use:` with the reason: activity routing is `shadow` or `off`, routing is off, or routing is unavailable. Each override is a row with a model, an effort, and **remove**, and a selector adds one for a free activity and tier. A removed built-in override is saved as the tier's own route, because a file that only omitted it would get the built-in back. Yellow notes flag an override equal to its base route, one stronger than the tier above, and the only cell or tier on its (model, effort) pair, which adds a cache. **Reset routes to defaults** resets the routes only; pending override and mode edits stay in the draft. The Usage tab's **Reset stats** clears the activity counts and routing vs your model, for this session and across sessions.
|
|
68
70
|
|
|
69
71
|
The classifier section lists every configured classifier as a row with its service host and whether its key and endpoint settings are complete. Selecting a row writes `classifier` to `router.json` at once, or removes it for the default, through the same validation, and resets the new classifier's failure count. A turn already being classified finishes with its own classifier; its readings stay off the pane. **Undo** returns to the previous classifier. The deadline saves at once too, and a built-in classifier's default deadline is written as no override. **Sends** names the host that receives prompt text.
|
|
70
72
|
|
|
@@ -73,10 +75,11 @@ The pane refuses to write through a symlink. A failed validation names the setti
|
|
|
73
75
|
## Safety and failure states
|
|
74
76
|
|
|
75
77
|
- A missing key or account ID, a classifier failure, or a policy refusal keeps the current model. Network refusal is never bypassed with a helper process.
|
|
76
|
-
- A missing, malformed, or timed-out activity answer keeps the running activity in `on`; the tier answer still applies. In `shadow` the
|
|
78
|
+
- A missing, malformed, or timed-out activity answer keeps the running activity in `on`; the tier answer still applies. In `shadow` the base route runs as always. It does not count as a classifier failure. If the whole classifier call fails, the running route stays. Activity statistics are written inside a guard: a failed store read or write loses that turn's counts and never fails a turn.
|
|
77
79
|
- Three launched classifier failures open a 60-second pause for that classifier. One in-flight request is allowed per classifier in each active Mod instance. Pending host HTTP work blocks another request until it settles.
|
|
78
80
|
- A `router.json` with v0.8 gateway keys or the 1.1 `jev` section marks the router unavailable until the [migration command](configuration.md#convert-an-older-routerjson) converts it.
|
|
79
81
|
- Unsupported Claude Code versions and leftover v0.8 gateway settings (the `jev-router` model or the `127.0.0.1:43170` base URL) mark the router unavailable. `/router` lists the settings to remove. A local gateway does not run as part of this Mod.
|
|
82
|
+
- While the router is unavailable, the pane header reads `ROUTING unavailable Claude’s model is kept` with the reason, and offers no on/off pair or pins. `/router` without a surface starts with `Routing unavailable: <reason>. Claude’s model is kept.`, and `/router auto`, `off`, `pin`, and `activities` reply the same and change nothing.
|
|
80
83
|
- A context-window error makes that model ineligible until the next history reset. The Mod does not retry an Anthropic request after a stream begins.
|
|
81
84
|
- Unknown context retains the current model. There is no characters-to-tokens fallback.
|
|
82
85
|
- Unknown model substitutions receive no cache credit for the requested model.
|
package/docs/router-band.svg
CHANGED
|
@@ -14,20 +14,19 @@
|
|
|
14
14
|
<text x="47.4" y="56" fill="#e0708a" xml:space="preserve">█</text>
|
|
15
15
|
<rect x="55.2" y="42" width="46.8" height="18" rx="4" fill="#e0708a"/>
|
|
16
16
|
<text x="55.2" y="56" fill="#0d1016" font-weight="700" xml:space="preserve"> high </text>
|
|
17
|
-
<text x="102.0" y="56" fill="#
|
|
18
|
-
<text x="
|
|
19
|
-
<text x="
|
|
20
|
-
<
|
|
21
|
-
<text x="
|
|
17
|
+
<text x="102.0" y="56" fill="#d0d0d0" xml:space="preserve">code → </text>
|
|
18
|
+
<text x="156.6" y="56" fill="#d0d0d0" xml:space="preserve">Opus 5.5 · xhigh</text>
|
|
19
|
+
<text x="281.4" y="56" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
20
|
+
<text x="320.4" y="56" fill="#7c7c7c" xml:space="preserve">↑ jump</text>
|
|
21
|
+
<text x="367.2" y="56" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
22
|
+
<text x="406.2" y="56" fill="#7c7c7c" xml:space="preserve">Jev 88% ≥ 82%</text>
|
|
22
23
|
<text x="507.6" y="56" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
23
|
-
<text x="546.6" y="56" fill="#
|
|
24
|
-
<text x="
|
|
25
|
-
<text x="
|
|
26
|
-
<text x="
|
|
27
|
-
<text x="
|
|
28
|
-
<text
|
|
29
|
-
<text x="804.0" y="56" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
30
|
-
<text class="cap" x="20" y="95">Two rows, with the hover row shown: recent replies by tier, pins, Routing off</text>
|
|
24
|
+
<text x="546.6" y="56" fill="#d0d0d0" xml:space="preserve">ctx </text>
|
|
25
|
+
<text x="577.8" y="56" fill="#87d787" xml:space="preserve">40%</text>
|
|
26
|
+
<text x="601.2" y="56" fill="#d0d0d0" xml:space="preserve"> · cache </text>
|
|
27
|
+
<text x="671.4" y="56" fill="#87d787" xml:space="preserve">100%</text>
|
|
28
|
+
<text x="718.2" y="56" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
29
|
+
<text class="cap" x="20" y="95">Two rows, with the hover row shown: recent replies by tier, the session against your model, pins, Turn off</text>
|
|
31
30
|
<rect x="12" y="103" width="897.6" height="67" rx="5" fill="#232323"/>
|
|
32
31
|
<text x="24.0" y="121" fill="#e0708a" xml:space="preserve">▂</text>
|
|
33
32
|
<text x="31.8" y="121" fill="#e0708a" xml:space="preserve">▄</text>
|
|
@@ -35,19 +34,16 @@
|
|
|
35
34
|
<text x="47.4" y="121" fill="#e0708a" xml:space="preserve">█</text>
|
|
36
35
|
<rect x="55.2" y="107" width="46.8" height="18" rx="4" fill="#e0708a"/>
|
|
37
36
|
<text x="55.2" y="121" fill="#0d1016" font-weight="700" xml:space="preserve"> high </text>
|
|
38
|
-
<text x="102.0" y="121" fill="#
|
|
39
|
-
<text x="
|
|
40
|
-
<text x="
|
|
41
|
-
<
|
|
42
|
-
<text x="
|
|
43
|
-
<text x="
|
|
44
|
-
<text x="
|
|
45
|
-
<text x="
|
|
46
|
-
<text x="
|
|
47
|
-
<text x="
|
|
48
|
-
<text x="687.0" y="121" fill="#d0d0d0" xml:space="preserve"> · cache </text>
|
|
49
|
-
<text x="757.2" y="121" fill="#87d787" xml:space="preserve">100%</text>
|
|
50
|
-
<text x="804.0" y="121" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
37
|
+
<text x="102.0" y="121" fill="#d0d0d0" xml:space="preserve">code → </text>
|
|
38
|
+
<text x="156.6" y="121" fill="#d0d0d0" xml:space="preserve">Opus 5.5 · xhigh</text>
|
|
39
|
+
<text x="281.4" y="121" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
40
|
+
<text x="320.4" y="121" fill="#7c7c7c" xml:space="preserve">↑ jump</text>
|
|
41
|
+
<text x="367.2" y="121" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
42
|
+
<text x="406.2" y="121" fill="#d0d0d0" xml:space="preserve">ctx </text>
|
|
43
|
+
<text x="437.4" y="121" fill="#87d787" xml:space="preserve">40%</text>
|
|
44
|
+
<text x="460.8" y="121" fill="#d0d0d0" xml:space="preserve"> · cache </text>
|
|
45
|
+
<text x="531.0" y="121" fill="#87d787" xml:space="preserve">100%</text>
|
|
46
|
+
<text x="577.8" y="121" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
51
47
|
<text x="24.0" y="140" fill="#7c7c7c" xml:space="preserve">replies </text>
|
|
52
48
|
<text x="86.4" y="140" fill="#5f9fe0" xml:space="preserve">█</text>
|
|
53
49
|
<text x="94.2" y="140" fill="#5f9fe0" xml:space="preserve">█</text>
|
|
@@ -69,7 +65,11 @@
|
|
|
69
65
|
<text x="219.0" y="140" fill="#e0708a" xml:space="preserve">█</text>
|
|
70
66
|
<text x="226.8" y="140" fill="#e0708a" xml:space="preserve">█</text>
|
|
71
67
|
<text x="234.6" y="140" fill="#e0708a" xml:space="preserve">█</text>
|
|
72
|
-
<text x="242.4" y="140" fill="#7c7c7c" xml:space="preserve">
|
|
68
|
+
<text x="242.4" y="140" fill="#7c7c7c" xml:space="preserve"> 0 switches · cache saved ≈ $1.52</text>
|
|
69
|
+
<text x="507.6" y="140" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
70
|
+
<text x="546.6" y="140" fill="#d0d0d0" xml:space="preserve">vs your model </text>
|
|
71
|
+
<text x="655.8" y="140" fill="#6fcf97" xml:space="preserve">−22%</text>
|
|
72
|
+
<text x="687.0" y="140" fill="#7c7c7c" xml:space="preserve"> (−$1.84, list prices)</text>
|
|
73
73
|
<text x="24.0" y="159" fill="#7c7c7c" xml:space="preserve">pin next turn </text>
|
|
74
74
|
<rect x="133.2" y="145" width="70.2" height="18" rx="4" fill="#2e3340"/>
|
|
75
75
|
<text x="133.2" y="159" fill="#d0d0d0" xml:space="preserve">[ micro ]</text>
|
|
@@ -79,10 +79,11 @@
|
|
|
79
79
|
<text x="273.6" y="159" fill="#d0d0d0" xml:space="preserve">[ medium ]</text>
|
|
80
80
|
<rect x="359.4" y="145" width="62.4" height="18" rx="4" fill="#2e3340"/>
|
|
81
81
|
<text x="359.4" y="159" fill="#d0d0d0" xml:space="preserve">[ high ]</text>
|
|
82
|
-
<
|
|
83
|
-
<
|
|
84
|
-
<
|
|
85
|
-
<
|
|
82
|
+
<text x="437.4" y="159" fill="#7c7c7c" xml:space="preserve">routing on </text>
|
|
83
|
+
<rect x="523.2" y="145" width="93.6" height="18" rx="4" fill="#2e3340"/>
|
|
84
|
+
<text x="523.2" y="159" fill="#d0d0d0" xml:space="preserve">[ Turn off ]</text>
|
|
85
|
+
<rect x="632.4" y="145" width="70.2" height="18" rx="4" fill="#2e3340"/>
|
|
86
|
+
<text x="632.4" y="159" fill="#d0d0d0" xml:space="preserve">[ 1 row ]</text>
|
|
86
87
|
<text class="cap" x="20" y="198">A pin waits for the next turn; ✕ cancels it</text>
|
|
87
88
|
<rect x="12" y="206" width="897.6" height="29" rx="5" fill="#232323"/>
|
|
88
89
|
<text x="24.0" y="224" fill="#5f9fe0" xml:space="preserve">▂</text>
|
|
@@ -91,18 +92,20 @@
|
|
|
91
92
|
<text x="47.4" y="224" fill="#7c7c7c" xml:space="preserve">█</text>
|
|
92
93
|
<rect x="55.2" y="210" width="39.0" height="18" rx="4" fill="#5f9fe0"/>
|
|
93
94
|
<text x="55.2" y="224" fill="#0d1016" font-weight="700" xml:space="preserve"> low </text>
|
|
94
|
-
<text x="94.2" y="224" fill="#
|
|
95
|
-
<text x="
|
|
96
|
-
<text x="
|
|
97
|
-
<
|
|
98
|
-
<text x="
|
|
99
|
-
<text x="
|
|
100
|
-
<text x="
|
|
101
|
-
<text x="
|
|
102
|
-
<text x="
|
|
103
|
-
<text x="
|
|
104
|
-
<text x="
|
|
105
|
-
<text x="
|
|
95
|
+
<text x="94.2" y="224" fill="#d0d0d0" xml:space="preserve">ops → </text>
|
|
96
|
+
<text x="141.0" y="224" fill="#d0d0d0" xml:space="preserve">Haiku 5.5 · high</text>
|
|
97
|
+
<text x="265.8" y="224" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
98
|
+
<text x="304.8" y="224" fill="#7c9cff" xml:space="preserve">⏵ next turn: </text>
|
|
99
|
+
<text x="406.2" y="224" fill="#d7af5f" font-weight="700" xml:space="preserve">medium</text>
|
|
100
|
+
<text x="460.8" y="224" fill="#d0d0d0" xml:space="preserve">✕</text>
|
|
101
|
+
<text x="468.6" y="224" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
102
|
+
<text x="507.6" y="224" fill="#7c7c7c" xml:space="preserve">= fits</text>
|
|
103
|
+
<text x="554.4" y="224" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
104
|
+
<text x="593.4" y="224" fill="#d0d0d0" xml:space="preserve">ctx </text>
|
|
105
|
+
<text x="624.6" y="224" fill="#87d787" xml:space="preserve">40%</text>
|
|
106
|
+
<text x="648.0" y="224" fill="#d0d0d0" xml:space="preserve"> · cache </text>
|
|
107
|
+
<text x="718.2" y="224" fill="#87d787" xml:space="preserve">100%</text>
|
|
108
|
+
<text x="765.0" y="224" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
106
109
|
<text class="cap" x="20" y="263">No classifier key: routing keeps the model and offers Set up</text>
|
|
107
110
|
<rect x="12" y="271" width="897.6" height="29" rx="5" fill="#232323"/>
|
|
108
111
|
<text x="24.0" y="289" fill="#f0b429" xml:space="preserve">⚠ Jev: no API key</text>
|
|
@@ -120,40 +123,38 @@
|
|
|
120
123
|
<text x="507.6" y="289" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
121
124
|
<text x="546.6" y="289" fill="#f0b429" xml:space="preserve">keeping model</text>
|
|
122
125
|
<text x="663.6" y="289" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
123
|
-
<text class="cap" x="20" y="328">Routing off: /model chose the model;
|
|
126
|
+
<text class="cap" x="20" y="328">Routing off: /model chose the model; Turn on resumes routing</text>
|
|
124
127
|
<rect x="12" y="336" width="897.6" height="29" rx="5" fill="#232323"/>
|
|
125
128
|
<text x="24.0" y="354" fill="#7c7c7c" xml:space="preserve">○ </text>
|
|
126
129
|
<text x="39.6" y="354" fill="#d0d0d0" xml:space="preserve">Routing </text>
|
|
127
130
|
<rect x="102.0" y="340" width="23.4" height="18" rx="4" fill="#2a3040"/>
|
|
128
131
|
<text x="102.0" y="354" fill="#8b93a7" xml:space="preserve">off</text>
|
|
129
|
-
<
|
|
130
|
-
<text x="
|
|
131
|
-
<text x="
|
|
132
|
-
<
|
|
133
|
-
<text x="
|
|
134
|
-
<text x="
|
|
135
|
-
<text
|
|
132
|
+
<rect x="133.2" y="340" width="85.8" height="18" rx="4" fill="#87afff"/>
|
|
133
|
+
<text x="133.2" y="354" fill="#0d1016" font-weight="700" xml:space="preserve">[ Turn on ]</text>
|
|
134
|
+
<text x="219.0" y="354" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
135
|
+
<text x="258.0" y="354" fill="#d0d0d0" xml:space="preserve">every turn uses </text>
|
|
136
|
+
<text x="382.8" y="354" fill="#d0d0d0" xml:space="preserve">Sonnet 5.5</text>
|
|
137
|
+
<text x="460.8" y="354" fill="#7c7c7c" xml:space="preserve"> (/model)</text>
|
|
138
|
+
<text x="546.6" y="354" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
139
|
+
<text class="cap" x="20" y="393">Activity routing on: an ops turn at medium moves from Opus to Haiku</text>
|
|
136
140
|
<rect x="12" y="401" width="897.6" height="29" rx="5" fill="#232323"/>
|
|
137
|
-
<text x="24.0" y="419" fill="#
|
|
138
|
-
<text x="31.8" y="419" fill="#
|
|
139
|
-
<text x="39.6" y="419" fill="#
|
|
141
|
+
<text x="24.0" y="419" fill="#d7af5f" xml:space="preserve">▂</text>
|
|
142
|
+
<text x="31.8" y="419" fill="#d7af5f" xml:space="preserve">▄</text>
|
|
143
|
+
<text x="39.6" y="419" fill="#d7af5f" xml:space="preserve">▆</text>
|
|
140
144
|
<text x="47.4" y="419" fill="#7c7c7c" xml:space="preserve">█</text>
|
|
141
|
-
<rect x="55.2" y="405" width="
|
|
142
|
-
<text x="55.2" y="419" fill="#0d1016" font-weight="700" xml:space="preserve">
|
|
143
|
-
<text x="
|
|
144
|
-
<text x="
|
|
145
|
-
<text x="
|
|
146
|
-
<
|
|
147
|
-
<text x="
|
|
148
|
-
<text x="
|
|
149
|
-
<text x="
|
|
150
|
-
<text x="
|
|
151
|
-
<text x="
|
|
152
|
-
<text x="
|
|
153
|
-
<text
|
|
154
|
-
<text x="663.6" y="419" fill="#87d787" xml:space="preserve">100%</text>
|
|
155
|
-
<text x="710.4" y="419" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
156
|
-
<text class="cap" x="20" y="458">Activity routing in shadow: the label is shown, the tier route still runs</text>
|
|
145
|
+
<rect x="55.2" y="405" width="62.4" height="18" rx="4" fill="#d7af5f"/>
|
|
146
|
+
<text x="55.2" y="419" fill="#0d1016" font-weight="700" xml:space="preserve"> medium </text>
|
|
147
|
+
<text x="117.6" y="419" fill="#d0d0d0" xml:space="preserve">ops → </text>
|
|
148
|
+
<text x="164.4" y="419" fill="#d0d0d0" xml:space="preserve">Haiku 5.5 · high</text>
|
|
149
|
+
<text x="289.2" y="419" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
150
|
+
<text x="328.2" y="419" fill="#7c7c7c" xml:space="preserve">↘ ops</text>
|
|
151
|
+
<text x="367.2" y="419" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
152
|
+
<text x="406.2" y="419" fill="#d0d0d0" xml:space="preserve">ctx </text>
|
|
153
|
+
<text x="437.4" y="419" fill="#87d787" xml:space="preserve">40%</text>
|
|
154
|
+
<text x="460.8" y="419" fill="#d0d0d0" xml:space="preserve"> · cache </text>
|
|
155
|
+
<text x="531.0" y="419" fill="#87d787" xml:space="preserve">100%</text>
|
|
156
|
+
<text x="577.8" y="419" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
157
|
+
<text class="cap" x="20" y="458">Activity routing in shadow: the label is shown, the base route still runs</text>
|
|
157
158
|
<rect x="12" y="466" width="897.6" height="29" rx="5" fill="#232323"/>
|
|
158
159
|
<text x="24.0" y="484" fill="#5f9fe0" xml:space="preserve">▂</text>
|
|
159
160
|
<text x="31.8" y="484" fill="#5f9fe0" xml:space="preserve">▄</text>
|
|
@@ -164,14 +165,11 @@
|
|
|
164
165
|
<text x="94.2" y="484" fill="#7c7c7c" xml:space="preserve">code (shadow) → </text>
|
|
165
166
|
<text x="219.0" y="484" fill="#d0d0d0" xml:space="preserve">Haiku 5.5 · high</text>
|
|
166
167
|
<text x="343.8" y="484" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
167
|
-
<
|
|
168
|
-
<text x="
|
|
169
|
-
<text x="
|
|
170
|
-
<text x="
|
|
171
|
-
<text x="
|
|
172
|
-
<text x="
|
|
173
|
-
<text x="
|
|
174
|
-
<text x="679.2" y="484" fill="#d0d0d0" xml:space="preserve"> · cache </text>
|
|
175
|
-
<text x="749.4" y="484" fill="#87d787" xml:space="preserve">100%</text>
|
|
176
|
-
<text x="796.2" y="484" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
168
|
+
<text x="382.8" y="484" fill="#7c7c7c" xml:space="preserve">= fits</text>
|
|
169
|
+
<text x="429.6" y="484" fill="#7c7c7c" xml:space="preserve"> · </text>
|
|
170
|
+
<text x="468.6" y="484" fill="#d0d0d0" xml:space="preserve">ctx </text>
|
|
171
|
+
<text x="499.8" y="484" fill="#87d787" xml:space="preserve">40%</text>
|
|
172
|
+
<text x="523.2" y="484" fill="#d0d0d0" xml:space="preserve"> · cache </text>
|
|
173
|
+
<text x="593.4" y="484" fill="#87d787" xml:space="preserve">100%</text>
|
|
174
|
+
<text x="640.2" y="484" fill="#d0d0d0" xml:space="preserve">Router</text>
|
|
177
175
|
</svg>
|
|
@@ -7,13 +7,13 @@
|
|
|
7
7
|
</style>
|
|
8
8
|
<rect width="899" height="401" rx="8" fill="#1c1c1c"/>
|
|
9
9
|
<rect x="10" y="10" width="879" height="381" rx="6" fill="none" stroke="#3f5f8f"/>
|
|
10
|
-
<text x="24.0" y="34" fill="#5fafd7" font-weight="700" xml:space="preserve">ROUTING
|
|
11
|
-
<
|
|
12
|
-
<
|
|
13
|
-
<
|
|
14
|
-
<
|
|
15
|
-
<text x="
|
|
16
|
-
<text x="
|
|
10
|
+
<text x="24.0" y="34" fill="#5fafd7" font-weight="700" xml:space="preserve">ROUTING</text>
|
|
11
|
+
<rect x="94.2" y="20" width="62.4" height="18" rx="4" fill="#87afff"/>
|
|
12
|
+
<text x="94.2" y="34" fill="#0d1016" font-weight="700" xml:space="preserve">[ ◉ on ]</text>
|
|
13
|
+
<rect x="164.4" y="20" width="70.2" height="18" rx="4" fill="#2e3340"/>
|
|
14
|
+
<text x="164.4" y="34" fill="#d0d0d0" xml:space="preserve">[ ○ off ]</text>
|
|
15
|
+
<text x="234.6" y="34" fill="#7c7c7c" xml:space="preserve"> off keeps the /model choice</text>
|
|
16
|
+
<text x="24.0" y="53" fill="#87d787" xml:space="preserve">Clef Flash ready</text>
|
|
17
17
|
<rect x="24.0" y="58" width="54.6" height="18" rx="4" fill="#2e3340"/>
|
|
18
18
|
<text x="24.0" y="72" fill="#d0d0d0" xml:space="preserve">[ Now ]</text>
|
|
19
19
|
<rect x="86.4" y="58" width="85.8" height="18" rx="4" fill="#2e3340"/>
|
package/docs/router-pane-now.svg
CHANGED
|
@@ -7,13 +7,13 @@
|
|
|
7
7
|
</style>
|
|
8
8
|
<rect width="594" height="572" rx="8" fill="#1c1c1c"/>
|
|
9
9
|
<rect x="10" y="10" width="574" height="552" rx="6" fill="none" stroke="#3f5f8f"/>
|
|
10
|
-
<text x="24.0" y="34" fill="#5fafd7" font-weight="700" xml:space="preserve">ROUTING
|
|
11
|
-
<
|
|
12
|
-
<
|
|
13
|
-
<
|
|
14
|
-
<
|
|
15
|
-
<text x="
|
|
16
|
-
<text x="
|
|
10
|
+
<text x="24.0" y="34" fill="#5fafd7" font-weight="700" xml:space="preserve">ROUTING</text>
|
|
11
|
+
<rect x="94.2" y="20" width="62.4" height="18" rx="4" fill="#87afff"/>
|
|
12
|
+
<text x="94.2" y="34" fill="#0d1016" font-weight="700" xml:space="preserve">[ ◉ on ]</text>
|
|
13
|
+
<rect x="164.4" y="20" width="70.2" height="18" rx="4" fill="#2e3340"/>
|
|
14
|
+
<text x="164.4" y="34" fill="#d0d0d0" xml:space="preserve">[ ○ off ]</text>
|
|
15
|
+
<text x="234.6" y="34" fill="#7c7c7c" xml:space="preserve"> off keeps the /model choice</text>
|
|
16
|
+
<text x="24.0" y="53" fill="#87d787" xml:space="preserve">Jev ready · 347 ms</text>
|
|
17
17
|
<rect x="24.0" y="58" width="54.6" height="18" rx="4" fill="#87afff"/>
|
|
18
18
|
<text x="24.0" y="72" fill="#0d1016" font-weight="700" xml:space="preserve">[ Now ]</text>
|
|
19
19
|
<rect x="86.4" y="58" width="85.8" height="18" rx="4" fill="#2e3340"/>
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
<text x="24.0" y="148" fill="#d0d0d0" xml:space="preserve">Why </text>
|
|
34
34
|
<text x="102.0" y="148" fill="#d0d0d0" xml:space="preserve">clear need for a stronger model</text>
|
|
35
35
|
<text x="24.0" y="167" fill="#d0d0d0" xml:space="preserve">Route </text>
|
|
36
|
-
<text x="102.0" y="167" fill="#d0d0d0" xml:space="preserve">high + code
|
|
36
|
+
<text x="102.0" y="167" fill="#d0d0d0" xml:space="preserve">high + code → Opus 5.5 · xhigh (base)</text>
|
|
37
37
|
<text x="24.0" y="205" fill="#5fafd7" font-weight="700" xml:space="preserve">TIERS · next turn</text>
|
|
38
38
|
<text x="24.0" y="224" fill="#7c7c7c" xml:space="preserve"> tier route Jev support</text>
|
|
39
39
|
<text x="24.0" y="243" fill="#e0708a" font-weight="700" xml:space="preserve">▶ </text>
|
|
@@ -84,7 +84,7 @@
|
|
|
84
84
|
<text x="172.2" y="395" fill="#e0708a" font-weight="700" xml:space="preserve">█</text>
|
|
85
85
|
<text x="180.0" y="395" fill="#e0708a" font-weight="700" xml:space="preserve">█</text>
|
|
86
86
|
<text x="187.8" y="395" fill="#e0708a" font-weight="700" xml:space="preserve">█</text>
|
|
87
|
-
<text x="195.6" y="395" fill="#7c7c7c" xml:space="preserve">
|
|
87
|
+
<text x="195.6" y="395" fill="#7c7c7c" xml:space="preserve"> 0 switches</text>
|
|
88
88
|
<text x="39.6" y="414" fill="#d0d0d0" xml:space="preserve">e</text>
|
|
89
89
|
<text x="47.4" y="414" fill="#d0d0d0" xml:space="preserve">e</text>
|
|
90
90
|
<text x="55.2" y="414" fill="#d0d0d0" xml:space="preserve">c</text>
|