@rynfar/meridian 1.38.0 → 1.39.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/README.md +33 -3
- package/dist/{cli-bfgya0hb.js → cli-jbdchsr4.js} +430 -135
- package/dist/cli.js +1 -1
- package/dist/proxy/adapter.d.ts +28 -2
- package/dist/proxy/adapter.d.ts.map +1 -1
- package/dist/proxy/adapters/claudecode.d.ts +21 -0
- package/dist/proxy/adapters/claudecode.d.ts.map +1 -0
- package/dist/proxy/adapters/detect.d.ts +3 -2
- package/dist/proxy/adapters/detect.d.ts.map +1 -1
- package/dist/proxy/adapters/pi.d.ts.map +1 -1
- package/dist/proxy/agentDefs.d.ts +2 -0
- package/dist/proxy/agentDefs.d.ts.map +1 -1
- package/dist/proxy/agentMatch.d.ts +11 -1
- package/dist/proxy/agentMatch.d.ts.map +1 -1
- package/dist/proxy/messages.d.ts +11 -0
- package/dist/proxy/messages.d.ts.map +1 -1
- package/dist/proxy/models.d.ts +25 -0
- package/dist/proxy/models.d.ts.map +1 -1
- package/dist/proxy/openai.d.ts.map +1 -1
- package/dist/proxy/passthroughTools.d.ts +18 -0
- package/dist/proxy/passthroughTools.d.ts.map +1 -1
- package/dist/proxy/query.d.ts +19 -1
- package/dist/proxy/query.d.ts.map +1 -1
- package/dist/proxy/server.d.ts.map +1 -1
- package/dist/proxy/session/lineage.d.ts +10 -1
- package/dist/proxy/session/lineage.d.ts.map +1 -1
- package/dist/server.js +1 -1
- package/package.json +4 -2
package/README.md
CHANGED
|
@@ -7,12 +7,12 @@
|
|
|
7
7
|
<a href="https://www.npmjs.com/package/@rynfar/meridian"><img src="https://img.shields.io/npm/v/@rynfar/meridian?style=flat-square&color=8b5cf6&label=npm" alt="npm"></a>
|
|
8
8
|
<a href="#"><img src="https://img.shields.io/badge/platform-macOS%20%7C%20Linux%20%7C%20Windows-a78bfa?style=flat-square" alt="Platform"></a>
|
|
9
9
|
<a href="#"><img src="https://img.shields.io/badge/license-MIT-c4b5fd?style=flat-square" alt="License"></a>
|
|
10
|
-
<a href="https://discord.gg/
|
|
10
|
+
<a href="https://discord.gg/jP2a2Z92NZ"><img src="https://img.shields.io/badge/discord-join-5865F2?style=flat-square&logo=discord&logoColor=white" alt="Discord"></a>
|
|
11
11
|
</p>
|
|
12
12
|
|
|
13
13
|
---
|
|
14
14
|
|
|
15
|
-
Meridian bridges the Claude Code SDK to the standard Anthropic API. No OAuth interception. No binary patches. No hacks. Just pure, documented SDK calls. Any tool that speaks the Anthropic or OpenAI protocol — OpenCode, ForgeCode, Crush, Cline, Aider, Pi, Droid, Open WebUI — connects to Meridian and gets Claude, with session management, streaming, and prompt caching handled natively by the SDK.
|
|
15
|
+
Meridian bridges the Claude Code SDK to the standard Anthropic API. No OAuth interception. No binary patches. No hacks. Just pure, documented SDK calls. Any tool that speaks the Anthropic or OpenAI protocol — OpenCode, ForgeCode, Crush, Cline, Aider, Pi, Droid, Open WebUI, Claude Code — connects to Meridian and gets Claude, with session management, streaming, and prompt caching handled natively by the SDK.
|
|
16
16
|
|
|
17
17
|
> [!NOTE]
|
|
18
18
|
> ### How Meridian works with Anthropic
|
|
@@ -483,6 +483,35 @@ Pi uses the `@mariozechner/pi-ai` library which supports a configurable `baseUrl
|
|
|
483
483
|
|
|
484
484
|
Pi mimics Claude Code's User-Agent, so automatic detection isn't possible. The `x-meridian-agent: pi` header in the config above tells Meridian to use the Pi adapter. Alternatively, if Pi is your only agent, you can set `MERIDIAN_DEFAULT_AGENT=pi` as an env var instead.
|
|
485
485
|
|
|
486
|
+
### Claude Code
|
|
487
|
+
|
|
488
|
+
Claude Code can point at Meridian like any other Anthropic API client. The
|
|
489
|
+
common use case is sharing a single Claude Max subscription from one host
|
|
490
|
+
across other machines on your network — run Meridian on the box that is
|
|
491
|
+
logged into Claude Max, then run Claude Code anywhere else against it.
|
|
492
|
+
|
|
493
|
+
```bash
|
|
494
|
+
# On another machine (or the same one)
|
|
495
|
+
ANTHROPIC_AUTH_TOKEN=x ANTHROPIC_BASE_URL=http://meridian-host:3456 claude
|
|
496
|
+
```
|
|
497
|
+
|
|
498
|
+
> **Note:** Use `ANTHROPIC_AUTH_TOKEN` (or `ANTHROPIC_API_KEY`) — Claude Code
|
|
499
|
+
> treats both as bearer credentials. Set the value to your `MERIDIAN_API_KEY`
|
|
500
|
+
> if you've enabled authentication, otherwise any string works.
|
|
501
|
+
|
|
502
|
+
> ⚠️ **Security for multi-machine setups.** If you expose Meridian beyond
|
|
503
|
+
> loopback (e.g. bind to `0.0.0.0` or a LAN IP), **set `MERIDIAN_API_KEY` to a
|
|
504
|
+
> strong secret** and require it on clients. An unprotected network-accessible
|
|
505
|
+
> proxy is a Claude Max credential leak — anyone who can reach the port can
|
|
506
|
+
> burn your subscription.
|
|
507
|
+
|
|
508
|
+
Claude Code is detected automatically via its `claude-cli/*` User-Agent.
|
|
509
|
+
Requests flow through the Claude Code adapter which:
|
|
510
|
+
|
|
511
|
+
- Parses the client's real working directory from its `Primary working directory:` system-prompt line so Claude answers path-related questions with your local path, not the proxy host's.
|
|
512
|
+
- Leaves the SDK subprocess cwd on the proxy host (Claude Code's local paths don't exist there).
|
|
513
|
+
- Runs in passthrough mode by default — Claude Code executes its own tools on the machine it runs on; Meridian just forwards tool_use blocks.
|
|
514
|
+
|
|
486
515
|
### Any Anthropic-compatible tool
|
|
487
516
|
|
|
488
517
|
```bash
|
|
@@ -502,6 +531,7 @@ export ANTHROPIC_BASE_URL=http://127.0.0.1:3456
|
|
|
502
531
|
| [Aider](https://github.com/paul-gauthier/aider) | ✅ Verified | Env vars — file editing, streaming; `--no-stream` broken (litellm bug) |
|
|
503
532
|
| [Open WebUI](https://github.com/open-webui/open-webui) | ✅ Verified | OpenAI-compatible endpoints — set base URL to `http://127.0.0.1:3456` |
|
|
504
533
|
| [Pi](https://github.com/mariozechner/pi-coding-agent) | ✅ Verified | models.json config (see above) — requires `MERIDIAN_DEFAULT_AGENT=pi` |
|
|
534
|
+
| [Claude Code](https://docs.anthropic.com/en/docs/claude-code) | ✅ Verified | `ANTHROPIC_BASE_URL` — remote clients share a Max subscription over the network; client CWD preserved in system prompt |
|
|
505
535
|
| [Continue](https://github.com/continuedev/continue) | 🔲 Untested | OpenAI-compatible endpoints should work — set `apiBase` to `http://127.0.0.1:3456` |
|
|
506
536
|
|
|
507
537
|
Tested an agent or built a plugin? [Open an issue](https://github.com/rynfar/meridian/issues) and we'll add it.
|
|
@@ -779,7 +809,7 @@ You haven't run `meridian setup`. Without the plugin, OpenCode requests won't ha
|
|
|
779
809
|
|
|
780
810
|
## Contributing
|
|
781
811
|
|
|
782
|
-
Issues and PRs welcome. Join the [Discord](https://discord.gg/
|
|
812
|
+
Issues and PRs welcome. Join the [Discord](https://discord.gg/jP2a2Z92NZ) to discuss ideas before opening issues. See [`ARCHITECTURE.md`](ARCHITECTURE.md) for module structure and dependency rules, [`CLAUDE.md`](CLAUDE.md) for coding guidelines, [`E2E.md`](E2E.md) for end-to-end test procedures, and [`MONITORING.md`](MONITORING.md) for understanding token usage and prompt cache health.
|
|
783
813
|
|
|
784
814
|
## License
|
|
785
815
|
|