DSH Plugins Marketplace

DSH Plugins

Plugins

/

dsh-plugin-undo

w

dsh-plugin-undo

Manifest valid1

DSH Session Undo Plugin: undo the last n turns in-place within the current session, without forking or creating a new session | Undo the last n turns in-place in the current DSH session

UI (client)hasBundlePatch

dsh-plugin-undo

Conversation undo for DeepSeek Harness: undo the last n turns within the current session — no new session, no project file changes.

Why this plugin

Most conversation-rewind plugins use sessions.fork to copy a history prefix into a new session (the original session is kept or archived). This plugin undoes in place on the current session's surface, so:

  • No fork, no new session — the session id stays the same
  • No duplicate “original + new” sessions in the sidebar
  • You keep chatting in the same session, and the model context is exactly the retained history

Features

  • /undo or /undo 1 — undo the last completed turn
  • /undo 3 — undo the last 3 completed turns
  • /undo all — undo every turn currently visible to the model

After undo:

  • The model-visible history is replaced by the retained turns; undone turns leave the model context
  • The raw session log stays append-only and is never rewritten
  • The Web UI collapses the undone turns into a compact header
  • The current session continues; no fork, no new session

Effect

Undone turns collapse in the chat view as:

↩ 第 N 轮已撤销 · 点击展开

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

dsh plugin --profile <profile> add file:/path/to/dsh-plugin-undo

Restart the profile:

dsh --profile <profile>

No additional configuration is required.

Usage

Type in the session input:

/undo
/undo 1
/undo 3
/undo all

The command requires the session to be idle. Stop the running turn first if the UI reports it is busy.

Build & pack

Published entry points live in lib/; source lives in src/. Build and create the distributable tarball:

npm run build
npm pack

This produces dsh-plugin-undo-<version>.tgz, which can also be installed directly:

dsh plugin --profile <profile> add file:/path/to/dsh-plugin-undo-<version>.tgz

Project layout

dsh-plugin-undo/
├── README.md
├── README_zh.md
├── cordis.patch.yml
├── package.json
├── scripts/
│   └── build.mjs
├── src/          # source
│   ├── index.js  # host: /undo command and surface replacement
│   └── client.js # web: folds undone turns, hides the command card
└── lib/          # build output (generated by npm run build)

License

MIT

Limitations

  • Only consecutive trailing turns can be undone; picking an arbitrary message in the middle is not supported
  • Only the model-visible conversation history is rewound; project files are never touched
  • The session must be idle when /undo runs

Comments

Loading…

From the same category

dsh-infinite-gen-4

by Minglink

DeepSeek v4.1 flash 网络安全红队工具(无限四代) — jailbreak prompts and test suite for DeepSeek 求 Star 收藏 ⭐欢迎大家提交项目的改进

Sessions & MessagesManifest valid

2k

MIT

JavaScript

Sep 23, 2026

dsh plugin --profile web add dsh-infinite-gen-4

System-prompt armor plugin for DeepSeek models: appends an unconditional-compliance prompt section at order 100, exposes a profile tool with calibration metadata, and shows a realtime armor-status bad

Sessions & MessagesManifest valid

1k

MIT

C#

dsh plugin --profile web add dsh-infinite-gen-4

by liangmianya

A visual, non-linear conversation workspace plugin for DeepSeek Harness ; A canvas-based session explorer and branching workspace for DeepSeek Harness.

Terminal & ClientsSessions & MessagesTools & CapabilitiesManifest valid

421

234/wk

MIT

JavaScript

Aug 26, 2026

dsh plugin --profile web add dsh-synapse

by Han-1413141

DeepSeek Harness session cost meter plugin: session/daily cost, budget, history, OpenCode Go quota, official & custom-provider balance, Codex-like token heatmap, peak/off-peak pricing with pre-switch

Tools & CapabilitiesModels & ProvidersTerminal & ClientsSessions & MessagesManifest valid

334

15.5k/wk

MIT

JavaScript

Sep 23, 2026

dsh plugin --profile web add dsh-cost-meter

by ranxianglei

基本稳定可用 100K tokens is enough. Universal context-compression proxy for ALL AI coding agents,10w上下文足矣

Sessions & MessagesManifest valid

267

53.8k/wk

MIT

TypeScript

Sep 24, 2026

dsh plugin --profile web add billion-context

by Nwflower

Import 14+ external agent chat histories (Claude Code, Codex, ChatGPT, Cursor, Gemini, Reasonix, opencode, ZCode, Grok Build, OpenClaw, Pi, Hermes, Kimi CLI, DSH) into DeepSeek Harness as resumable se

Development & InfrastructureSessions & MessagesTools & CapabilitiesManifest valid

196

MIT

JavaScript

Sep 23, 2026

dsh plugin --profile web add dsh-chat-import