dsh-streaming-diff
Manifest validReplays the diff of the edit that just landed in a right-sidebar tab, revealing it line by line behind a moving scan line, with a second tab that lists every file the last round changed. What is repla
dsh-streaming-diff
简体中文 | English
在 DeepSeek Harness 的右侧栏复刻 VS Code 里 Cline 的流式 Diff。
伪实时:动画播的是刚写入的改动,不是模型的实时输出,但是体感上与实时输出几乎一致。
静态预览:查看回放结束时的差异结果。
早期的 Cline 会随模型输出更新 Diff;SDK 版的 Cline 则等编辑内容生成完,才开始播放写入前的 Diff 预览。
使用
- Streaming Diff:当前会话有新编辑就自动回放。下一次编辑会替换当前回放页,旧编辑不会重播。一次
apply_patch改了多个文件时,回放页最终只显示最后一个。 - 上一轮变更:从右侧栏的标签页列表打开。这里静态展示最近一个有文件改动的轮次,不必等该轮结束。同一文件改了多次,只显示最后一次编辑的 diff,不合并成整轮净改动。每个文件都能单独折叠。
两页都支持单栏或左右对比、自动换行和复制 diff 文本,沿用 DSH 的语法高亮。对话里原有的 diff 卡片不变。
安装
在 DSH 0.2.2-rc.1、Node.js 22+ 上测试过。无需手动修改 DSH 配置。
在源码目录打包:
npm pack --ignore-scripts
在 DSH 中打开 插件 → 安装插件,填入生成的 .tgz 文件的绝对路径。安装后刷新页面,再让当前会话改一个文件;如果没有出现 Streaming Diff,重启 DSH 服务后再试。
本地开发时,可以在源码目录用 link: 安装,不用反复打包:
dsh plugin --profile web add "link:$($PWD.Path)"
要卸载,在插件页移除 Streaming Diff,或运行 dsh plugin --profile web remove dsh-streaming-diff。
设置
在 设置 → Streaming Diff 中关闭 Diff标签页,可以让已折叠的侧栏保持关闭,新编辑仍会生成回放标签页。两页共用 Diff样式:默认 DSH,也可选 dsh、pure、cline 或 codex。界面语言跟随 DSH。
限制
- 由
apply_patch创建的新文件目前不会显示。 - 「上一轮变更」只看当前加载的会话记录,不提供历史轮次选择。最多显示 60 个文件,每个文件最多显示 400 行,超出时有提示。
- 行号和复制文本里的
@@坐标都是相对位置,不是文件里的实际行号。
开发
客户端入口 只读会话事件,优先用工具返回的 meta.diffs 计算行级差异。回放页响应新事件,「上一轮变更」则从已加载的记录整理出来。
npm test 测试 diff 计算、动画和宿主接入;npm run bench 单独测量 diff 算法的耗时和内存占用。
Comments
Loading…
Similar plugins
Adds a Reading tab to the DSH web client that shows process steps and live reasoning in source order, collapses successful turns to the final answer, and keeps the original tabs, composer, and tooling
★ 2
NOASSERTION
TypeScript
dsh plugin --profile web add dsh-clearviewby phoenixyun
Live streaming diffs for DSH file edits: a diff that grows while the model is still emitting the edit arguments.
★ 0
MIT
JavaScript
Nov 7, 2026
dsh plugin --profile web add dsh-plugin-live-diffdsh的diff审核
★ 1
MIT
JavaScript
dsh plugin --profile web add dsh-diff-reviewFolds streaming reasoning and tool calls into collapsed step bars and collapses each finished turn into a single summary bar; step bars show native tool icons, filenames, edited line counts, and failu
★ 0
dsh plugin --profile web add dsh-turn-foldby liyu6969
Right-sidebar panel that replays a file write or edit line by line as the agent produces it, with per-file tabs, a diff gutter and an optional animated character scene.
★ 2
MIT
JavaScript
Nov 18, 2026
dsh plugin --profile web add @local/dsh-code-liveby var-lin
Drag-and-drop reordering, official/third-party dividers and a stash panel for the buttons DSH renders in the sidebar, the sidebar footer, the conversation tabs, the composer dock and Settings. Only di
★ 1
MIT
TypeScript
Nov 6, 2026
dsh plugin --profile web add dsh-plugin-layout-organizer