dsh-scope-plugins
Manifest validSet plugins on or off per workspace and conversation, with inheritance and saved archives. Its HTTP routes have no DSH access check, so a web page open in your browser could call them.
插件分区系统 · Plugin Scopes
Switch plugins on or off per workspace and per conversation, with inheritance from parent scopes, master switches, saved archives, and a sidebar panel to inspect the current scope.


English
What it does
DSH keeps plugin activation at the profile level, so this plugin works one level below it: it decides, per agent (one agent per conversation), which tools each plugin contributes remain visible to the model, and applies that through agent.ctx.tools.restrict() on agent/created (plus a backfill for already-running agents). The result is per-conversation isolation for tool-carrying plugins without touching the profile.
- Inheritance — each scope (global → workspace → nested workspace → conversation) has a slider:
0starts from the global default and ignores parents;1…nstacks the nearest n parent layers, then applies this scope's overrides;-1("do not inherit") starts blank.- Unset scopes default to
1(follow the nearest parent). - Workspace nesting is derived from directory containment, because DSH workspaces are a flat list.
- Master switch — turn everything on or off for the scope in one click; the switch shows "follow inheritance" when no master state is set.
- Archives — save the current scope's inheritance depth, master state and per-plugin overrides as a named archive; restore, rename or delete it later. Archives never change which plugins are installed.
- Display settings — show hidden entries and historical (uninstalled) plugins, then reveal or hide each one from the list.
- Plugin list — Chinese/English title, one-line description, the tools the plugin registers and a per-scope switch. Plugins without tools (wallpaper, skins, pure UI services) are marked global: DSH offers no per-session way to unload them.
Where to open it
- Left sidebar → 插件分区系统 / Plugin Scopes panel; the dropdown selects the scope (global / workspace / conversation).
- Right sidebar → "new tab" guide → the plugin card opens the current conversation's scope.
- Every conversation gets its own right-sidebar tab layout, as usual.
Data
- State:
$DSH_HOME/storages/scope-plugins/<profile>.json(separate per profile). - Host HTTP API (same origin):
GET /scope-plugins/api/state?scope=global|workspace:<id>|session:<id>POST /scope-plugins/api/rule,/archive,/display,/install
Install
Install from the DSH plugin market (search 插件分区系统 / Plugin Scopes), or point plugin_manager's install_bundle at this repository directory. After changing code: reload the host plugin (include:scope-plugins off/on in the plugin manager) and refresh the page.
Limits
- Only installed plugins can be switched; removed plugins become "history" and can be reinstalled from display settings.
- Inheritance follows workspace directory containment and
parentSession, not workspace pin/recency order. - Switching applies to later turns; conversation history is untouched.
- Plugins without tools cannot be isolated per conversation.
License
MIT
中文说明
按工作区和对话独立开关插件,支持从上级继承、全开全关、插件存档,并在侧边栏查看当前作用域的启用情况。
做了什么
DSH 的插件启停本身是 profile 级,本插件在其下一层工作:在 agent/created(并对已有 agent 回填)时,用 agent.ctx.tools.restrict() 决定每个会话里各插件贡献的工具是否对模型可见,从而实现按会话隔离,而不改动 profile。
- 继承:每个作用域(全局 → 工作区 → 嵌套工作区 → 对话)有一个滑块:
0从全局默认开始,不读上级;1…n叠加最近 n 层上级设置,再应用本层覆盖;-1(不继承)从空白起算;- 未设置的层默认
1(跟随最近上级); - 工作区的嵌套关系按目录包含推导(DSH 的工作区是扁平列表)。
- 全开 / 全关:一键开关本作用域全部插件;未设置时显示“跟随继承”。
- 插件存档:把当前继承档位、全开关状态和单插件覆盖存成命名存档,之后可恢复、重命名、删除;存档不改变插件的安装状态。
- 显示设置:显示已隐藏项与历史(已卸载)插件,再决定哪些出现在列表里。
- 插件列表:中文名、一句话介绍、涉及的工具名、右侧开关。没有工具的插件(壁纸、皮肤、纯 UI 服务)标“全局”,因为 DSH 没有按会话卸载它们的手段。
入口
- 左侧栏「插件分区系统」面板:下拉切换作用域(全局 / 各工作区 / 各对话)。
- 右侧栏「新标签页」指南里的卡片:点开即当前对话的作用域。
- 每个对话各自一份右侧栏布局。
数据
- 状态文件:
$DSH_HOME/storages/scope-plugins/<profile 名>.json(按 profile 分隔)。 - 宿主 HTTP API(同源):
GET /scope-plugins/api/state?scope=global|workspace:<id>|session:<id>POST /scope-plugins/api/rule、/archive、/display、/install
安装
从 DSH 插件市场安装(搜索「插件分区系统」/ Plugin Scopes),或用 plugin_manager 的 install_bundle 指向本仓库目录。改代码后:在插件管理器里把 include:scope-plugins 关一次再开,然后刷新页面。
限制
- 只有已安装的插件能被开关;卸载后条目进入“历史”,可在显示设置里重新安装。
- 继承只沿工作区目录包含关系与
parentSession推导,不感知收藏/置顶顺序。 - 开关影响后续轮次,不改变会话历史。
- 无工具的插件无法按对话隔离。
许可
MIT
Comments
Loading…
Similar plugins
by Zenjibad
Enables or disables DSH plugins from Settings → Plugins: each toggle stops or starts the plugin immediately without a restart and the change persists across restarts.
★ 1
↓ 51/wk
MIT
TypeScript
Aug 28, 2026
dsh plugin --profile web add dsh-plugin-toggle为模型展示交付成果和下达精细微调指示的dsh desktop面板
★ 0
MIT
JavaScript
dsh plugin --profile web add dsh-plugin-middle-panelby 1959377950-dotcom
DSH Web plugin: Archive-All action on every workspace folder menu in the sidebar (Ungrouped included). Running / open / blank / subagent sessions are skipped.
★ 0
MIT
JavaScript
Sep 23, 2026
dsh plugin --profile web add dsh-workspace-archive-allby zjuatri
A DSH browser sidebar plugin with an isolated Chrome profile for every conversation, live interaction, and agent automation.
★ 0
JavaScript
Sep 16, 2026
dsh plugin --profile web add dsh-browser-pluginby WSGsety
DSH web plugin manager — enable/disable installed plugins from Settings. · DSH 网页插件管理:设置页直接启停已安装插件。
★ 0
MIT
JavaScript
Aug 15, 2026
dsh plugin --profile web add @wsgsety/dsh-plugin-managerby WhatCannotBeSaid
A "Disable unofficial plugins…" button for the DSH Plugins page: it opens a checklist of the unofficial plugins in the current direction (all checked by default) and toggles only the ones you keep checked. Once everything is off it flips to enabling them again. Never uninstalls.
★ 0
MIT
JavaScript
Oct 4, 2026
dsh plugin --profile web add dsh-disable-unofficial-plugins