Introduction

When developing web sessions with DeepSeek Harness (DSH), locating historical questions or context switch points in long conversations often requires frequent manual scrolling. This approach is inefficient and can make it easy to lose track. The dsh-anchor-rail plugin provides global conversation navigation through a fixed left-side rail.

Plugin Overview

dsh-anchor-rail is a client-side plugin maintained by developer lyfZhixing. The core problem it solves is how to quickly locate user questions in long conversations and how to handle the display of historical data affected by context compression.

Key Features

  1. Left-side rail display: Displays anchors for all user questions on the left side of the conversation chat area, without moving as the page scrolls.
  2. Compressed segment aggregation: Consecutive compressed questions are folded into a single dashed group anchor (such as ▸ Compressed · N questions), avoiding a crowded rail caused by too much compressed content.
  3. Hover interaction: When hovering over the rail or any anchor, an anchor name list expands on the right (#index + question text).
  4. Group expansion: Hovering over a dashed group anchor switches to the sublist of compressed questions for that segment; hovering over a normal anchor only shows the uncompressed list.
  5. High-density fallback: When the spacing between anchors is less than 24px, the name panel automatically becomes a compact scrolling list to prevent text overlap.
  6. Highlighting and jumping: The anchor/name corresponding to the question currently being read is highlighted and extended. Clicking an anchor or name quickly jumps to the corresponding question.
  7. History preservation: Historical anchors after context compression are retained (aggregated into dashed groups or displayed individually) and are not lost due to compression.

Installation and Enabling

It is recommended to install using the official DSH plugin command:

dsh plugin --profile web add dsh-anchor-rail

For local debugging or customization, you can place the repository in ~/.dsh/profiles/web/plugins/dsh-anchor-rail/, and configure dependencies and bundle in package.json.

How It Works

The plugin is divided into a Host half and a Client half:
* Host half: Reads the complete raw log via sessionQuery.readSession, extracts user question events, uses compression checkpoints to mark compressed history, and provides data through the /dsh-anchor-rail/anchors route.
* Client half: Handles rail rendering, hover list logic, and scroll jumping. When the jump target is outside the current window, it automatically calls loadOlder() to load historical data page by page.

Typical Usage

  1. Open the DSH web session page.
  2. The rail automatically appears on the left (displayed only when the number of questions is greater than 2 and the content is scrollable).
  3. Hover over the rail to view all anchor names, and click any name to jump.
  4. Hover over a dashed group to view the sublist of compressed questions.

Notes

  • Automatic hiding: The rail automatically hides when there are fewer than 2 questions or the content does not need scrolling.
  • Scrolling list: When the spacing between anchors is less than 24px, the name panel automatically becomes a compact scrolling list.
  • License: MIT.

Summary

dsh-anchor-rail solves the problem of quickly locating historical questions in long conversations through a left-side rail and hover interactions. It properly handles data display after context compression, making it suitable for developers who need to quickly trace back in complex conversations.