Horizon215/dsh-plugins--packages-mode-switcher ↗★ 9
@your-scope/dsh-mode-switcher
Collaboration-mode switcher: one-tap capsules above the composer flip the session between Plan (official), Review and Quick-Answer modes — adapted from OpenAI Codex's mode templates 适合需要在Plan、Review和Quick-Answer模式间快速切换的用户。
インストール
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:Horizon215/dsh-plugins#47c61d624358f92d2f229dd981ef3883ee2af6a1&path:packages/mode-switcherドキュメント
README 全文を読む ↗@your-scope/dsh-mode-switcher
One-tap collaboration-mode capsules above the composer — flip the session between Plan (the official plan mode), Review and Quick-Answer modes, with guidance adapted from OpenAI Codex's own mode templates. DeepSeek Harness Web UI 的「模式切换器」——输入框上方一排胶囊,一键在 Plan(官方)/ 审查 / 快答三种协作模式间切换。
Screenshots / 截图见仓库根 README:https://github.com/Horizon215/dsh-plugins
English
Features
- Mode capsules above the composer —
Plan·Review·Quick; click to switch, click again to leave. The active capsule stays lit. - Drives the official plan mode, not a reimplementation: the Plan capsule executes
/plan//plan offthrough the commands channel and reads the host-computedplanprojection (the official Plan chip, composer placeholder andexit_plan_modeflow all follow). On deployments without plan mode the capsule simply hides. - Two custom modes, adapted from OpenAI Codex's prompt assets (Apache-2.0):
- Review — from Codex's review rubric: read-only senior-reviewer stance, findings first, severity tags
[P0]–[P3], explicit "looks good" when nothing qualifies, one-line overall verdict. - Quick — from Codex's default collaboration mode: answer first, reasonable assumptions over clarifying questions, minimal tool calls, no edits unless asked.
- Review — from Codex's review rubric: read-only senior-reviewer stance, findings first, severity tags
- Log-only state — switching appends a
modeswitch/modesession event and the last one wins, exactly like the official plan mode: the mode survives reloads, resumes and forks, and other surfaces (CLI, another tab) agree with what you see. - Prompt-section injection — the active mode's guidance renders as the
modeswitch:policysystem-prompt section on every request (verifiable in the session log'srequest/header). - Slash command too —
/mode review,/mode quick,/mode off, or bare/modeto ask. Bilingual UI (zh/en) follows the app locale.
Install
From source (npm package coming soon):
git clone https://github.com/Horizon215/dsh-plugins.git
cd dsh-plugins
pnpm install && pnpm build
dsh plugin --profile web add file:./packages/mode-switcher
Restart dsh web. The package declares dsh.bundle, so it joins the profile automatically — no config edits.
Notes
- Requires dsh ≥
0.1.0-rc.5, web UI only. - This is a hybrid plugin: the host half registers the
/modecommand and the prompt section; the browser half is just the capsule bar. The host half has zero runtime imports — everything goes through cordis services. - Custom-mode guidance is English (matching the deployment's other prompt sections); the model still mirrors your language in replies.
- Plan and a custom mode can be active at once (e.g. plan + review); they're independent layers, same as upstream.
Uninstall
dsh plugin --profile web remove @your-scope/dsh-mode-switcher
中文
功能
- 输入框上方的模式胶囊 ——
Plan·审查·快答,点一下切换,再点一下退出,激活胶囊常亮。 - 驱动官方 Plan 模式而非重造:Plan 胶囊通过命令通道执行
/plan//plan off并读取宿主计算的plan投影(官方 Plan 芯片、输入框占位文案、exit_plan_mode流程全部跟随)。部署里没有 plan 模式时该胶囊自动隐藏。 - 两个自定义模式,改编自 OpenAI Codex 的提示词资产(Apache-2.0):
- 审查 —— 源自 Codex 的审查 rubric:只读的高级审查员立场,发现优先、按
[P0]–[P3]严重度标记、没有合格发现就明说"看起来没问题"、结尾一行总体结论。 - 快答 —— 源自 Codex 的默认协作模式:先给答案、合理假设优于追问、最少工具调用、不让改就不改。
- 审查 —— 源自 Codex 的审查 rubric:只读的高级审查员立场,发现优先、按
- 状态只落在日志 —— 切换即追加
modeswitch/mode会话事件、最后一条生效,与官方 plan 模式同一架构:刷新、恢复、分叉后模式都在,其他端(CLI、另一个标签页)看到的状态一致。 - 提示词段注入 —— 激活模式的指导作为
modeswitch:policy系统提示词段出现在每次请求里(可在会话日志的request/header中验证)。 - 也支持斜杠命令 ——
/mode review、/mode quick、/mode off,或裸/mode查询当前模式。界面中英双语跟随应用语言。
安装
从源码安装(npm 包即将推出):
git clone https://github.com/Horizon215/dsh-plugins.git
cd dsh-plugins
pnpm install && pnpm build
dsh plugin --profile web add file:./packages/mode-switcher
重启 dsh web。包已声明 dsh.bundle,会自动加入 profile,无需改配置。
说明
- 需要 dsh ≥
0.1.0-rc.5,仅 Web UI。 - 这是一个混合插件:宿主半注册
/mode命令和提示词段,浏览器半只有胶囊条。宿主半零运行时导入——一切都走 cordis 服务。 - 自定义模式的指导文本是英文(与部署里其他提示词段一致);模型回复仍跟随你的语言。
- Plan 与自定义模式可以同时激活(例如 plan + 审查),二者是独立层,与上游一致。
卸载
dsh plugin --profile web remove @your-scope/dsh-mode-switcher