Skip to content

errorcode7/dsh-prompt-manager

50Last commit Aug 14, 2026

dsh-prompt-manager DSH plugin

dsh-prompt-manager turns DeepSeek Harness system prompts from black-box strings into manageable, auditable pipelines. It provides preset-based editing (replace/insert/remove sections), a canvas that shows the assembly process step by step, and agent tools for switching or saving prompts. Built as a DSH plugin using official extension points, it works with any Harness profile.

How to install the dsh-prompt-manager DSH plugin

dsh plugin --profile web add dsh-prompt-manager   # 发布到 npm 后

Copying does not run this command. Review the repository and version before installing the dsh-prompt-manager DSH plugin.

dsh-prompt-manager DSH plugin data source

dsh-prompt-manager DSH plugin snapshot date: Aug 16, 2026

discovered

What the dsh-prompt-manager DSH plugin can do

  • Manage system prompts as presets: save, switch, and edit prompt rules without touching YAML manually.
  • Visualize the prompt assembly pipeline: see source sections, preset overrides, variable interpolation, and final output on a canvas.
  • Control section order precisely: use top, anchor, or numeric order to place any section exactly where you want.
  • Audit historical rounds: review the last 20 real prompt assemblies with full context (variables, tools, user input).
  • Edit presets via a settings tab with a form-based editor (action, section, position, content).

Where the dsh-prompt-manager DSH plugin fits

  • Quickly switch between different writing styles (e.g., creative, technical) by toggling presets.
  • Debug prompt injection issues by inspecting the exact prompt sent to the model on a given round.
  • Audit which sections contributed to a system prompt and how they were overridden.
  • Develop and test new prompt sections without restarting Harness sessions.
  • Share prompt configurations across team members using preset files.

Who the dsh-prompt-manager DSH plugin is for

  • DeepSeek Harness users who want fine-grained control over system prompts.
  • Developers or prompt engineers who need to audit, version, and switch prompt setups easily.

dsh-prompt-manager DSH plugin limitations

  • Presets do not affect sections with `complete: true` in the registry; those sections override the entire prompt.
  • Presets apply globally to all sessions; per-agent overrides require separate mechanisms (agent preset or agent.ctx).
  • Preset changes take effect only on the next model step, not immediately in the current conversation.
  • Only works within DeepSeek Harness; not a standalone tool for other LLM frameworks.

dsh-prompt-manager DSH plugin: from the repository README

Quoted from the errorcode7/dsh-prompt-manager README, the upstream source of the dsh-prompt-manager DSH plugin. Copyright remains with the original authors.

把 DeepSeek Harness 的**系统提示词**从"黑盒字符串"变成**可视化、可配置、可审计**的流水线,方便精细化管理和学习提交到服务器的提示词: - 提示词由哪些段拼成、各段从哪来、最终发给模型的是什么,一目了然; - 用预设(preset)对任意段做替换 / 插入 / 删除,并**精确控制渲染顺序**(谁在前谁在后); - 幕布按真实模型步骤还原组装过程,支持回看历史轮次。 ## 界面预览 设置页「提示词管理」——预设列表、开关切换与表单化规则编辑器: ![设置页 · 提示词管理](docs/pic/1.png) 全屏幕布——提示词组装流水线(来源 → 覆盖 → 插值 → 最终): ![全屏幕布 · 组装流水线](docs/pic/2.png) 最终渲染结果展示——系统提示词渲染输出: ![最终渲染结果展示](docs/pic/3.png) ## 核心能力 围绕两个目标:**管理**提示词、**展示**提示词是怎么来的。 ### 管理:把系统提示词当"配置"管 - **一套方案 = 一个预设文件**:把一组提示词改动(新增/替换/删除某些段)存成一个预设。内置预设随插件分发(只读),你自己的存在 `$DSH_HOME/prompts/`。想换风格、想验证注入防御,开关一下,下一个模型步骤就生效;直接改文件也即时热重载。 - **可视化编辑,不用记 YAML**:一条规则 = 动作(做什么)+ 段名(对谁做)+ 渲染位置(放哪)+ 内容,四个字段正交。动作、位置都是下拉选择,段名从现有段里挑或自己写,锚点段同样可挑——不会配出"语法对但没效果"的组合。 - **精确控制顺序**:想让某段"压倒一切"就置顶,想让它跟在某段后面就选锚点,想精确插缝就给 order 数值。 ### 展示:把"黑盒字符串"变成看得见的流水线 - **幕布**:一次真实请求的提示词是怎么拼出来的——来源片段 → 预设覆盖 → 变量插值 → 最终系统提示词 → 完整请求(含消息与工具 schema),画布上一眼看到谁覆盖了谁、变量替换成了什么。 - **回看历史轮次**:最近 20 轮真实组装随时翻看,能对照"当时发给模型的是什么"。 ## 工作原理 Harness 的系统提示词本来就不是一整块文本:各插件用 `systemPrompt.section({ name, order, text })` 注册分段,组装时按 `order` 升序渲染、空段丢弃、以空行连接。本插件借这套机制的**扩展点**做"预设改写"和"组装观测",不碰注册表、不动其他插件——停用预设即可完全还原: | 我们的功能 | 借用的框架机制 | 实现方式 | |---|---|---| | 预设改写提示词 | 官方 `system-prompt/assemble

Read the full READMERepository license: MIT

dsh-prompt-manager DSH plugin questions

How do I install dsh-prompt-manager?

Run `dsh plugin --profile web add dsh-prompt-manager` in your terminal. If you're using a different profile, replace 'web' with your profile name. You can also install from a local source directory with `dsh plugin --profile web add /path/to/dsh-prompt-manager`. After installation, the plugin will appear in the Harness settings under 'Prompt Management'.

Where are the preset files stored?

Built-in presets (read-only) are located in the plugin's installation directory under `dsh-prompt-manager/presets/`. Your custom presets are stored in `$DSH_HOME/prompts/`, where `$DSH_HOME` is your Harness data directory. Each preset is a separate YAML file, and `active.yml` in the same directory specifies which preset is currently active (set to `null` to disable).

How do I switch between presets?

You can switch presets in two ways: (1) Use the agent tool `switch_prompt` in a conversation – just say 'switch to creative mode' and the plugin will handle it. (2) Manually edit the `active.yml` file in `$DSH_HOME/prompts/` and change the `active` field to the desired preset name (without .yml). The change takes effect on the next model step.

What is the 'canvas' and how do I use it?

The canvas is a full-screen view that shows the prompt assembly pipeline for a real request. It displays source sections, preset overrides, variable interpolation, the final system prompt, and the complete request (including messages and tool schemas). To access the canvas, look for a dedicated route registered by the plugin (likely a button in the settings or a direct URL). You can also view historical rounds (last 20 assemblies) by clicking on the round selector.

How do I disable the plugin completely?

To stop the plugin from affecting prompts, simply set `active: null` in `$DSH_HOME/prompts/active.yml` and save. All presets will be ignored, and the system prompt will revert to the default assembly without any overrides. If you want to remove the plugin entirely, run `dsh plugin --profile web remove dsh-prompt-manager`.