wang-xudong/dsh-plugin-undo

插件 ⭐ 1 MIT web-ui

DSH会话撤回插件:在当前会话内原地撤销最后n轮对话,不fork、不新建会话。

catalog 简介:DSH 会话撤回插件:在当前会话内原地撤销最后 n 轮对话,不 fork、不新建会话 | Undo the last n turns in-place in the current DSH session

安装

Click the header to expand or collapse that turn in place. The `/undo` command card itself is hidden; the folded headers are the only visible undo feedback.

## How it works

1. The host derives the currently model-visible turns from `turn/start` / `turn/end`
2. It takes the last n turns and appends `surfaceOp: { op: 'replace', start, end }` over their surface range
3. The checkpoint is an **empty assistant message** outside any turn boundary; message derivation skips empty assistant content, so the model sees only the retained history — no undo marker, no turn numbers
4. The client half reads the successful `/undo` command nodes and folds the undone turns with DOM/CSS

## Install

wang-xudong/dsh-plugin-undo 加入你的 DSH 配置(web profile)即可启用。

README

展开完整 README 收起

README 内容为空。