插件目录 / Developer / dsh-hotplug-engine
dsh-hotplug-engine
已验证 · 实测可装 AnothetLoice
功能简介
DSH的插件安装、回滚和审计服务
可用 — 实测通过,早期项目
DSH的插件安装、回滚和审计服务 实测能干净安装、正常启动。早期项目,但功能可用。
「已验证」表示我们的自动化 CI 在干净 profile 里实际执行了 dsh plugin add 并启动成功——仅此而已。功能描述与版本兼容性均为作者声明。这不是安全审计,也不代表对第三方代码的背书。
README
dsh-hotplug-engine
给 DSH 做插件管理的服务插件。市场、agent、其他插件都能调用:安装、卸载、启停、回滚、审计,一条链路。
做什么
DSH 用 cordis.patch.yml 和 loader 管理插件。这个插件把这套操作包成服务:改 patch、调 pnpm、装后健康确认、失败自动回滚、全程审计。只动文件和命令,不碰内核。
不做什么
- 不是市场:没有目录、搜索、榜单、推荐。
spec(装什么、从哪装)由调用方给,引擎不猜。 - 不改官方机制:HMR、loader、patch 语义都是官方的,只消费,不重写。
- 不另存状态:以官方组合树为唯一真源,引擎只投影和差分。
- 不带安装界面:UI 只有最小管理面板(查看、启停、回滚、审计),没有 spec 输入。
接入方式
| 场景 | 入口 |
|---|---|
| 市场 / 插件管理界面 | 注入 hotplugEngine 服务,或调 REST |
| agent 会话 | hotplug_* 工具 |
| 宿主插件 | 注入 hotplugEngine |
安装
pnpm --dir <profile-dir> add dsh-hotplug-engine
# 或 dsh plugin add dsh-hotplug-engine
bundle 包:装/卸后重启 profile;新客户端面板刷新页面加载。
上手
- 宿主注入:
inject: ['hotplugEngine'],调ctx.hotplugEngine的install/rollback/enable等方法,Promise resolve 即操作完成。 - REST:前缀
/api/dsh-hotplug,同源。写:install/uninstall/enable/disable/rollback;读:snapshot/status/audit/operations/events(SSE)。 - 工具:
hotplug_status/hotplug_install/hotplug_uninstall/hotplug_toggle/hotplug_rollback/hotplug_audit,写工具走审批。
完整契约见 docs/01-contract.md。
License
MIT
安装
装一次目录插件,之后本站所有插件都能让 DeepSeek Harness 自动找、自动装:
dsh plugin add dshbase-catalog 然后对 agent 说「帮我装 dsh-hotplug-engine」,它会在目录里找到并自动安装。文档:dshbase-catalog · 已验证场景包。
Web profile:
dsh plugin --profile web add dsh-hotplug-engine Headless(CLI)profile:
dsh plugin --profile headless add dsh-hotplug-engine 包信息
npm:dsh-hotplug-engine · 版本 0.1.3 · 实测环境 dsh 0.1.0-rc.6
实测报告
端到端验证通过:dsh 0.1.0-rc.6 上 L1 安装 + L2 加载 + L3 运行问答。
使用场景
扩展 agent 的编码能力面——给它一个新工具、工作流或集成,让它接手以前做不了的开发任务。
适合谁
想让 dsh 在真实代码库上像队友一样干活的开发者——能改、能跑、能验证,而不只是回答问题。
二次开发建议
工具/命令面就是缝:暴露更多 SDK 能力、加更聪明的上下文接线,或收紧改代码与验证之间的循环。