Skip to content

ZhengQingJing/dsh-session-tree

30Last commit Aug 14, 2026

dsh-session-tree DSH plugin

dsh-session-tree is a community-developed DSH plugin that displays the session fork history as a version tree in the conversation view. It allows users to create new child sessions from any loaded and completed turn, providing a non-destructive way to explore alternative conversation paths.

How to install the dsh-session-tree DSH plugin

dsh plugin --profile web add dsh-session-tree@next

Copying does not run this command. Review the repository and version before installing the dsh-session-tree DSH plugin.

dsh-session-tree DSH plugin data source

dsh-session-tree DSH plugin snapshot date: Aug 16, 2026

discovered

What the dsh-session-tree DSH plugin can do

  • Visualizes session fork history as a deterministic version tree in a new 'Version Tree / Branches' tab.
  • Distinguishes normal forks from subagent lineages for clarity.
  • Lists only completed turns within the loaded history window, with option to load earlier turns.
  • Creates child sessions via DSH native `ctx.sessions.fork({ sessionId, atSeq })` and opens the new conversation.
  • Limits initial DOM workload for large trees and long conversations.
  • Disables all fork buttons during an ongoing fork request to prevent duplicate operations.

Where the dsh-session-tree DSH plugin fits

  • Experiment with alternative responses from a specific completed turn without affecting the original session.
  • Navigate through a complex conversation tree to review different branches and their outcomes.
  • Recover a previous successful turn by forking from it, avoiding the need to replay the entire conversation.
  • Collaborate with team members by sharing session IDs and exploring different branches from a common base.

Who the dsh-session-tree DSH plugin is for

  • DSH users who need to manage and explore multiple conversation variants.
  • Developers and researchers using DSH for iterative experimentation and debugging.
  • Power users who want non-destructive branching similar to version control for conversations.

dsh-session-tree DSH plugin limitations

  • Upstream fork RPC lacks operation id, persistent source witness, or idempotent retry contract; duplicates may still occur across multiple pages/processes.
  • Session summary includes parent id but not `seedLength` or parsed fork boundary, so the tree cannot cost-effectively annotate exact source sequence on child edges.
  • Does not support named refs, HEAD, reflog, merge, rebase, cherry-pick, branch deletion, shared prefix storage, or automatic garbage collection.
  • Each native child session materializes the inherited event prefix; long-lived branches amplify storage usage.
  • Workspace snapshots and external side-effect rollback are explicitly out of scope.

dsh-session-tree DSH plugin: from the repository README

Quoted from the ZhengQingJing/dsh-session-tree README, the upstream source of the dsh-session-tree DSH plugin. Copyright remains with the original authors.

`dsh-session-tree` 是一个可安装的 DeepSeek Harness(DSH)浏览器端插件。它将 DSH 原生 Session fork 呈现为不可变的对话版本树,并允许用户从任意**已加载且已完成的对话轮次**创建子分支。 > [!IMPORTANT] > **非官方社区插件。** 本项目由社区独立开发,不隶属于 DeepSeek,也未经 DeepSeek 背书或维护。DSH 与本插件均处于预发布阶段;升级前请审阅变更,并备份重要的 DSH profile 与 Session 数据。 源码仓库:[github.com/ZhengQingJing/dsh-session-tree](https://github.com/ZhengQingJing/dsh-session-tree) 当前版本支持: - DeepSeek Harness 源码版 `0.1.0-rc.5`(审计基线 `47f9438`)。 - DSH Client 公开 API `0.1.0-rc.5` 和 `0.1.0-rc.6`。 - Node.js `^22.19.0 || >=24.0.0`。 DSH 尚处于开发者预览阶段。为避免在未来 API 变更上作出不安全的假设,本插件的 peer dependency 仅允许上述两个已验证的预发布版本。 ## 功能 - 在对话页面中新增 **版本树 / Branches** 标签页。 - 将 `SessionSummary.parentId` 投影为确定性的当前对话家族树。 - 区分普通 fork 与 subagent 谱系。 - 显示但隔离孤儿节点和循环谱系,不修改持久化记录。 - 列出当前已加载历史窗口中的已完成轮次。 - 调用 DSH 原生 `ctx.sessions.fork({ sessionId, atSeq })` 创建子 Session,然后打开新对话。 - 按需加载更早的历史轮次。 - 限制大型版本树和长对话的初始 DOM 工作量。 插件不定义自有 `SessionEvent` 类型,也不维护独立的分支数据库。卸载插件后,已创建的分支仍是普通、可读的 DSH Session。 ## 安全契约 - 回溯始终创建新的子 Session;绝不截断或重写父 Session。 - 只提供已完成的 `turn/end` 检查点。 - 当 fork 请求进行中时,当前视图中的其他 fork 按钮全部禁用。 - 不自动重试不确定或部分成功的请求。界面会要求用户先检查版本树,以避免生成重复子分支。 - 禁用 `increaseTitle`,避免子 Session 已发布后又因标题修改失败而产生额外的部分成功状态。 - 谱系异常在 UI 中 fail-soft,不会被静默修复。 - 对话分支**不会**撤销文件

Read the full READMERepository license: MIT

dsh-session-tree DSH plugin questions

How do I install dsh-session-tree?

You can install it via DSH's plugin command. The recommended way is `dsh plugin --profile web add dsh-session-tree@next` to get the latest pre-release version from npm. Alternatively, you can install from a GitHub release tarball or by cloning the repository and building locally. See the README for detailed instructions.

Does this plugin modify my original sessions?

No. It only reads session data and creates new child sessions via DSH's native fork API. Your original sessions remain unchanged. Even after uninstalling the plugin, the child sessions you created are still accessible as normal DSH sessions.

Can I delete branches I created?

The plugin does not currently support branch deletion. You can only create new branches. If you want to remove a child session, you would need to delete it manually through DSH's native session management (if available) or by directly modifying the session storage.

Is it safe to use with the latest DSH version?

The plugin explicitly supports DSH source version 0.1.0-rc.5 and DSH Client API 0.1.0-rc.5/0.1.0-rc.6. It uses peer dependency constraints to avoid incompatible API changes. If you upgrade DSH beyond these versions, you should check for plugin updates and verify compatibility.

What happens if I fork a turn that is still being generated?

The plugin only allows forking from completed turns (those ending with `turn/end`). In-progress assistant chunks are not provided as checkpoints. You must wait for the turn to complete before you can create a branch from it.