返回目录

dsh-magpie-connector

精选清单收录维护状态: 活跃

prgrmrwy/dsh-magpie-connector

将自托管 Magpie 网关接入 DeepSeek Harness 作为模型服务,按上游分组显示模型和用量信息。

前往 GitHub项目主页
$ dsh plugin add dsh-magpie-connector

安装

dsh 没有统一的安装命令——把该插件 README 中的配置行加入你的 profile/patch 配置,然后重启即可。

了解安装方式

8

星标

4

Fork

TypeScript

语言

MIT

许可证

2026-10-27

创建于

2026-11-20

最近推送

README

dsh-magpie-connector

English · 简体中文

Model picker grouped by upstream provider: Magpie (Claude), Magpie (Codex) and Magpie (Deepseek)

Settings: the connection line on top, then models grouped by provider with visibility, default effort and usage cards

Sidebar usage card: one weekly row per upstream with readings and bars

Top: model picker — routing groups in their own Magpie (Routing) group, everything else grouped by upstream provider. Middle: Settings → Magpie, the Routing groups section (visibility, type and default reasoning effort). Bottom: the resident sidebar usage card (click its header to expand every window). Captured from an isolated DSH host (English UI) with a local mock Magpie gateway; gateway address, models, account and readings are synthetic.

Magpie connector architecture: Web GUI and Host plugin, credentials and settings, Magpie gateway and upstream providers, optionally through Cloudflare Access

Connect a self-hosted Magpie gateway to DeepSeek Harness with one provider route per upstream owner: models grouped by upstream provider on stock DSH, usage cards (you can spend a Codex reset from them), and a per-session fast mode. Magpie keeps managing logins, accounts, routing and provider egress; this plugin adds the DSH side.

Product direction: Make Magpie's usage information and existing model/routing entry points easier to consume from DSH. Account pools and routing strategies stay in Magpie. See product positioning and design boundaries.

What you get

Capability What it does
Gateway lines (basic) Each line has its own URL and gateway key. The model catalog comes from the gateway's GET /models; Responses-capable models use Responses, everything else uses Chat Completions. Text, tool round trips, images, usage, cancellation and DSH-managed retries go through.
Check a line before saving (0.4.0) Every line card has “Check line”: one real GET /models with that card's address, access mode and key (empty credentials fall back to the line's saved values), rendered as a read-only snapshot — result kind, latency, model count and, when the host has a cached catalog with a sync time, the model ids extra to or missing from that cache. It never changes the active line, writes credentials/settings, syncs the catalog or registers a route; the diff is against the cached catalog, so it never claims to match the current line.
Automatic multi-line failover (signature) Empty on first install; normally one line; add backup lines and let the order decide priority. Before every gateway operation the plugin picks the first reachable complete line with a ≤600ms TCP probe (10s positive / 15s negative in-memory cache, no background polling), so home uses the LAN while outside falls back to the public endpoint. Switching lines carries the catalog over (no flash), clears usage cards and re-syncs the new line; single-line users keep 0.1.x behavior.
Grouped by upstream provider (signature) Works on stock DSH, no Host extension needed: the plugin registers one real provider route per gateway owned_by (dsh-magpie-connector-claude, -codex, -opencode-go, …; missing or invalid ownership goes to -other), so the official model picker shows Magpie (Claude), Magpie (Codex), Magpie (Opencode-go), Magpie (Other) groups. Settings and usage cards use the same grouping, and a provider that only appears in usage is never dropped.
Routing groups (0.7.1) Magpie routing entries — custom groups (group/…) and auto-discovered groups (auto/…) — get their own Magpie (Routing) group in the picker instead of landing under their first member's vendor, and a 「Routing groups」 section at the top of Settings with visibility (its own 「Follow the gateway list」), type (custom / auto) and the default reasoning effort the gateway advertises. Entries are recognised by id prefix only. The plugin sends the group id as-is; Magpie picks the member, vendor and account (a group's effort may change which member serves). Create and edit groups in Magpie.
Line panel and latency Configured lines start collapsed; click a row header to edit it, and reorder/delete are always-visible DSH product-icon buttons with tooltips. Opening Settings measures every saved line with a parseable address once (parallel TCP connect time, ≤600ms per line, no HTTP, no credentials) and shows a 4-bar signal plus milliseconds; timeouts show a timeout reading and failures or older hosts degrade to a dash. Display-only: it never affects automatic line selection, is not persisted, and never polls.
Per-line Cloudflare Access Each line independently chooses Direct or Cloudflare Access. Access-enabled line requests carry the service token pair plus the bearer key; the token is never sent to a plain-HTTP line.
Usage cards Each upstream account shows plan, expiry, window readings and, when the gateway provides them, its Codex reset credits: a folded Usage limit resets · N available line that expands to each credit with its expiry and how far off the soonest is (expires in N days); plans that hand out one kind per window show 2 five-hour · 1 weekly in the summary instead. Cards are read once when settings open and only re-read when you press Refresh on that card; bars turn orange above 70% and red at 90%.

在 GitHub 阅读完整 README →

DSH Plugins 是独立的 DeepSeek Harness 插件目录,与 DeepSeek 官方无关,也不代表官方背书。第三方插件未经安全审计,安装前请审查源码。

每周获取最新的 DeepSeek Harness 插件,绝不滥发。