Introduction

Using the Fork feature in DeepSeek Harness terminates the current session and creates a new blank session. If you need to continue from a point in the middle of the conversation, the new session cannot know what happened after that point. dsh-message-handoff solves this problem. It adds a handle next to each confirmed assistant message, allowing users to perform a “handoff” at that point: copy the conversation history before that point, and have the LLM summarize the content after that point, thereby forking a new session with context.

Plugin Overview

dsh-message-handoff is a plugin designed for DeepSeek Harness to implement message-level session handoff.

  • Core capability: Provides a handle next to assistant messages; clicking it forks a new session.
  • Maintainer: antonkoatl.
  • Open source license: MIT.
  • Technical characteristics: Zero runtime dependencies; source code is manually maintained; no build step is required.

Installation and Enabling

The installation process does not require a build environment; lib/client.js is precompiled.

dsh plugin --profile web add /path/to/dsh-message-handoff
dsh web

After installation, you can confirm that the plugin is loaded with the following command:

dsh --profile web --dump-config | grep message-handoff

Core Features

The plugin provides the following capabilities:

  1. Message-level handoff: Renders a copy · ✋ handoff · fork control group next to each confirmed assistant message.
  2. History copying and summarization: After clicking the handle, the verbatim history before the selected message is copied into the new session; at the same time, the LLM is called to summarize only the conversation content after the selected message.
  3. Structured document injection: In the forked new session, a structured document containing “Task Objective,” “Current Progress,” “Key Decisions,” “File List,” “Next-Step Plan,” and “Unresolved Issues” is injected.
  4. Automatic session management: The child session is attached to the source session’s workspace, the title is automatically renamed, and the new session is opened.

Configuration

The plugin supports the config: parameter in cordis.yml to control input and output limits for summary requests:

- id: message-handoff
  name: dsh-message-handoff
  config:
    maxInputBytes: 24000   # 总结输入的字节上限(UTF-8),超时则丢弃最旧条目
    maxTokens: 10000       # 总结输出的 Token 预算
    timeoutMs: 120000      # 总结请求的超时时间(毫秒)

The model used for summarization is taken by default from the latest request routing of the source session; if unavailable, it falls back to the deployed default model.

Usage Flow

  1. In the web interface, find a confirmed assistant message.
  2. Click the Handoff icon on the right side of the message row (between the Copy and Fork buttons).
  3. The system automatically performs the following:
    • Copies the verbatim history up to that message into the new session.
    • Sends a request to the LLM to summarize the content after that message.
    • Injects the structured summary document into the new session.
  4. The new session opens automatically, and the source session remains unchanged.

Notes and Limitations

  • Privacy: To generate the summary, all conversation text after the selected message is sent to the configured model.
  • Trigger limitations: This handle is rendered only for confirmed assistant messages; user messages do not support this operation.
  • No persistent files: The plugin currently does not generate HANDOFF.md in the file system; the summary exists only in the session log.
  • Text limitations: Summarization processes text content only and does not include tool calls or attachments.
  • Preset inheritance: The forked child session inherits the preset configuration in effect when the source session was created, not the latest preset available at the time of handoff.

Summary

dsh-message-handoff is a practical tool designed to solve the loss of context when forking a session in DSH. By automating history copying and LLM summarization, it allows developers to continue from any point in the conversation without manual copying and pasting. For development scenarios that require long-term maintenance of multi-turn conversations or frequent entry into the middle of a session, the plugin provides a clear workflow.