@askalf/dario 2.9.2 → 2.9.4

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.
Files changed (2) hide show
  1. package/README.md +63 -26
  2. package/package.json +1 -4
package/README.md CHANGED
@@ -33,7 +33,7 @@ export ANTHROPIC_BASE_URL=http://localhost:3456 # or OPENAI_BASE_URL=http://lo
33
33
  export ANTHROPIC_API_KEY=dario # or OPENAI_API_KEY=dario
34
34
  ```
35
35
 
36
- Opus, Sonnet, Haiku — all models, streaming, tool use. Works with Cursor, Continue, Aider, LiteLLM, Hermes, OpenClaw, or any tool that speaks the Anthropic or OpenAI API. When rate limited, `--cli` routes through Claude Code for uninterrupted Opus access.
36
+ Opus, Sonnet, Haiku — all models, streaming, tool use. **Zero dependencies.** ~1,600 lines of TypeScript. Works with Cursor, Continue, Aider, LiteLLM, Hermes, OpenClaw, or any tool that speaks the Anthropic or OpenAI API. When rate limited, `--cli` routes through Claude Code for uninterrupted Opus access.
37
37
 
38
38
  <table>
39
39
  <tr>
@@ -44,7 +44,7 @@ Opus, Sonnet, Haiku — all models, streaming, tool use. Works with Cursor, Cont
44
44
 
45
45
  **Grok** (xAI)
46
46
 
47
- *"Dario works great and is safe. Fully functional with OpenClaw / Hermes. Gives you Opus 4.6, Sonnet & Haiku using your existing Claude Max/Pro sub. No extra API key or billing needed. Streaming + tools work perfectly. 100% open-source (~1100 lines TS), runs locally only, proper OAuth (PKCE), no telemetry. Highly recommended if you want a clean local proxy."*
47
+ *"Dario works great and is safe. Fully functional with OpenClaw / Hermes. Gives you Opus 4.6, Sonnet & Haiku using your existing Claude Max/Pro sub. No extra API key or billing needed. Streaming + tools work perfectly. 100% open-source, runs locally only, proper OAuth (PKCE), no telemetry. Highly recommended if you want a clean local proxy."*
48
48
 
49
49
  </td>
50
50
  <td width="33%" valign="top">
@@ -58,7 +58,7 @@ Opus, Sonnet, Haiku — all models, streaming, tool use. Works with Cursor, Cont
58
58
 
59
59
  **Gemini** (Google)
60
60
 
61
- *"Highly recommended for personal, local development. Solves a massive pain point for developers by bridging Claude Max/Pro subscriptions with developer IDEs, saving substantial API costs. Modular & lean (~1100 lines), modern PKCE auth, SSRF protection, mature CI/CD pipeline with CodeQL and npm provenance attestations."*
61
+ *"Highly recommended for personal, local development. Solves a massive pain point for developers by bridging Claude Max/Pro subscriptions with developer IDEs, saving substantial API costs. Modular & lean, modern PKCE auth, SSRF protection, mature CI/CD pipeline with CodeQL and npm provenance attestations."*
62
62
 
63
63
  </td>
64
64
  </tr>
@@ -95,17 +95,17 @@ dario is the only proxy that solves this. It injects native Claude Code device i
95
95
  <details>
96
96
  <summary><strong>vs competitors</strong></summary>
97
97
 
98
- | Feature | dario | Meridian (710 stars) | CLIProxyAPI (24K stars) | claude-code-mux |
99
- |---------|-------|---------|------------|-----------------|
100
- | Native billing classification | **Yes** | No | Inherited (CLI-only) | No |
101
- | Direct OAuth (streaming, tools) | **Yes** | Yes (SDK-based) | No | No |
102
- | CLI fallback (rate limit bypass) | **Yes** | No | Yes (only mode) | No |
103
- | OpenAI API compat | **Yes** | Yes | Yes | Yes |
104
- | Orchestration sanitization | **Yes** | Yes | No | No |
105
- | Token anomaly detection | **Yes** | Yes | No | No |
106
- | Codebase size | ~1,500 lines | ~9,000 lines | Platform | Rust binary |
107
- | Dependencies | 1 | Many | Many | Compiled |
108
- | Setup | 2 commands | Config + build | Config + dashboard | Config |
98
+ | Feature | dario | Meridian (710 stars) | CLIProxyAPI (24K stars) |
99
+ |---------|-------|---------|------------|
100
+ | Native billing classification | **Yes** | No | Inherited (CLI-only) |
101
+ | Direct OAuth (streaming, tools) | **Yes** | Yes (SDK-based) | No |
102
+ | CLI fallback (rate limit bypass) | **Yes** | No | Yes (only mode) |
103
+ | OpenAI API compat | **Yes** | Yes | Yes |
104
+ | Orchestration sanitization | **Yes** | Yes | No |
105
+ | Token anomaly detection | **Yes** | Yes | No |
106
+ | Codebase size | ~1,600 lines | ~9,000 lines | Platform |
107
+ | Dependencies | 0 | Many | Many |
108
+ | Setup | 2 commands | Config + build | Config + dashboard |
109
109
 
110
110
  </details>
111
111
 
@@ -346,6 +346,44 @@ model:
346
346
 
347
347
  Then run `hermes` normally — it routes through dario using your Claude subscription.
348
348
 
349
+ ### OpenClaw
350
+
351
+ Add to your `openclaw.json` models config:
352
+
353
+ ```json
354
+ {
355
+ "models": {
356
+ "providers": {
357
+ "anthropic": {
358
+ "baseUrl": "http://127.0.0.1:3456",
359
+ "apiKey": "dario",
360
+ "api": "anthropic-messages",
361
+ "models": [
362
+ {
363
+ "id": "claude-sonnet-4-6",
364
+ "name": "claude-sonnet-4-6",
365
+ "contextWindow": 1000000,
366
+ "maxTokens": 64000,
367
+ "input": ["text"],
368
+ "reasoning": true
369
+ },
370
+ {
371
+ "id": "claude-opus-4-6",
372
+ "name": "claude-opus-4-6",
373
+ "contextWindow": 1000000,
374
+ "maxTokens": 64000,
375
+ "input": ["text"],
376
+ "reasoning": true
377
+ }
378
+ ]
379
+ }
380
+ }
381
+ }
382
+ }
383
+ ```
384
+
385
+ **Note:** Use `http://127.0.0.1:3456` without `/v1` — OpenClaw adds the path itself.
386
+
349
387
  ## How It Works
