DeepSeek Harness (DSH) official log export (dsh-session-log-export) generates a ZIP archive of raw JSONL by default, which is difficult to read directly. The dsh-session-md plugin fills this gap by exporting a session as a human-readable Markdown file or self-contained HTML page.

The plugin supports multiple export modes, covering scenarios from “reproducing for a model” to “human weekly reports.” It provides UI buttons for one-click downloads and also supports direct file writing via tool calls.

Installation

The plugin installation command is:

dsh plugin --profile web add dsh-session-md

After installation, refresh the browser page to apply the changes. The plugin declares dsh.bundle.patch, so there is no need to manually edit configuration files.

  • Node version: Requires ^22.19.0 || >=24
  • Dependencies: No @deepseek-ai/* dependencies and no peerDependencies

Usage

UI Operation

There is a download icon button in the action area on the right side of the session title bar (usually in the same location as the official “Download Session Log” button). Clicking it displays a mode menu supporting the following export types:

  • Full: Complete tool parameters and results are preserved; suitable for Agent handoff or reproduction.
  • Handoff: Retains tool calls but removes the chain of thought; suitable for a token-saving handoff version.
  • Readable: Human-readable mode; tool calls retain only names.
  • Audit: Does not truncate content; includes system prompts and injected context; suitable for archiving.
  • HTML Export: Generates a self-contained HTML page that can be printed or sent directly.

The file name is specified by the Host’s Content-Disposition header and supports Chinese titles. The browser download path is determined by the browser and is not subject to session file sandbox restrictions.

Tool Call

You can also directly ask the model in a conversation to call the tool to export:

export_session_md({ mode: 'readable' }) // 当前会话导出为简洁版
export_session_md({ all: true, path: '/abs/dir' }) // 批量导出全部会话
export_session_md({ includeToolDetails: false }) // 仅保留工具名

Export Modes Explained

The plugin provides four main rendering presets, and parameters can explicitly override default values:

Mode Tool Calls Chain of Thought System Prompt Description
full Full Parameters + results Retained Not included For review/replay; has length limits
handoff Handoff Parameters + results Removed Not included Token-saving handoff version
readable Readable Names only Retained (collapsed) Not included Shortest, suitable for human reading
audit Audit Parameters + results Retained Included No truncation; for archiving

The default output (includeToolDetails: true) is suitable for review; disabling tool details (includeToolDetails: false) creates a “clean shared version,” usually only a fraction of the original size.

Technical Details

  • Hot swapping: The plugin supports the standard Cordis plugin lifecycle and can be reloaded using load / unload.
  • File name handling: Uses slugify to process file names; on Windows, reserved device names (such as CON and NUL) and illegal characters are automatically avoided.
  • Offline validation: The plugin includes a complete offline test suite, allowing the rendering logic to be validated without a DSH environment.
  • Source code changes: After modifying the plugin source code, restart dsh web to apply the changes; refreshing the browser page is usually not enough.

Directory and Source Code