DeepSeek Harness Plugin Hub

发布与管理完整 Harness Profiles,发现适合你的插件。

探索

插件目录环境预设文档中心动态

社区

发布插件联系我们报告问题

相关链接

Plugin Hub GitHubDeepSeek Harness 官方项目系统状态隐私说明
© 2026 DeepSeek Harness Plugin HubPowered byPaxTech

独立、非官方社区项目,与 DeepSeek 官方无隶属、授权或背书关系。

DeepSeek Harness Plugin Hub
ProfilesPlugins分类动态文档登录管理 Profiles
ProfilesPlugins分类动态文档登录
← Plugins
O

dsh-openrouter-sync-models

Openrouter Sync Models

使 DeepSeek Harness OpenRouter 模型列表与 OpenRouter 目录保持同步,包括账户预设

插件会安装到这里;不确定时保持 web。

npx -y @deepseek-ai/dsh plugin --profile web add github:m1khal3v/dsh-openrouter-sync-models#e147a0db5280b5cdacce6316bbd76fb3b650fd43
README兼容性版本

兼容性与来源证明

Openrouter Sync Models 以 dsh-openrouter-sync-models 发布,当前版本为 0.1.7。Plugin Hub 会校验它的 manifest,并保存精确安装来源,便于复现安装结果。

DSH 兼容范围
*
运行环境
any
发布来源
github
Registry 更新时间
2026/11/2

版本

0.1.7stable
2026/11/2

相关插件

正在加载相关插件…

最新版
0.1.7
DSH
*
HMR
重启进程
Tree shaking
未声明可安全裁剪
解包体积
未提供
文件数
未提供
Surface
any
许可证
MIT
发布源
github
GitHub
★ 1
周下载
0
最近提交
2026/11/2
查看源码 ↗
README Badge

点击下方 Badge 复制 Markdown,粘贴到 README 即可。

这是你的 Plugin?认领权益 · 优先安全扫描

验证 package.json 声明的 GitHub 仓库,即可管理这个公开页面。认领后,Hub 会优先安排当前版本的安全扫描,并在通过后公开展示结果。

认领这个 Plugin →
报告问题

相关插件

继续浏览 models-usage 分类下经过校验的插件。

Experimental Cot Translation Bundle@deepseek-ai/dsh-experimental-cot-translation-bundle扩展推理的实验性机器翻译Whale Widgetdsh-whale-widgetDSH Web 界面右下角的 DeepSeek 余额小鲸鱼挂件:余额/今日已用/峰谷定价、自定义泡泡点击序列(文本/余额/今日/峰谷/图片/随机语句与并列加权选择)、逐行样式与字体、悬浮快捷编辑、音效与每轮消耗、自定义角色/动图/音效、吸附与翻转自定义Our Free Model@ebony-vinyl/dsh-our-free-modelOur Free Model — 在 dsh 里装上这个插件即可,无需登录、注册或填 API Key,就能使用包括 DeepSeek V4.1 Flash、Kimi K3 在内的前沿模型,桌面端另有 EAC 协付渠道;2.0 起接入 LobsterAI、Qoder、TRAE、Cline、Loomy、Raccoon、MiniMax、ZCode、Gemini 十个账号渠道(原有匿名免费通道保留)(登录、账号池、积分领取、本地 OpenAI 网关与局域网转发、数据看板与运行日志),六页毛玻璃界面统一呈现。Connect Workbuddydsh-connect-workbuddy把本机登录的 WorkBuddy 模型(国内版与国际版)接入 DeepSeek Harness:每次刷新按上游目录自动读取每个模型的积分倍率,支持逐模型图片输入开关、多账号切换与账号池自动换号,并提供每日签到、卡片与输入框里的胶囊积分读数等只读积分概览。

README

dsh-openrouter-sync-models

An always-current OpenRouter model catalog for DeepSeek Harness.
Keeps the llm-pi-ai OpenRouter route in sync at startup, every six hours, and whenever your key changes — including account-only @preset/... models.


⚡️ Highlights

  • 🔐 Authenticated catalog — uses your OpenRouter token, so custom presets and account-specific models are included, not just the public list.
  • 🧩 One plugin, every surface — desktop, web, and CLI. It discovers the route through ctx.llm and writes through ctx.settings, with no profile paths or build-mode branches.
  • 🧼 Zero YAML surgery — no regex, no DSH_HOME, no DSH_PROFILE, no backups or status files. DSH owns atomic writes, revision checks, and HMR.
  • 🎛 Useful by default — tool-capable, text-output, chat-reachable models only. Presets on, paid and free models both included.
  • 🧠 Detail-aware mapping — capacities, input modalities, reasoning efforts, and evidenced compatibility flags are projected into the model profiles.
  • 📡 Observable — structured ctx.logger diagnostics plus a live openrouter/models-synced event.