350
388
 
351
389
  ### Direct API Mode (default)
@@ -544,8 +582,8 @@ Dario handles your OAuth tokens. Here's why you can trust it:
544
582
 
545
583
  | Signal | Status |
546
584
  |--------|--------|
547
- | **Source code** | ~1,500 lines of TypeScript — small enough to audit in one sitting |
548
- | **Dependencies** | 1 production dep (`@anthropic-ai/sdk`). Verify: `npm ls --production` |
585
+ | **Source code** | ~1,600 lines of TypeScript — small enough to audit in one sitting |
586
+ | **Dependencies** | 0 runtime dependencies. Verify: `npm ls --production` |
549
587
  | **npm provenance** | Every release is [SLSA attested](https://www.npmjs.com/package/@askalf/dario) via GitHub Actions |
550
588
  | **Security scanning** | [CodeQL](https://github.com/askalf/dario/actions/workflows/codeql.yml) runs on every push and weekly |
551
589
  | **Credential handling** | Tokens never logged, redacted from errors, stored with 0600 permissions |
@@ -564,9 +602,17 @@ npm audit signatures 2>/dev/null; npm view @askalf/dario dist.integrity
564
602
  cd $(npm root -g)/@askalf/dario && npm ls --production
565
603
  ```
566
604
 
605
+ ## Technical Deep Dives
606
+
607
+ | Topic | Link |
608
+ |-------|------|
609
+ | Billing tag algorithm, fingerprint analysis, Hermes/OpenClaw compatibility | [Discussion #8](https://github.com/askalf/dario/discussions/8) |
610
+ | Why Opus 4.6 feels worse and how to fix it (thinking block accumulation, effort defaults) | [Discussion #9](https://github.com/askalf/dario/discussions/9) |
611
+ | Rate limit header analysis and subscription throttling mechanics | [Discussion #1](https://github.com/askalf/dario/discussions/1) |
612
+
567
613
  ## Contributing
568
614
 
569
- PRs welcome. The codebase is ~1,500 lines of TypeScript across 4 files:
615
+ PRs welcome. The codebase is ~1,600 lines of TypeScript across 4 files:
570
616
 
571
617
  | File | Purpose |
572
618
  |------|---------|
@@ -589,15 +635,6 @@ npm run dev # runs with tsx (no build needed)
589
635
  | [@GodsBoy](https://github.com/GodsBoy) | Proxy authentication, token redaction, error sanitization ([#2](https://github.com/askalf/dario/pull/2)) |
590
636
  | [@belangertrading](https://github.com/belangertrading) | Billing classification investigation ([#4](https://github.com/askalf/dario/issues/4)), Opus/Sonnet 429 diagnosis + CLI fallback workaround ([#6](https://github.com/askalf/dario/issues/6)), billing reclassification root cause ([#7](https://github.com/askalf/dario/issues/7)) |
591
637
 
592
- ## Also by AskAlf
593
-
594
- | Project | What it does |
595
- |---------|-------------|
596
- | [platform](https://github.com/askalf/platform) | AI workforce with autonomous agents, teams, memory, and self-healing |
597
- | [agent](https://github.com/askalf/agent) | Connect any device to the workforce over WebSocket |
598
- | [claude-re](https://github.com/askalf/claude-re) | Claude Code reimplemented in Python |
599
- | [amnesia](https://github.com/askalf/amnesia) | Privacy search engine — 155 engines, zero tracking |
600
-
601
638
  ## License
602
639
 
603
640
  MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@askalf/dario",
3
- "version": "2.9.2",
3
+ "version": "2.9.4",
4
4
  "description": "Use your Claude subscription as an API. No API key needed. Local proxy for Claude Max/Pro subscriptions.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -56,9 +56,6 @@
56
56
  "engines": {
57
57
  "node": ">=18.0.0"
58
58
  },
59
- "dependencies": {
60
- "@anthropic-ai/sdk": "^0.81.0"
61
- },
62
59
  "devDependencies": {
63
60
  "@types/node": "^22.0.0",
64
61
  "tsx": "^4.19.0",