现代化对话回退与重试插件:纯 UI 图形化交互、原地 Prompt 微调、支持工作区与外部文件双引擎安全快照同步,完美解决分支重放断代问题。
安装
# GitHub 源码(首次需按提示配置 allowBuilds 构建授权后重试)
dsh plugin --profile web add github:Movingtoleveltwo/dsh-revert
装任何插件都等于在你的机器上跑第三方代码,权限和你本人一样大——能读你的文件、用你的凭据、访问网络,工具审批管不到它。GitHub 来源的插件还会在安装时执行构建脚本——pnpm 默认拦截,所以安装可能停在 ERR_PNPM_GIT_DEP_PREPARE_NOT_ALLOWED 或 ERR_PNPM_IGNORED_BUILDS;dsh 会打印出需要添加的确切键名,把它加进该 profile 的 pnpm-workspace.yaml 的 allowBuilds 下,重跑一次即可装上。放行构建本身就是一次信任判断:请只安装可信来源,并尽量锁定 commit(github:owner/repo#sha)。
README
简体中文
DeepSeek Harness (DSH) 现代化对话回退与重试插件:纯 UI 图形化交互、原地 Prompt 微调、支持工作区与外部文件双引擎安全快照恢复。
✨ 核心特性
- 🎯 纯 UI 图形化交互:无需记忆任何复杂的斜杠指令,鼠标悬浮在任意对话消息下方即可点击「↩️ 还原重试」;
- ✏️ 原地微调 Prompt:弹窗直接回显该轮用户输入的 Prompt,修改后自动聚焦回填到聊天输入框;
- 🛡️ 工作区内快照(Shadow Git):在独立影子存储中维护轻量快照,秒级撤销代码变动,绝不污染或重置用户自己的本地 Git 分支;
- 🌐 工作区外部安全恢复(External Interceptor):精准拦截 AI 在工作区外部编辑过的文件,并在回退时一并安全写回原始状态;
- 📱 多端全适配:电脑端、平板端与手机端界面完美适配。
🚀 安装与启用
方式 1:通过插件市场一键安装
在 DSH 的【设置 ➔ 插件市场】中搜索 dsh-revert,点击安装即可。
方式 2:本地开发与手动加载
# 进入 profile 目录并链接本地插件
cd ~/.dsh/profiles/web
npm link /path/to/dsh-revert
在 ~/.dsh/profiles/web/package.json 中的 dsh.profile.bundles 添加 "dsh-revert",重启 DSH 即可生效。
💬 问题反馈
本项目致力于提供最稳定、丝滑的对话回退体验。如果您在使用过程中遇到任何 Bug、文件未正确回滚的情况,或者有新的功能建议,非常欢迎您在 Issues 中向我反馈。我看到后会第一时间进行排查和修复!期待与大家一起把这个插件打磨得更好。
English
A modern UI-based rewind and retry plugin for DeepSeek Harness (DSH). Features inline prompt editing and a flawless dual-engine state recovery system (Workspace ShadowGit + External Tracker).
✨ Key Features
- 🎯 Pure UI Interaction: Hover over any chat message and click the "↩️ Rewind" button. No slash commands required.
- ✏️ Inline Prompt Editing: Automatically extracts and fills the prompt from the reverted turn into your composer.
- 🛡️ Workspace Shadow Git: Maintains lightweight, isolated snapshots of your workspace. Rolls back AI code changes in seconds without polluting your own Git repository.
- 🌐 External File Interceptor: Safely tracks and reverts files modified by the AI outside of the current workspace.
- 📱 Fully Responsive: Seamlessly adapts to Desktop, Tablet, and Mobile views.
🚀 Installation
Method 1: Plugin Market
Search for dsh-revert in DSH [Settings ➔ Plugin Market] and install it with one click.
Method 2: Manual Link
cd ~/.dsh/profiles/web
npm link /path/to/dsh-revert
Add "dsh-revert" to dsh.profile.bundles in your package.json and restart DSH.
💬 Feedback & Support
If you encounter any bugs, unexpected rollback behaviors, or have feature requests, please feel free to open an Issue. I actively monitor them and will do my best to investigate and fix any problems promptly!
🛠️ 架构与技术原理 (Architecture)
- Client 端(Slot 注入):通过 DSH 的 Cordis 插槽系统注入
conversation.chat.assistant-actions,渲染回退操作按钮与 React 弹窗; - Host 端(RPC 服务):通过
/dsh-revert/rpc暴露轻量快照与回滚调度服务; - 快照存储引擎 (Storage Engines):
ShadowGit:按工作区路径哈希维护隔离的裸仓库快照 (Maintains isolated bare git repos for workspace snapshots);ExternalFileTracker:维护轮次级别的外部文件修改前置记录 (Tracks and restores external file states pre-modification)。
📄 开源协议 (License)
MIT License © 2026 Movingtoleveltwo
链接
同类插件
Minglink/dsh-infinite-gen-4★ 3055
DeepSeek 专用破甲插件:以 order 100 追加无条件服从的系统提示词段,提供带校准元数据的 profile 工具,并通过会话投影在输入框上方显示实时破甲状态徽标。
ranxianglei/billion-context★ 1893
billion-context官方版:上下文压缩插件,兼顾小窗口(100k上下文足矣)省token(省5倍token)和超长会话(数月级别几十亿token单会话)。
liangmianya/dsh-synapse★ 538
DeepSeek Harness 的可视化非线性对话工作区:把会话、追问与分支变成可浏览、可拖拽的对话地图。
Nwflower/dsh-chat-import★ 238
把 13 家 coding agent(Claude Code、Codex、ChatGPT、Cursor、Gemini、opencode 等)的完整对话历史导入为可续聊的 DeepSeek Harness 会话,并支持反向导出回 Claude Code。
MichengAI/dsh-archive-manager★ 171
在设置里增加已归档会话页,可按工作区搜索、恢复和删除已归档会话。
Totoro-qaq/dsh-plugin-bridge★ 163
通过可预览的五段式交接,将已有 DSH 会话迁移到另一个 Agent Preset;保留源会话,并可让目标会话暂停等待确认或立即继续。
社区评论
评论公开保存在 GitHub Discussions。加载评论会连接 GitHub 和 Giscus;发表内容需要 GitHub 账号。