🛠 How It Works

OpenRouter              Sync Plugin               Settings (Patch)                llm-pi-ai
    │                         │                           │                             │
    │                         │ GET /api/v1/models        │                             │
    │◄────────────────────────│ (resolves token)          │                             │
    │ (Bearer token)          │                           │                             │
    │                         │                           │                             │
    │ JSON Catalog Array      │                           │                             │
    │────────────────────────►│                           │                             │
    │                         │ ctx.settings.mutate()     │                             │
    │                         │──────────────────────────►│                             │
    │                         │ (filtered & projected)    │                             │
    │                         │                           │ DSH persists &              │
    │                         │                           │ validates patch             │
    │                         │                           │─────────────────┐           │
    │                         │                           │                 │           │
    │                         │                           │◄────────────────┘           │
    │                         │                           │                             │
    │                         │                           │ Applies live via HMR        │
    │                         │                           │────────────────────────────►│
  1. The plugin finds the openrouter route through ctx.llm.listConfigurableProviders().
  2. It resolves the route's apiKeyEnv through ctx.credentials and requests the authenticated catalog.
  3. The response is filtered and projected into DSH model profiles.
  4. Only api and models are written, through ctx.settings.mutate().
  5. DSH persists the active profile patch, validates the result, and applies it live through HMR.

No restart is needed for model updates.


🚀 Quick Start

1. Install the plugin

dsh plugin --profile <profile> add dsh-openrouter-sync-models

<profile> is the profile directory name under $DSH_HOME/profiles/<name>. Install the plugin into every profile you actually boot.

<profile>What it runsHow to install
webShipped browser surface, booted by dsh web or dsh --profile webdsh plugin --profile web add dsh-openrouter-sync-models
headlessShipped one-shot CLI, booted by dsh --profile headless "job"dsh plugin --profile headless add dsh-openrouter-sync-models
sdkShipped SDK host over JSON-RPC stdiodsh plugin --profile sdk add dsh-openrouter-sync-models
sdk-minimalShipped minimal SDK agent treedsh plugin --profile sdk-minimal add dsh-openrouter-sync-models
acpShipped ACP stdio hostdsh plugin --profile acp add dsh-openrouter-sync-models
desktopElectron-owned desktop profileUse the app's Plugins page, or the desktop-installed dsh command. The npm CLI rejects plugin management for desktop.
<name> (custom)Any other profile directoryInitialize it with dsh --profile <name> --from-default-profile web (or another shipped template), then install the plugin into it.

The shipped web, headless, sdk, sdk-minimal, and acp profiles initialize automatically on first use. A custom profile name is just a directory under $DSH_HOME/profiles/, so the same plugin can be installed independently into several profiles.

If a profile omits the settings or credentials services, the plugin still loads but leaves synchronization inactive.

Or from a local checkout:

pnpm install
pnpm run build
dsh plugin --profile <profile> add file:~/projects/mine/dsh-openrouter-sync-models

2. Configure the OpenRouter route

The plugin only writes api and models; the route itself stays user-owned:

- id: llm-pi-ai
  name: '@deepseek-ai/dsh-llm-pi-ai'
  config:
    providers:
      openrouter:
        apiKeyEnv: OPENROUTER_API_KEY
        # api and models are maintained by dsh-openrouter-sync-models

3. Provide the key

Store OPENROUTER_API_KEY through the harness credential store, the environment, or the profile's credential layer.

The catalog endpoint is public, but the authenticated response is the one that contains @preset/... models. Without a key the plugin skips the pass by default rather than deleting every preset.


⚙️ Configuration

Every field is optional.

KeyDefaultDescription
provideropenrouterllm-pi-ai provider route to synchronize
endpointhttps://openrouter.ai/api/v1/modelsCatalog endpoint
apiopenai-completionsRoute-level wire protocol written beside the list
apiKeyEnvOPENROUTER_API_KEYCredential reference used when the route names none
requireKeytrueSkip when the credential cannot be resolved
includePresetstrueInclude account-specific @preset/... models
freeOnlyfalseKeep only zero-priced models
requireToolstrueKeep only models advertising tool calling
requireTextOutputtrueKeep only plain-text output models
requireChatEndpointtrueDrop :batch entries with no chat endpoint
minContextWindow0Minimum advertised context in tokens
maxOutputTokens0Clamp a known output cap; 0 keeps the advertised value
excludeModels[]Exact model ids to leave out
intervalHours6Refresh interval
timeoutMs45000HTTP timeout
startupGraceMs30000How long startup waits for the provider directory

Example override:

- id: openrouter-sync-models
  name: dsh-openrouter-sync-models
  config:
    freeOnly: true
    minContextWindow: 64000
    excludeModels:
      - openrouter/auto

