@askalf/dario 4.8.53 → 4.8.55

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/README.md CHANGED
@@ -12,11 +12,13 @@
12
12
  <a href="https://x.com/ask_alf"><img src="https://img.shields.io/badge/follow-@ask_alf-1da1f2?style=flat-square" alt="Follow on X"></a>
13
13
  </p>
14
14
 
15
- <p align="center"><em>Zero runtime dependencies · <a href="https://www.npmjs.com/package/@askalf/dario">SLSA-attested</a> every release · nothing phones home · ~18.8k lines you can read in a weekend · independent, unofficial, third-party (<a href="DISCLAIMER.md">DISCLAIMER.md</a>)</em></p>
15
+ <p align="center"><em>Zero runtime dependencies · <a href="https://www.npmjs.com/package/@askalf/dario">SLSA-attested</a> every release · nothing phones home · ~19.2k lines you can read in a weekend · independent, unofficial, third-party (<a href="DISCLAIMER.md">DISCLAIMER.md</a>)</em></p>
16
16
 
17
17
  ---
18
18
 
19
- > ⚠️ **Critical update please upgrade to v4.8.41.** Versions **before 4.8.39** could silently corrupt code / structured content routed through dario (the identifier scrub stripped tokens like the JavaScript `continue` keyword `continue;` became `;`). **4.8.41** also adds CC-style prompt caching (~99% less fresh input on long sessions, so they stop hitting Max limits early). **[Details →](https://github.com/askalf/dario/issues/457)** · `npm install -g @askalf/dario@latest`
19
+ > **NewClaude Fable 5 fully supported.** `claude-fable-5`, its `[1m]` long-context variant, and the `fable` / `fable1m` shortcuts route on your subscription like any other model. dario tracked CC's new flagship the day it shipped, including the wire quirks Anthropic never documented: the `fallback-credit` beta fable *requires* (without it subscription fable traffic is silently soft-refused), its refusal of high effort levels, and the **per-model beta tailoring** matched to CC v2.1.170. `npm install -g @askalf/dario@latest`
20
+ >
21
+ > ⚠️ Still on a version **before 4.8.39**? Upgrade now — those could silently corrupt code/structured content routed through the proxy (the identifier scrub stripped tokens like the JS `continue` keyword). **[Details →](https://github.com/askalf/dario/issues/457)**
20
22
 
21
23
  ---
22
24
 
@@ -154,13 +156,15 @@ dario doesn't *guess* Claude Code's request shape — it captures it live from y
154
156
 
155
157
  [Discussion #178](https://github.com/askalf/dario/discussions/178) reproduces a ninth fingerprint operating on commit metadata: the classifier fires on the literal namespaced string `openclaw.inbound_meta.v1` in recent git commits. dario's template replay protects you because that git context never reaches `api.anthropic.com` — only dario's captured CC template does.
156
158
 
157
- **Why this needs constant maintenance.** The 2026-06-15 split is announced; the wire-shape changes that arrive between releases are not. CC v2.1.142 ([changelog](https://code.claude.com/docs/en/changelog), 2026-05-14) itemized a Fast-mode tweak and some fixes — and said **nothing** about three wire-shape changes in the same release:
159
+ **Why this needs constant maintenance.** The 2026-06-15 split is announced; the wire-shape changes that arrive between releases are not. CC v2.1.142 ([changelog](https://code.claude.com/docs/en/changelog), 2026-05-14) itemized a Fast-mode tweak and some fixes — and said **nothing** about three wire-shape changes in the same release. That's the rule, not the exception; a running ledger of silent changes dario caught and shipped:
158
160
 
159
- | Silent change in v2.1.142 | Effect on subscribers | dario shipped |
161
+ | Silent wire-shape change (no subscriber changelog) | Effect on subscribers | dario shipped |
160
162
  |---|---|---|
161
163
  | `context-1m-2025-08-07` dropped from the default beta set + rejected on OAuth auth | Subscription users lose >200K context on Sonnet/Opus | v3.38.3–4 (2026-05-14/15) |
162
164
  | `thinking: {type:"adaptive"}` gated per-model server-side | Sonnet/Opus 4-5 through any proxy 400s every request | [v3.38.5](https://github.com/askalf/dario/pull/273) — 2026-05-15 |
163
165
  | `TodoWrite`/`TodoRead` replaced by the `Task*` family, no migration note | Clients hardcoding `todo_*` send unrecognized tools | [v3.38.6](https://github.com/askalf/dario/pull/274) — 13 min later |
166
+ | **Claude Fable 5** ships as CC's flagship (v2.1.170) with undocumented wire quirks: a required `fallback-credit-2026-06-01` beta, soft-refusal of `max`/`xhigh` effort, and a `[1m]`-only `context-1m` beta | Subscription fable traffic 200-refused (empty body) without the flag; wrong effort silently returns nothing | [v4.8.46–52](https://github.com/askalf/dario/pulls?q=fable) — 2026-06-09 |
167
+ | CC tailors the `anthropic-beta` set **per model** — opus 9, sonnet 8 (no `mid-conversation-system`), haiku 6 (also no `effort`) | Proxies sending one beta set diverge from CC for non-opus models | [v4.8.53](https://github.com/askalf/dario/pull/478) — 2026-06-09 |
164
168
 
165
169
  And it gets subtler: v4.2.1 (2026-05-17) shipped receipts for **same CC binary, different wire output 24 hours apart** — Anthropic ships changes through CC's *remote configuration*, not just npm releases. So dario runs **three classes of drift detection**, all auto-detecting and auto-PR'ing:
166
170
 
@@ -179,7 +183,7 @@ You point every tool at one URL. dario reads each request, decides which backend
179
183
 
180
184
  | Client speaks | Model | Routes to | What happens |
181
185
  |---|---|---|---|
182
- | Anthropic Messages | `claude-*` / `opus` / `sonnet` / `haiku` | Claude backend | OAuth swap + CC template replay → `api.anthropic.com` |
186
+ | Anthropic Messages | `claude-*` / `fable` / `opus` / `sonnet` / `haiku` | Claude backend | OAuth swap + CC template replay → `api.anthropic.com` |
183
187
  | Anthropic Messages | `gpt-*`, `llama-*`, … | OpenAI-compat backend | Anthropic→OpenAI translation, forwarded |
184
188
  | OpenAI Chat | `gpt-*` / `o1-*` / `o3-*` | OpenAI-compat backend | Auth swap, body forwarded byte-for-byte |
185
189
  | OpenAI Chat | `claude-*` | Claude backend | OpenAI→Anthropic translation, then Claude path |
@@ -187,6 +191,8 @@ You point every tool at one URL. dario reads each request, decides which backend
187
191
 
188
192
  The tool doesn't know. The backend doesn't know. dario is the seam.
189
193
 
194
+ **The full Claude lineup, kept current.** Claude Fable 5 (CC's flagship), Opus 4.8, Sonnet 4.6, and Haiku 4.5 — plus `[1m]` long-context variants — by full id (`claude-fable-5`, `claude-opus-4-8`) or shortcut (`fable` / `opus` / `sonnet` / `haiku` / `fable1m`). dario adopts each new model the day it lands and applies its model-specific wire shape (effort level, beta set, thinking config) automatically; `GET /v1/models` always reflects the live set.
195
+
190
196
  ---
191
197
 
192
198
  ## Overage guard
@@ -228,11 +234,11 @@ Tune via `~/.dario/config.json` → `overageGuard`, or CLI flags: `--overage-beh
228
234
 
229
235
  | Signal | Status |
230
236
  |---|---|
231
- | Source | **~18.8k** lines of TypeScript across **44** files — auditable in a weekend |
237
+ | Source | **~19.2k** lines of TypeScript across **44** files — auditable in a weekend |
232
238
  | Dependencies | **0 runtime.** Verify: `npm ls --production` |
233
239
  | Provenance | Every release [SLSA-attested](https://www.npmjs.com/package/@askalf/dario) via GitHub Actions + Sigstore |
234
240
  | Scanning | [CodeQL](https://github.com/askalf/dario/actions/workflows/codeql.yml) on every push and weekly |
235
- | Tests | **84 test files**, **77 in the default `npm test` suite** (`test/all.test.mjs`) — green on every release |
241
+ | Tests | **91 test files**, **84 in the default `npm test` suite** (`test/all.test.mjs`) — green on every release |
236
242
  | Drift response | hourly [`cc-drift-watch.yml`](./.github/workflows/cc-drift-watch.yml) + auto-publish on merge — median CC-release → dario-release under one hour |
237
243
  | Credentials | Never logged, redacted from errors, `0600` on disk in `0700` dirs; MCP server redacts at the tool boundary |
238
244
  | Network | Binds `127.0.0.1` by default; upstream only to configured backends over HTTPS; hardcoded SSRF allowlist |
package/dist/proxy.d.ts CHANGED
@@ -111,6 +111,15 @@ export declare function buildOrchestrationPatterns(preserveTags?: Set<string>):
111
111
  * opt any tag out of the scrub. dario#78.
112
112
  */
113
113
  export declare function sanitizeMessages(body: Record<string, unknown>, preserveTags?: Set<string>): void;
114
+ export declare const OPENAI_MODELS_LIST: {
115
+ object: string;
116
+ data: {
117
+ id: string;
118
+ object: string;
119
+ created: number;
120
+ owned_by: string;
121
+ }[];
122
+ };
114
123
  interface ProxyOptions {
115
124
  port?: number;
116
125
  host?: string;
package/dist/proxy.js CHANGED
@@ -477,7 +477,7 @@ function translateStreamChunk(line) {
477
477
  catch { }
478
478
  return null;
479
479
  }
480
- const OPENAI_MODELS_LIST = { object: 'list', data: ['claude-fable-5', 'claude-fable-5[1m]', 'claude-opus-4-8', 'claude-opus-4-7', 'claude-opus-4-6', 'claude-sonnet-4-6', 'claude-haiku-4-5'].map(id => ({ id, object: 'model', created: 1700000000, owned_by: 'anthropic' })) };
480
+ export const OPENAI_MODELS_LIST = { object: 'list', data: ['claude-fable-5', 'claude-fable-5[1m]', 'claude-opus-4-8', 'claude-opus-4-7', 'claude-opus-4-6', 'claude-sonnet-4-6', 'claude-haiku-4-5'].map(id => ({ id, object: 'model', created: 1700000000, owned_by: 'anthropic' })) };
481
481
  /**
482
482
  * Append a JSON-ND line to the proxy log file. No-op when stream is
483
483
  * null (logFile not configured). Errors are swallowed — log writes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@askalf/dario",
3
- "version": "4.8.53",
3
+ "version": "4.8.55",
4
4
  "description": "Use your Claude Pro/Max subscription in any tool — Cursor, Cline, Aider, the Agent SDK, your scripts — at subscription pricing, not per-token API bills. One local Anthropic + OpenAI-compatible endpoint.",
5
5
  "type": "module",
6
6
  "bin": {