Back to home

penglai-doll

dsh-plugin-manager

Plugin management tab for the Web Plugins settings: manage agent presets (list/read/validate/copy/remove, per-row enable/disable) and the dynamic Cordis plugin inventory, through a same-origin /plugin-manager JSON API.

Stars
0
Language
JavaScript
Created
Aug 17, 2026
Updated
Aug 17, 2026

Introduction

dsh-plugin-manager

GitHub topics: dsh-plugin License: MIT

Bilingual 中英双语:English first, 中文译文在后。

English

Formal (composition-mounted) DeepSeek Harness plugin: a 插件管理 tab in the Web Plugins settings section that manages two plugin planes.

What it manages

  • Agent presets (agentPresets service): list, view composition text, mount-validate (standingKeyFor), duplicate (copy), delete (remove), and per-row enable/disable by disabled: true line surgery on a user preset's agent.cordis.yml. Shipped presets are read-only.
  • Dynamic Cordis plugins (dynamicCordisRunner service): frame-wide inventory and panel-driven stop (stopFromPanel).

Architecture

  • lib/index.js — Host half (plain ESM, no imports): injects agentPresets, webServer, dynamicCordisRunner, agents, fs; serves a same-origin JSON API under /plugin-manager/* via webServer.register (wrapped in ctx.effect, so teardown removes the routes).
  • lib/client.js — Client half: a hand-written web plugin bundle in the window.__ModuleLoader__.load({id, factory}) format; registers settings.plugins.tab (id manager) and calls the host API with fetch. Only module dependency: react.

Installation (web profile)

dsh plugin --profile web add <this-directory>

and add one row to the profile's cordis.patch.yml:

- insert:
    - id: plugin-manager
      name: 'dsh-plugin-manager'

Then restart dsh web. The row is both a host row and (via the dsh.client field in package.json) a browser roster row.

Trust

The /plugin-manager routes perform the same mutations the shipped settings pages offer, and are served on the same host/port as the Web UI with no additional auth. Keep this plugin on loopback hosts.


中文

正式(composition 挂载)的 DeepSeek Harness 插件:Web 插件设置里的一个 插件管理 标签页,管理两类插件平面。

它管理什么

  • Agent 预设agentPresets 服务):列出、查看组合文本、挂载校验(standingKeyFor)、复制(copy)、删除(remove),以及对用户预设的 agent.cordis.ymldisabled: true 行级启停。随附预设只读。
  • 动态 Cordis 插件dynamicCordisRunner 服务):全框架清单与面板驱动的停止(stopFromPanel)。

架构

  • lib/index.js — Host 半边(纯 ESM、无 import):注入 agentPresetswebServerdynamicCordisRunneragentsfs;通过 webServer.register 提供 /plugin-manager/* 同源 JSON API(包在 ctx.effect 里,卸载即移除路由)。
  • lib/client.js — Client 半边:window.__ModuleLoader__.load({id, factory}) 格式的手写 web 插件 bundle;注册 settings.plugins.tab(id manager),用 fetch 调用 host API。唯一模块依赖:react

安装(web profile)

dsh plugin --profile web add <this-directory>

并向 profile 的 cordis.patch.yml 加一行:

- insert:
    - id: plugin-manager
      name: 'dsh-plugin-manager'

然后重启 dsh web。该行既是 host 行,也(通过 package.json 里的 dsh.client 字段)是浏览器 roster 行。

信任

/plugin-manager 路由执行的是随附设置页本就提供的同类变更,且与 Web UI 同源同端口、无额外鉴权。请仅在 loopback 主机上使用本插件。