With the defaults, a 2026-11-02 authenticated sample of 416 catalog entries yields roughly 305 models, including account presets. Set freeOnly: true to reproduce the old free-only behavior.


🧬 What Gets Mapped

OpenRouter fields are projected into the subset DSH can actually serve:

OpenRouterDSH
idid
namename
min(context_length, top_provider.context_length)contextWindow
top_provider.max_completion_tokensmaxTokens
architecture.input_modalitiesinput (text/image only)
reasoning.supported_effortsreasoningEfforts
reasoning.mandatoryremoves the off level
supported_parametersselected compat flags

A field OpenRouter omits stays omitted. In particular, when max_completion_tokens is absent, maxTokens is not written: pi-ai falls back to the installed catalog entry and then to the route default exactly as it does for a hand-written profile.

Compatibility switches are only declared when evidenced:

  • thinkingFormat: 'openrouter' for chat models
  • maxTokensField: 'max_tokens' when the model accepts max_tokens but not max_completion_tokens
  • supportsStrictMode: true when structured_outputs is advertised
  • cacheControlFormat: 'anthropic' for Anthropic-backed entries, including presets identified by canonical_slug
  • supportsDeveloperRole: true for OpenAI/Anthropic-backed entries
  • requiresReasoningContentOnAssistantMessages: true for DeepSeek-backed entries

DSH has no model-config field for OpenRouter description, pricing, benchmarks, default_parameters, voices, links, or alias_target, so those are intentionally not projected.


🧠 Behavior & Good to Know

  • Strict refresh policy. Within one host process the catalog refreshes on exactly three triggers:
    • the startup pass;
    • a change of the route's own OpenRouter credential;
    • the periodic pass six hours after the last completed attempt.
  • No event storms. HMR, settings, adapter, plugin-manager, and profile-reload events do not start a catalog request.
  • Startup waits for both halves. The first pass waits for the provider directory entry and the active llm-pi-ai settings descriptor, gives the loader and its network/proxy plugins one second to settle, then retries briefly (0 → 1 → 3 → 10 s) on target-ordering skips, settings-write races, or a transient fetch failed. This prevents an install-time pass from sleeping until the next interval.
  • Credential pass runs only when the exact route reference (apiKeyEnv, then the configured fallback) changes. Updates are debounced, and a change during a running pass queues at most one follow-up.
  • Periodic pass is rescheduled six hours after every completed attempt; it is never overlapped with another pass.
  • Install/update writes survive HMR. The first timer is created outside the HMR transaction's AsyncLocalStorage context, so the settings write queues behind the active reconciliation instead of failing with HMR transactions cannot be nested. The route and settings revision are then re-read after the catalog fetch, and a transient SETTINGS_CONFLICT or reload race is retried with the fresh revision before the pass is reported as failed.
  • Empty results are never written. Network errors, 401/403, empty catalogs, revision conflicts, and validation failures leave the profile untouched.
  • modelOverrides is respected. If the route uses modelOverrides, the plugin skips it because DSH refuses models beside modelOverrides.
  • Route ownership matters. The route should come from the profile patch or a layer beneath it. A higher-priority home or command-line patch blocks the write; the plugin reports the failure without changing anything.
  • Do not run dsh-openrouter-sync beside this plugin. Both target the same models list.
  • OpenRouter OAuth: the synchronizer resolves apiKeyEnv. A route authenticated only through pi-ai's OAuth record has no environment reference; configure apiKeyEnv for catalog synchronization even if inference signs in interactively.

Observability

Logs go through:

ctx.logger('openrouter-sync-models')

Every attempt, including a skip, also writes its last terminal report to:

$DSH_HOME/cache/openrouter-sync-models.json

The record includes at, trigger, attempt, status, and reason, which answers “did the install-time pass run, and if not, why” even when the desktop build sends stdout to /dev/null. A failure also carries the provider or settings error message in detail; network failures include the nested cause (ENOTFOUND, ECONNRESET, CERT_HAS_EXPIRED, …) instead of a bare fetch failed.

Model changes are also published as a live event:

ctx.on('openrouter/models-synced', report => {
  // report.status: updated | unchanged | skipped | failed
  // report.reason: stable reason for a skip/failure
  // report.added / report.removed: model ids
})

The event never enters the session log.


🧑‍💻 Development

pnpm install
pnpm run verify    # typecheck + tests
pnpm run build

lib/ is generated by tsdown; declarations come from tsc -p tsconfig.types.json.

The package publishes through GitHub Actions on v* tags with npm provenance. Before the first release tag, configure the package's npm Trusted Publisher for the m1khal3v/dsh-openrouter-sync-models repository and the release.yml workflow. The workflow uses OIDC and stores no npm token.

📄 License

MIT