dsh-session-export: Exporting DSH Sessions to Markdown and JSON

Introduction

In DSH, after a session ends, developers often need to archive, read, share, or pass the conversation records to downstream processes. dsh-session-export addresses this specific problem: exporting the current DSH session into portable, human-readable Markdown and structured JSON.

It is a community plugin for DSH, maintained by bwndlct. The plugin ecosystem direction of DSH is “everything is a plugin”; the community directory is an independent site, with no official affiliation to DeepSeek / High-Flyer, and is not an official app store.

What This Is

bwndlct/dsh-session-export is a DSH plugin that exports DeepSeek Harness (DSH) sessions to portable, human-readable Markdown and structured JSON files.

License: MIT.

Core Features

Below are the verified capabilities.

Two Entry Points

  1. session_export() tool: allows the model to perform the export.

  2. /session-export slash command: triggers the export from the Web UI.

Two Formats

  • Markdown: a human-readable session export file.
  • JSON: a structured export file that includes schemaVersion, using a stable export schema.

Ordering and Robustness

  • Reconstructs the session in the order of user messages, assistant messages, tool calls, and tool results.
  • Handles unknown event types, missing metadata, code fences, oversized tool results, and more robustly.
  • Tool results exceeding 8,000 characters are truncated and flagged.

File Names and Runtime

  • Generates cross-platform-safe file names.
  • Does not overwrite existing files; duplicate export files will have -1, -2, etc. appended.
  • Zero runtime dependencies, using only TypeScript and Node built-in modules.

Installation and Enablement

Requires dsh >= 0.1.0-rc.6. The plugin is built and verified against @deepseek-ai/dsh 0.1.0-rc.6 (DSH Developer Preview).

  1. Run the installation command:
dsh plugin --profile web add dsh-session-export
  1. Add the plugin to the bundles list in the current profile’s package.json. The configuration looks like:
"dsh": {
  "profile": {
    "bundles": [
      "dsh-session-export"
    ]
  }
}
  1. Restart dsh.

Note: The slash command is only registered in profiles that mount the commands service (e.g., web); the session_export() tool is available in all profiles.

Typical Usage

Let the Model Export

Tell the model:

把当前会话导出成 Markdown
Export this session, json only

Export in the Web UI

/session-export
/session-export markdown
/session-export json

You can also export only one format:

/export-md
/export-json

Suitable Scenarios and Notes

Suitable for:

  • People who need to archive the current DSH session as Markdown or JSON.
  • People who need to view and share session records.
  • People who need to trigger exports via slash commands in the Web UI.

Notes:

  • The plugin runs with the permissions of the current dsh process; check the source code and MIT license before installation.
  • Exported files may contain sensitive data; this plugin performs no redaction.
  • Slash commands require a profile that mounts the commands service (e.g., web).
  • Before sharing exported files, review the source code, tool parameters, tool results, paths, and other information they may contain.

Conclusion

The value of dsh-session-export lies in turning DSH sessions into stable, readable, portable Markdown/JSON files for subsequent archiving and toolchain processing.

GitHub: https://github.com/bwndlct/dsh-session-export. The community directory URL is not confirmed in the facts of this article, so no specific URL is provided; you can search for dsh-session-export in the DSH community directory.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye