dsh-message-branch
Manifest validEdit plain-text user prompts inline and resend them in a new DSH conversation branch.
DSH Message Branch · 原位编辑提问
预览版 / Preview。在 DeepSeek Harness 的用户消息复制按钮旁添加铅笔入口,原位修改纯文本提问,并从该消息之前创建新分支重新发送。原会话保留,不改写历史日志。
Inline editing for plain-text user prompts in DeepSeek Harness. Save into a new conversation branch while preserving the original conversation. This is a preview: UI behavior and mocked lifecycle tests have been checked, but real-model fork-and-send end-to-end validation is not yet complete.
使用
- 点击用户消息复制按钮旁的铅笔。普通消息及运行期间追加、已进入历史的消息都提供入口。
- 在原消息位置修改文字,按 Esc 或点击「取消」恢复显示。
- 等原会话停止、待处理队列清空,再点击「保存并重新生成」,或按 Ctrl/⌘ + Enter。
- 插件创建新会话分支并发送修改后的文字,随后打开该分支。新分支可能产生模型调用费用。
安装与兼容性
本仓库包含可直接加载的客户端 bundle,无安装期脚本,也无需编译。
- 已验证界面环境:DSH
0.2.1-rc.5,Windows 桌面版;不声明对其他版本的兼容保证。 - Node.js
>=22.19.0,使用宿主 React18.3.x。 - 本地安装:
dsh plugin add /absolute/path/to/this/repository。 - 发布的 GitHub Release 如含
.tgz,可下载后使用dsh plugin add /absolute/path/to/package.tgz安装。 - 不需要 npm 账号或额外 API Key。发送使用 DSH 当前配置的模型。
- 不建议与其他覆盖用户消息渲染的插件同时启用;禁用本插件后恢复宿主原生渲染。
安全边界与已知限制
- 目前只支持纯文本。带图片、文件或其他非文本块的消息会显示限制,禁止保存,不会悄悄丢弃附件。
- 运行中、待处理队列非空、会话未就绪时禁止提交。
- 缺失前序事件时需先加载历史;替换事件暂不支持。
- 使用官方
sessions.fork的精确事件前缀边界。原消息及其后的历史不直接作为新分支前缀。 - 不撤销已经执行的文件修改、命令、网络请求等外部副作用。
- 不提供历史删除、恢复功能,不直接改写会话文件。
- 分支或发送结果不明确时不自动重试;已经创建的分支会保留入口供检查,防止重复发送。
- 无遥测、无凭据收集、无第三方请求。仅通过宿主会话服务发送用户编辑的文字;复制按钮按用户点击写入剪贴板。
实现
通过正式 conversation.chat.node Slot 覆盖 user / steering 的外围渲染,并复用官方 conversation.chat.user.content 内容工厂。没有 DOM 扫描、MutationObserver 或 CSS 哈希选择器,不改皮肤或壁纸。尚未进入历史的 pending 消息继续由宿主管理。
Host 入口 lib/index.js 为空 ESM 插件;浏览器入口 lib/client.js 使用 __ModuleLoader__。声明 dsh.bundle.patch 与 dsh.client.platform,以支持标准插件安装。
验证
npm test
npm run check
当前 16 项模拟接口测试通过,覆盖分支边界、原位取消/保存、防重复提交、重挂载、失败恢复入口、运行状态复核、附件保护、两类用户消息入口、自适应高度及右对齐结构。
已在桌面 GUI 验证铅笔入口、原位编辑、取消、禁用状态、图片与气泡对齐。上述测试不等于真实模型 fork/prompt 端到端验收;建议先在不含敏感信息的测试会话中试用。遇到问题请提供 DSH 版本、操作步骤和脱敏截图,不要提交令牌或私人会话日志。
License
MIT,见 LICENSE。
Comments
Loading…
Similar plugins
by Arbeiter-bit
Double-click any of your own messages to rewrite it and resend from that point; the original conversation is untouched.
★ 1
MIT
JavaScript
Oct 10, 2026
dsh plugin --profile web add dsh-reeditMessage and attachment editing with save-only updates, forked regeneration, and a version timeline for DSH desktop.
★ 3
MIT
JavaScript
dsh plugin --profile web add @sh1robana/dsh-plugin-message-editby iStarryDust
编辑重发:在用户消息气泡上多一个「编辑」,改完从那条消息重新生成
★ 0
MIT
JavaScript
Oct 27, 2026
dsh plugin --profile web add @istarry/dsh-edit-regenby Moeblack
DSH 插件:分支式消息编辑、重掷、重试与版本时间线 | DSH plugin: branch-based message editing, reroll, retry, version timeline
★ 53
↓ 752/wk
TypeScript
Aug 16, 2026
dsh plugin --profile web add dsh-message-editby Branwen050
消息编辑铅笔:编辑助手回复并从该回合分叉出新版本会话 / Edit assistant replies by forking a new session version
★ 0
JavaScript
Oct 26, 2026
dsh plugin --profile web add dsh-pencilby SpookySandwich
DSH 消息编辑插件:编辑已发送的消息并从该处分叉对话,气泡下方带版本计数与树状视图。Edit a sent message and branch from that point — version counter, tree view, placement presets.
★ 30
↓ 251/wk
NOASSERTION
JavaScript
Oct 30, 2026
dsh plugin --profile web add dsh-plugin-message-edit