@bytesbrains/cruise-worker 0.14.1 → 0.15.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.
@@ -0,0 +1,118 @@
1
+ -- Mistral's retirements, first half: codestral leaves its lane, Large 4 arrives (#7).
2
+ --
3
+ -- Mistral's deprecation notice (received 2026-11-30 UTC) retires three models
4
+ -- this catalogue holds. Re-read on 2026-12-01 UTC against the "Deprecated &
5
+ -- retired models" table at https://docs.mistral.ai/getting-started/models/:
6
+ --
7
+ -- codestral-2508 deprecated 2026-11-30, retires 2026-12-31, no alternative
8
+ -- mistral-large-2512 deprecated 2026-10-31, retires 2027-04-30
9
+ -- mistral-medium-2604 deprecated 2026-10-31, retires 2027-04-30 (listed as
10
+ -- Medium 3.5, `mistral-medium-3-5`, the alias 0025 pinned)
11
+ --
12
+ -- The table's alternative column for the last two renders a Mistral Large 4
13
+ -- link, and the notice names Large 4 as the replacement for both.
14
+ --
15
+ -- ## codestral-2508 leaves `bb/code-completion`, now
16
+ --
17
+ -- It is the one with a date this month and the only one still in a lane by
18
+ -- its own seat: rank 1 of `bb/code-completion` (0029, 0070). 0089 already took
19
+ -- it out of `bb/agentic-coding` and `bb/builder`. Mistral offers no
20
+ -- replacement — it is ending code completion — so the seat is not refilled.
21
+ -- The lane keeps three members, 0029's floor: `deepseek/deepseek-flash`
22
+ -- (quality rank 2) and the two Workers AI Qwen coders (rank 3). Selection is
23
+ -- `cheap`, so whichever of them is cheapest and passes the gates serves.
24
+ --
25
+ -- One DELETE, which matches the row whatever position the control plane may
26
+ -- have moved it to (`src/lanes-write.ts`), and nothing where it is absent.
27
+ --
28
+ -- DeepSeek Flash moves from rank 2 to rank 1, because a lane whose best tier
29
+ -- is 2 reads as 0070's first-tier UPDATE having matched nothing
30
+ -- (`test/lane-quality-ranks.test.ts`). The order is unchanged: rank is
31
+ -- ordinal within a lane, Flash was already above the Qwen coders, and the
32
+ -- lane is `cheap`, so `graduated`'s reading of ranks does not touch it.
33
+ --
34
+ -- The model stays **enabled** until it retires. Taking it out of the lane is
35
+ -- what the lane needs; disabling it is what a caller who names
36
+ -- `mistral/codestral-2508` directly needs, and that caller is owed the month
37
+ -- Mistral gave them. If the disable is late, nothing serves wrong: from
38
+ -- 2027-01-01 every request fails upstream and falls through its chain, and the
39
+ -- next conformance run in which no check passes clears `measured_at`
40
+ -- (`src/conformance-verdict.ts`), so the gate refuses it as unmeasured. The
41
+ -- disable lands with the two April models, in the second half of #7.
42
+ --
43
+ -- ## mistral-large-2512 is in no lane already
44
+ --
45
+ -- #7 places it in `bb/code-review` and `bb/hunter`. Applied in order, the
46
+ -- migrations say otherwise: 0075 rebuilt `bb/hunter` without it, and 0084
47
+ -- rebuilt `bb/code-review` (with 0088 after it) without it either. It is a catalogue row and nothing else, so its
48
+ -- only work is the April disable.
49
+ --
50
+ -- ## mistral/mistral-large-4-0 is catalogued, unmeasured, in no lane
51
+ --
52
+ -- From the model card https://docs.mistral.ai/models/mistral-large-4-0 (read
53
+ -- 2026-12-01 UTC): Mistral Large 4, version v26.10, an open-weight hybrid
54
+ -- instruct-and-reasoning MoE, API ids `mistral-large-4-0` and `mistral-large`.
55
+ -- The id is the versioned one and so is the catalogue id, for 0025's rule:
56
+ -- `mistral-large` is the moving name, and an alias that moves is a rate change
57
+ -- with no signal (0020, 0041). #7 wrote `mistral/mistral-large-4`; no page
58
+ -- lists that id.
59
+ --
60
+ -- **`max_context` is 1,000,000, the smaller reading of the card's "1M".** The
61
+ -- card prints no exact figure and `GET /v1/models/mistral-large-4-0` has not
62
+ -- been read for this account. 0025's rule for a card-versus-API disagreement
63
+ -- is to take the smaller, because refusing a request the host would have taken
64
+ -- is visible and correctable and passing one it would not is neither;
65
+ -- 1,000,000 against 1,048,576 is the same choice before the API has spoken.
66
+ -- Correct it in place when the API is read. `max_output` stays NULL: no page
67
+ -- states one, and 0011 says never write a number you did not fetch.
68
+ --
69
+ -- `data_retention` is NULL, like every Mistral row: the terms depend on the
70
+ -- account (`ACCOUNT_DEPENDENT` in `test/catalogue-retention.test.ts`).
71
+ --
72
+ -- Price, from https://docs.mistral.ai/inference/pricing (standard column) and
73
+ -- the card, which agree: $0.70 in, $0.07 cached, $2.10 out per MTok, so
74
+ -- 700000 / 70000 / 2100000 micros. No batch row: Mistral's 50% batch discount
75
+ -- is a general statement on its pricing page, not a figure for this model,
76
+ -- and Cruise's Batch API reaches OpenAI only (`docs/batches.md`).
77
+ --
78
+ -- **Why it joins no lane in this file.** It lands unmeasured, and a lane's
79
+ -- capabilities are the intersection of its members, `null` when any member is
80
+ -- unmeasured (`src/lanes.ts`). Seating it now would turn `tools`, `streaming`
81
+ -- and the rest to `null` on every lane it joined, which is the catalogue
82
+ -- promising less than the gate would serve and, for a client that filters on
83
+ -- `tools`, a lane that vanishes. 0120's shape: catalogue, measure, then seat.
84
+ --
85
+ -- ## What the second half does, once conformance has measured Large 4
86
+ --
87
+ -- Moves the `mistral-medium-2604` seats — `bb/agentic-coding`, `bb/builder`,
88
+ -- `bb/code-review`, `bb/hunter` (rank 3, position 9), `bb/translation`
89
+ -- (rank 1) and `bb/deep-reasoning` (rank 3, which #7 does not list) — to
90
+ -- Large 4 with 0089's UPDATE OR IGNORE then DELETE, and disables all three
91
+ -- retiring models. Large 4 is cheaper than Medium 3.5 on both sides
92
+ -- ($0.70/$2.10 against $1.50/$7.50), so under `cheap` it will win more of
93
+ -- those lanes' traffic than Medium did; the ranks are re-read then, against
94
+ -- what the measurement says, not guessed here.
95
+ --
96
+ -- The dates are UTC. `effective_from` is the read date, not a launch date the
97
+ -- pages do not print: 0020 and 0021, a row dated in the future prices in the
98
+ -- future and every request reads as unpriced until then.
99
+
100
+ DELETE FROM lane_members
101
+ WHERE lane_id = 'bb/code-completion'
102
+ AND model_id = 'mistral/codestral-2508';
103
+
104
+ UPDATE lane_members
105
+ SET quality_rank = 1
106
+ WHERE lane_id = 'bb/code-completion'
107
+ AND model_id = 'deepseek/deepseek-flash';
108
+
109
+ INSERT INTO models (id, upstream_id, upstream_model, max_context, max_output) VALUES
110
+ ('mistral/mistral-large-4-0', 'mistral', 'mistral-large-4-0', 1000000, NULL);
111
+
112
+ INSERT INTO price_observations
113
+ (observed_at, model, effective_from, prompt_tokens_from, peak_utc,
114
+ input_micros_per_mtok, output_micros_per_mtok, cached_input_micros_per_mtok, source, note)
115
+ VALUES
116
+ ('2026-12-01 00:00:00', 'mistral/mistral-large-4-0', '2026-12-01', 0, '',
117
+ 700000, 2100000, 70000, 'https://docs.mistral.ai/inference/pricing',
118
+ 'First observation: Mistral Large 4 catalogued as the replacement for mistral-large-2512 and mistral-medium-2604 (0126, #7). Standard column of the pricing page, matching the model card: $0.70 in, $0.07 cached, $2.10 out per MTok.');
@@ -0,0 +1,184 @@
1
+ -- Board follow-ups, 2026-12-03 (#10).
2
+ --
3
+ -- The board's list is a task list, not a source: every figure below was read
4
+ -- 2026-12-04 UTC from the provider's own page, cited per row (#79, #122).
5
+ -- Five of the board's items touch rows this catalogue holds; the rest are new
6
+ -- models, catalogued here and seated nowhere, or declined at the bottom with
7
+ -- the reason, so the next board pass does not raise them again.
8
+ --
9
+ -- ## Gemini 4 Argon leaves its five lanes before Google swaps the model
10
+ --
11
+ -- https://ai.google.dev/gemini-api/docs/deprecations (served from
12
+ -- aistudio.google.com/docs/deprecations): `gemini-4-argon` shuts down
13
+ -- 2026-12-15, replacement `gemini-4-carbon`, and from that date requests to
14
+ -- the Argon id are routed to Carbon and billed at Carbon's rates. The 2026-12-01
15
+ -- changelog entry says the two share a schema and rate limits, and that Carbon
16
+ -- can spend more thinking tokens per task, raising output spend and latency.
17
+ --
18
+ -- So from 2026-12-15 the string `gemini-4-argon` names a different model. A
19
+ -- measurement is the model seen to serve (`src/conformance-verdict.ts`), and
20
+ -- Argon's stays valid on paper for up to 30 days after the swap while
21
+ -- describing a model that no longer answers. Seats are what lanes route on, so
22
+ -- they go now, before the date, rather than trusting a measurement of the wrong
23
+ -- model for a fortnight. Argon held rank 2 in the four coding lanes and rank 1
24
+ -- in `bb/deep-reasoning` (0111). Every lane keeps at least one rank-1 member
25
+ -- (Fable 5.1, Opus 5.5 and GPT-6 Astra in the coding lanes; DeepSeek Flash and
26
+ -- GPT-6 Astra in deep-reasoning) and seven or more members, so nothing else
27
+ -- moves. Google's seat in those lanes is empty until Carbon is measured.
28
+ --
29
+ -- The model stays **enabled**: a caller naming it directly is owed what Google
30
+ -- serves under it, and Google keeps serving it. Its price does not change at
31
+ -- the swap: Argon's 2026-12-01 row (0110) is $4 / $20 / $0.20, which is
32
+ -- Carbon's standard rate on the pricing page today. Re-read, not re-written.
33
+ --
34
+ -- ## grok-build-0.1 is disabled
35
+ --
36
+ -- https://docs.x.ai/developers/release-notes (served from docs.grok.com):
37
+ -- "`grok-build-0.1` reached end of life on November 19, 2026 and is no longer
38
+ -- served on the API." It is in no lane. Disabled, never deleted: the ledger may
39
+ -- name it, and its price rows stay (0062). The measurement is cleared with it,
40
+ -- as 0090 did for `mistral/zai-glm-5-2`. `grok-build-latest`, the board says,
41
+ -- now aliases Grok 4.5. This catalogue has no row under that name and gains
42
+ -- none: an alias that moves is a rate change with no signal (0025).
43
+ --
44
+ -- ## gpt-5.6-sol: the promotion has ended
45
+ --
46
+ -- https://developers.openai.com/api/docs/pricing no longer marks a promotion
47
+ -- for gpt-5.6-sol. Standard is $5.00 / $30.00 / $0.50 per MTok (≤272K input)
48
+ -- and $10.00 / $45.00 / $1.00 above it; Batch is half: $2.50 / $15.00 / $0.25
49
+ -- and $5.00 / $22.50 / $0.50. The page prints no date for the change, so the
50
+ -- rows take the read date, 2026-12-04 (0020, 0021). Requests between the end of
51
+ -- the promotion and this migration were priced at the old rate. That is a
52
+ -- lower ledger figure for those days, and nothing here can reprice a row
53
+ -- already written.
54
+ --
55
+ -- It stays in its four lanes at rank 2. Lanes select `cheap`, so a dearer
56
+ -- member simply wins less traffic; and a lane's price is its maximum member
57
+ -- (`src/lanes.ts`), so the rise reaches the budget checks by itself.
58
+ --
59
+ -- ## New models: catalogued, unmeasured, in no lane
60
+ --
61
+ -- The 0110 → 0111 shape: catalogue and price now, seat after a conformance
62
+ -- run. An unmeasured member nulls a lane's capabilities (`src/lanes.ts`).
63
+ --
64
+ -- `google-ai-studio/gemini-4-carbon` and `gemini-4-hydrogen`: GA 2026-11-10
65
+ -- and 2026-11-12 (changelog). Each model page: context window 1,048,576
66
+ -- ("unified input and output token limit"), max output "65,536 (default
67
+ -- synchronous) / up to 1,048,576 (with long decode)". The synchronous figure,
68
+ -- for 0110's reason: long decode is not on the compat path. No prompt-length
69
+ -- tier on the pricing page. Carbon $4.00 / $20.00 / $0.20, dated 2026-12-01 by
70
+ -- the changelog that ended its introductory rate. Hydrogen $1.50 / $7.50 /
71
+ -- $0.075, no introductory rate stated, from the read date. Hydrogen is the
72
+ -- board's pick for a `project-management` lane holding Argon; none does.
73
+ --
74
+ -- `openai/gpt-6.2-sol` and `gpt-6.2-astra`: each model page gives a
75
+ -- 1,050,000 context window and 128,000 max output, the shape 0088 wrote for
76
+ -- GPT-6.1 Sol (the page's 922,000 maximum input is inside that window). Prices
77
+ -- from the pricing page, ≤272K / >272K, Standard then Batch:
78
+ -- gpt-6.2-sol $2 / $10 / $0.10, $4 / $15 / $0.20; batch half of each
79
+ -- gpt-6.2-astra $8 / $40 / $0.40, $16 / $60 / $0.80; batch half of each
80
+ -- Both pages: "The API rejects requests that set reasoning effort to `none`."
81
+ -- Cruise never sends `none` itself; a caller's value passes through. Tool
82
+ -- requests already go by `/responses`: `isOpenAIReasoningModel` matches
83
+ -- `^gpt-6`. So neither needs code, and the `none` refusal is the caller's to
84
+ -- see if they send it.
85
+ --
86
+ -- `anthropic/claude-fable-5-2`: model page, 1M context, 128K output. Pricing
87
+ -- page: $8 input, $40 output, $0.20 cache read per MTok, the full 1M window at
88
+ -- the standard rate (no long-context tier). No batch row: Cruise's Batch API
89
+ -- reaches OpenAI only (`docs/batches.md`). Mythos 5.2 is "limited
90
+ -- availability" and gated, so it is not a buyable member and is not
91
+ -- catalogued.
92
+ --
93
+ -- Retention: `retained` on each host's API terms as last read for that host's
94
+ -- rows (OpenAI 2026-10-02, Anthropic 2026-10-02, Google 2026-10-15, on the paid
95
+ -- key 0109 read). A new row inherits nothing, so each writes its own (0110).
96
+ -- The dates are when those terms were read, not today: nobody re-read them.
97
+ --
98
+ -- ## Declined, and why
99
+ --
100
+ -- - `qwen4-max` (Alibaba) and `glm-5.4` (Z.ai, API-only): neither lab has an
101
+ -- upstream row. Each is tier 3 or 4 in `docs/upstreams.md`, starting with an
102
+ -- account and a key, not a migration.
103
+ -- - gpt-6.2-astra's capability item asks to re-derive lane limits "if it's a
104
+ -- lane member". It is not one yet; its limits are written above.
105
+ -- - Gemini 4 Live and Live Translate are audio-session models with no text
106
+ -- row. Kimi K3.1 Pro Prime has no first-party page to price from.
107
+
108
+ DELETE FROM lane_members
109
+ WHERE model_id = 'google-ai-studio/gemini-4-argon'
110
+ AND lane_id IN ('bb/agentic-coding', 'bb/builder', 'bb/code-review', 'bb/deep-reasoning', 'bb/hunter');
111
+
112
+ UPDATE models
113
+ SET enabled = 0,
114
+ measured_at = NULL,
115
+ measured_by = NULL,
116
+ measurement_source = NULL
117
+ WHERE id = 'grok/grok-build-0.1';
118
+
119
+ INSERT INTO models (id, upstream_id, upstream_model, max_context, max_output,
120
+ data_retention, data_retention_source, data_retention_as_of) VALUES
121
+ ('google-ai-studio/gemini-4-carbon', 'google-ai-studio', 'gemini-4-carbon', 1048576, 65536,
122
+ 'retained', 'https://ai.google.dev/gemini-api/terms (Paid Services; key on Tier 1)', '2026-10-15'),
123
+ ('google-ai-studio/gemini-4-hydrogen', 'google-ai-studio', 'gemini-4-hydrogen', 1048576, 65536,
124
+ 'retained', 'https://ai.google.dev/gemini-api/terms (Paid Services; key on Tier 1)', '2026-10-15'),
125
+ ('openai/gpt-6.2-sol', 'openai', 'gpt-6.2-sol', 1050000, 128000,
126
+ 'retained', 'https://developers.openai.com/api/docs/guides/your-data', '2026-10-02'),
127
+ ('openai/gpt-6.2-astra', 'openai', 'gpt-6.2-astra', 1050000, 128000,
128
+ 'retained', 'https://developers.openai.com/api/docs/guides/your-data', '2026-10-02'),
129
+ ('anthropic/claude-fable-5-2', 'anthropic', 'claude-fable-5-2', 1000000, 128000,
130
+ 'retained', 'https://privacy.claude.com/en/articles/7996868-is-my-data-used-for-model-training', '2026-10-02');
131
+
132
+ INSERT INTO price_observations
133
+ (observed_at, model, effective_from, prompt_tokens_from, peak_utc, service_tier,
134
+ input_micros_per_mtok, output_micros_per_mtok, cached_input_micros_per_mtok, source, note)
135
+ VALUES
136
+ ('2026-12-04 00:00:00', 'openai/gpt-5.6-sol', '2026-12-04', 0, '', '',
137
+ 5000000, 30000000, 500000, 'https://developers.openai.com/api/docs/pricing',
138
+ 'The promotional rate has ended (#10, 0127). The page prints no date for the change, so the read date.'),
139
+ ('2026-12-04 00:00:00', 'openai/gpt-5.6-sol', '2026-12-04', 272001, '', '',
140
+ 10000000, 45000000, 1000000, 'https://developers.openai.com/api/docs/pricing',
141
+ 'Long-context tier: >272K input tokens.'),
142
+ ('2026-12-04 00:00:00', 'openai/gpt-5.6-sol', '2026-12-04', 0, '', 'batch',
143
+ 2500000, 15000000, 250000, 'https://developers.openai.com/api/docs/pricing',
144
+ 'Batch, half the post-promotion standard rate (#10, 0127).'),
145
+ ('2026-12-04 00:00:00', 'openai/gpt-5.6-sol', '2026-12-04', 272001, '', 'batch',
146
+ 5000000, 22500000, 500000, 'https://developers.openai.com/api/docs/pricing',
147
+ 'Batch long-context tier: >272K input tokens.'),
148
+
149
+ ('2026-12-04 00:00:00', 'google-ai-studio/gemini-4-carbon', '2026-12-01', 0, '', '',
150
+ 4000000, 20000000, 200000, 'https://ai.google.dev/gemini-api/docs/pricing',
151
+ 'First observation (#10, 0127). Standard rate from 2026-12-01, dated by the changelog entry ending the introductory rate. Implicit caching only.'),
152
+ ('2026-12-04 00:00:00', 'google-ai-studio/gemini-4-hydrogen', '2026-12-04', 0, '', '',
153
+ 1500000, 7500000, 75000, 'https://ai.google.dev/gemini-api/docs/pricing',
154
+ 'First observation (#10, 0127). No introductory rate stated. Implicit caching only.'),
155
+
156
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-sol', '2026-12-04', 0, '', '',
157
+ 2000000, 10000000, 100000, 'https://developers.openai.com/api/docs/pricing',
158
+ 'First observation (#10, 0127).'),
159
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-sol', '2026-12-04', 272001, '', '',
160
+ 4000000, 15000000, 200000, 'https://developers.openai.com/api/docs/pricing',
161
+ 'Long-context tier: >272K input tokens.'),
162
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-sol', '2026-12-04', 0, '', 'batch',
163
+ 1000000, 5000000, 50000, 'https://developers.openai.com/api/docs/pricing',
164
+ 'First batch observation (#10, 0127).'),
165
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-sol', '2026-12-04', 272001, '', 'batch',
166
+ 2000000, 7500000, 100000, 'https://developers.openai.com/api/docs/pricing',
167
+ 'Batch long-context tier: >272K input tokens.'),
168
+
169
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-astra', '2026-12-04', 0, '', '',
170
+ 8000000, 40000000, 400000, 'https://developers.openai.com/api/docs/pricing',
171
+ 'First observation (#10, 0127).'),
172
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-astra', '2026-12-04', 272001, '', '',
173
+ 16000000, 60000000, 800000, 'https://developers.openai.com/api/docs/pricing',
174
+ 'Long-context tier: >272K input tokens.'),
175
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-astra', '2026-12-04', 0, '', 'batch',
176
+ 4000000, 20000000, 200000, 'https://developers.openai.com/api/docs/pricing',
177
+ 'First batch observation (#10, 0127).'),
178
+ ('2026-12-04 00:00:00', 'openai/gpt-6.2-astra', '2026-12-04', 272001, '', 'batch',
179
+ 8000000, 30000000, 400000, 'https://developers.openai.com/api/docs/pricing',
180
+ 'Batch long-context tier: >272K input tokens.'),
181
+
182
+ ('2026-12-04 00:00:00', 'anthropic/claude-fable-5-2', '2026-12-04', 0, '', '',
183
+ 8000000, 40000000, 200000, 'https://platform.claude.com/docs/en/about-claude/pricing',
184
+ 'First observation (#10, 0127). The full 1M window at the standard rate: no long-context tier.');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bytesbrains/cruise-worker",
3
- "version": "0.14.1",
3
+ "version": "0.15.0",
4
4
  "description": "The Cruise Worker, built and ready to deploy: one OpenAI-compatible endpoint in front of every model provider, with budgets that stop.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
package/worker/VERSION CHANGED
@@ -1 +1 @@
1
- 0.14.1+81955629
1
+ 0.15.0+5410a035