@askalf/dario 4.8.52 → 4.8.53
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/dist/proxy.d.ts +30 -9
- package/dist/proxy.js +41 -9
- package/package.json +1 -1
package/dist/proxy.d.ts
CHANGED
|
@@ -29,17 +29,38 @@ export declare function parseProviderPrefix(model: string): {
|
|
|
29
29
|
*/
|
|
30
30
|
export declare const FABLE_FALLBACK_CREDIT_BETA = "fallback-credit-2026-06-01";
|
|
31
31
|
export declare const CONTEXT_1M_BETA = "context-1m-2025-08-07";
|
|
32
|
+
export declare const MID_CONVERSATION_SYSTEM_BETA = "mid-conversation-system-2026-04-07";
|
|
33
|
+
export declare const EFFORT_BETA = "effort-2025-11-24";
|
|
32
34
|
/**
|
|
33
35
|
* Model-conditional beta flags, mirroring real CC (live captures
|
|
34
|
-
* 2026-06-09, CC v2.1.170 —
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
* -
|
|
38
|
-
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
36
|
+
* 2026-06-09, CC v2.1.170 — same binary/account, `--print -p hi`, identical
|
|
37
|
+
* request shape, deterministic across repeat trials):
|
|
38
|
+
*
|
|
39
|
+
* model betas effort-body notable beta set
|
|
40
|
+
* --------------- ----- ----------- ------------------------------------
|
|
41
|
+
* claude-opus-4-8 9 xhigh baked base (all flags)
|
|
42
|
+
* claude-sonnet-4-6 8 high base − mid-conversation-system
|
|
43
|
+
* claude-haiku-4-5 6 (none) base − mid-conversation-system − effort
|
|
44
|
+
*
|
|
45
|
+
* APPENDS (CC adds for these families):
|
|
46
|
+
* - `fallback-credit-2026-06-01` rides on FABLE requests only (without it,
|
|
47
|
+
* subscription fable traffic is soft-refused upstream).
|
|
48
|
+
* - `context-1m-2025-08-07` rides on `[1m]`-labelled requests only (CC does
|
|
49
|
+
* NOT send it for plain models). `skipContext1m` (dario#36) suppresses the
|
|
50
|
+
* [1m] append when the account's long-context billing was rejected.
|
|
51
|
+
*
|
|
52
|
+
* OMISSIONS (CC drops for these families; the baked base is opus's full set):
|
|
53
|
+
* - `mid-conversation-system-2026-04-07` — sonnet + haiku omit it. All three
|
|
54
|
+
* models still send the SAME 3 system blocks, so this is a capability
|
|
55
|
+
* advertisement, not load-bearing for the system shape — safe to drop.
|
|
56
|
+
* - `effort-2025-11-24` — haiku omits it (and sends no `output_config.effort`
|
|
57
|
+
* body field either; dario already strips that field for haiku, so dropping
|
|
58
|
+
* the beta just restores consistency).
|
|
59
|
+
*
|
|
60
|
+
* Removing a beta can never provoke an upstream 400 (the runtime rejection
|
|
61
|
+
* cache only ever needs to ADD strips), so the omissions are strictly safe.
|
|
62
|
+
* Only the two families measured to omit them are touched; opus / fable /
|
|
63
|
+
* unknown models keep the full baked set unchanged.
|
|
43
64
|
*/
|
|
44
65
|
export declare function betaForModel(base: string, model: string | null | undefined, skipContext1m?: boolean): string;
|
|
45
66
|
/**
|
package/dist/proxy.js
CHANGED
|
@@ -209,17 +209,38 @@ function filterBillableBetas(betas) {
|
|
|
209
209
|
*/
|
|
210
210
|
export const FABLE_FALLBACK_CREDIT_BETA = 'fallback-credit-2026-06-01';
|
|
211
211
|
export const CONTEXT_1M_BETA = 'context-1m-2025-08-07';
|
|
212
|
+
export const MID_CONVERSATION_SYSTEM_BETA = 'mid-conversation-system-2026-04-07';
|
|
213
|
+
export const EFFORT_BETA = 'effort-2025-11-24';
|
|
212
214
|
/**
|
|
213
215
|
* Model-conditional beta flags, mirroring real CC (live captures
|
|
214
|
-
* 2026-06-09, CC v2.1.170 —
|
|
215
|
-
*
|
|
216
|
-
*
|
|
217
|
-
* -
|
|
218
|
-
*
|
|
219
|
-
*
|
|
220
|
-
*
|
|
221
|
-
*
|
|
222
|
-
*
|
|
216
|
+
* 2026-06-09, CC v2.1.170 — same binary/account, `--print -p hi`, identical
|
|
217
|
+
* request shape, deterministic across repeat trials):
|
|
218
|
+
*
|
|
219
|
+
* model betas effort-body notable beta set
|
|
220
|
+
* --------------- ----- ----------- ------------------------------------
|
|
221
|
+
* claude-opus-4-8 9 xhigh baked base (all flags)
|
|
222
|
+
* claude-sonnet-4-6 8 high base − mid-conversation-system
|
|
223
|
+
* claude-haiku-4-5 6 (none) base − mid-conversation-system − effort
|
|
224
|
+
*
|
|
225
|
+
* APPENDS (CC adds for these families):
|
|
226
|
+
* - `fallback-credit-2026-06-01` rides on FABLE requests only (without it,
|
|
227
|
+
* subscription fable traffic is soft-refused upstream).
|
|
228
|
+
* - `context-1m-2025-08-07` rides on `[1m]`-labelled requests only (CC does
|
|
229
|
+
* NOT send it for plain models). `skipContext1m` (dario#36) suppresses the
|
|
230
|
+
* [1m] append when the account's long-context billing was rejected.
|
|
231
|
+
*
|
|
232
|
+
* OMISSIONS (CC drops for these families; the baked base is opus's full set):
|
|
233
|
+
* - `mid-conversation-system-2026-04-07` — sonnet + haiku omit it. All three
|
|
234
|
+
* models still send the SAME 3 system blocks, so this is a capability
|
|
235
|
+
* advertisement, not load-bearing for the system shape — safe to drop.
|
|
236
|
+
* - `effort-2025-11-24` — haiku omits it (and sends no `output_config.effort`
|
|
237
|
+
* body field either; dario already strips that field for haiku, so dropping
|
|
238
|
+
* the beta just restores consistency).
|
|
239
|
+
*
|
|
240
|
+
* Removing a beta can never provoke an upstream 400 (the runtime rejection
|
|
241
|
+
* cache only ever needs to ADD strips), so the omissions are strictly safe.
|
|
242
|
+
* Only the two families measured to omit them are touched; opus / fable /
|
|
243
|
+
* unknown models keep the full baked set unchanged.
|
|
223
244
|
*/
|
|
224
245
|
export function betaForModel(base, model, skipContext1m = false) {
|
|
225
246
|
let beta = base;
|
|
@@ -233,6 +254,17 @@ export function betaForModel(base, model, skipContext1m = false) {
|
|
|
233
254
|
append(FABLE_FALLBACK_CREDIT_BETA);
|
|
234
255
|
if (/\[1m\]$/.test(m) && !skipContext1m)
|
|
235
256
|
append(CONTEXT_1M_BETA);
|
|
257
|
+
const drop = new Set();
|
|
258
|
+
if (m.includes('haiku')) {
|
|
259
|
+
drop.add(MID_CONVERSATION_SYSTEM_BETA);
|
|
260
|
+
drop.add(EFFORT_BETA);
|
|
261
|
+
}
|
|
262
|
+
else if (m.includes('sonnet')) {
|
|
263
|
+
drop.add(MID_CONVERSATION_SYSTEM_BETA);
|
|
264
|
+
}
|
|
265
|
+
if (drop.size > 0) {
|
|
266
|
+
beta = beta.split(',').filter((b) => !drop.has(b.trim())).join(',');
|
|
267
|
+
}
|
|
236
268
|
return beta;
|
|
237
269
|
}
|
|
238
270
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@askalf/dario",
|
|
3
|
-
"version": "4.8.
|
|
3
|
+
"version": "4.8.53",
|
|
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": {
|