Preface¶
Sessions in DSH can fork. After forking, the child session inherits the history of the parent session, but the sidebar usually only presents a flattened list with indentation. This kind of list explains “what sessions exist,” but it doesn’t explain “which session came from which.”
dsh-fork-graph solves the second problem: it visualizes the session fork relationship as a git-graph style topology and allows jumping between branches.
What is it¶
dsh-fork-graph is a DeepSeek Harness (DSH) web plugin maintained by chouyong with an MIT license.
Its one-sentence positioning is: displaying a git-graph style session fork topology in the DSH session header, allowing you to see which session branched from which and to jump between branches.
It does not replace the DSH fork action, nor does it maintain an independent set of session data; it simply projects the DSH’s existing session list data into a graph.
Core Features¶
- Display git-style session fork history in the session header.
- Each branch has its own independent colored lane; forks use curves to leave the parent node.
- Each session occupies a line, showing the title, and facts such as
current,running,subagent,forks into N, etc. - Clicking any node jumps to the corresponding session.
- Default focus is on the current session’s lineage family, rather than listing all historical sessions.
- If the current lineage has no fork, this control does not render.
- Supports English and Chinese, following the page language.
- No write behavior: no session events, no RPC, no state persistence, no prompt content.
- It is a pure projection of DSH session list data, not introducing a second data source.
Installation and Activation¶
Confirm the environment before installation:
- DSH
- Node.js
^22.19.0 || >=24.0.0 - pnpm
The following introduces the installation method under the Web profile.
- Install the plugin in the Web profile:
dsh plugin --profile web add github:chouyong/dsh-fork-graph
- Start the DSH Web UI:
dsh web
- If pnpm
≥10refuses the plugin’spreparescript, you need to add the following configuration to thepnpm-workspace.yamlin that profile:
allowBuilds:
dsh-fork-graph: true
Re-execute the add command above after adding.
- If you don’t want subsequent pushes to change the local installation content, you can use a commit-fixed version:
dsh plugin --profile web add github:chouyong/dsh-fork-graph#<sha>
- If git installation fails due to the unpublished
@deepseek-ai/dsh-compact, you can use the pre-built tarball method:
npm install --ignore-scripts --legacy-peer-deps
npm run build
npm pack
dsh plugin --profile web add ./dsh-fork-graph-0.1.0.tgz
- Remove the plugin:
dsh plugin --profile web remove dsh-fork-graph
Typical Usage¶
After the steps above, run:
dsh web
Then check the control provided by this plugin in the session header of the DSH Web.
It defaults to showing only the lineage family of the current session. Each line corresponds to a session and displays the title and current status, e.g., current, running, subagent, forks into N.
Clicking any node jumps to the corresponding session.
If the current lineage has no fork, this control will not render. Blank leaf sessions are hidden, except for the current session; the panel displays the count of hidden ones. Wider lineages scroll because lanes are not recycled.
Use Cases and Notes¶
This plugin is suitable for developers who fork sessions multiple times in DSH and need to quickly determine the session origin and branch location.
Notes before use:
- It is a read-only visualization, no session events, no RPC, no state persistence, no prompt content.
- It does not provide fork UI; DSH already has fork actions, and this plugin is responsible for the visualization.
- It does not show the exact location where the fork occurred because DSH currently does not surface
seedLengthto the browser. - Language follows the documentation or page language, not DSH’s locale service.
- Some DSH packages cannot be installed from npm due to the unpublished
@deepseek-ai/dsh-compact, so the README provides a fallback installation method using pre-built tarballs. - The plugin runs with the permissions of the current dsh process. Source code, dependencies, and license should be checked before installation.
Short Conclusion¶
The value of dsh-fork-graph is transforming the flat list of fork relationships in DSH sessions into a clickable, trackable topology graph.
GitHub repository:
https://github.com/chouyong/dsh-fork-graph
Verified materials did not provide the plugin directory page URL. If installing from the DSH plugin directory, you can search for dsh-fork-graph by name.