PwnKY/dsh-session-link 预览 preview

PwnKY/dsh-session-link

Plugin插件 Native原生 ⭐ 7 MIT Sessions & Context会话与上下文

DeepSeek Harness的Codex式会话深度链接插件:dsh:// 深链,跨对话读取上下文

Project Overview项目介绍

This is a native plugin built exclusively for DeepSeek Harness (DSH) that adds Codex-style deep session linking functionality. It can be installed with one command: dsh plugin --profile web add dsh-session-link, after which you just need to restart the DSH Web GUI and refresh the browser page. The plugin automatically adds its configuration to your DSH profile bundle, so there is no need to manually edit any YAML configuration files. It supports multiple common link formats, including dsh:// deep links, local browser session URLs, and standard DSH session URIs.

After installation, the plugin adds a one-click copy button to the header of every DSH conversation in the web interface. When you want to reference an existing session from another conversation, just click the button to copy the session deep link, paste it into your new message, and send the message. The plugin will resolve the link, generate a read-only snapshot of the original session context, and inject that snapshot before your current prompt. It only injects text content and skips non-text assets like images, per upstream DSH service limits.

The plugin builds on the official @deepseek-ai/dsh-session-reference service included with DSH 0.1.0-rc.8 and above, and is released under the permissive MIT license. It has several key known limitations: session links only work on the local machine that hosts the DSH instance, references to missing or oversized sessions will fail gracefully without interrupting the current conversation. Windows users can optionally run a provided PowerShell script to register the dsh:// protocol, which lets you click deep links to open the corresponding session directly in your browser.

这是DeepSeek Harness专属的原生插件,实现了Codex风格的会话深度链接功能。用户可复制任意会话的dsh://格式链接,粘贴到另一对话中,插件会将被引用会话的上下文生成只读快照,注入到当前提示词之前作为背景上下文,也可直接点击链接在浏览器中打开对应会话。插件支持dsh深链、浏览器地址、规范URI等多种链接格式,不会误伤无关文本。

适合需要在多个独立对话间复用已有会话上下文的DSH用户,整体使用流程非常简单。通过一键命令安装后,只需点击Web界面会话标题旁的复制链接按钮获取深链,再粘贴到目标对话发送即可。插件会自动解析链接,生成符合大小限制的只读快照放在当前提示词前,原链接会替换为可读的@会话ID标签,方便用户和模型识别。

本插件基于DSH官方提供的session-reference服务开发,遵循MIT许可协议免费使用,依赖DSH 0.1.0-rc.8及以上版本。存在几个已知限制:链接仅在本机有效,仅支持文本投影,非文本内容如图片无法跨会话传播,引用会话不存在或超预算时会保留原链接不打断对话。Windows用户可额外注册协议处理器实现点击深链直接打开会话。

Pre-install check安装前体检Compatibility · Security兼容性 · 安全性 1 warning1 项注意
  • Only 7 stars - very few users, little community feedback星标只有 7,几乎没人在用,遇到问题缺少社区反馈
DSH walks through these 9 checksDSH 会逐条核对这 9 项

Compatibility兼容性

  • DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
  • External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
  • Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册

Security安全性

  • Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
  • Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
  • curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
  • Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
  • Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
  • Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式

Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。

Or use CLI install (for developers)或使用命令行安装(适合开发者)

CLI Install命令行安装

dsh plugin --profile web add dsh-session-link

把 PwnKY/dsh-session-link 加入你的 DSH 配置(web profile)即可启用。

READMEREADME

dsh-session-link

npm npm downloads · English · 中文

DeepSeek Harness 的 Codex 式会话深度链接插件

复制任意会话的链接,粘贴到另一个对话里 —— 被引用会话的上下文会被快照,并作为受控的只读背景上下文注入到你的提示词之前;同一链接也能在浏览器中直接打开对应会话。

一键安装

# 一条命令装完:安装包 + 自动加入 profile 的 bundle 层 + 自动应用配置行
dsh plugin --profile web add dsh-session-link

# 重启 Web GUI 并刷新页面
dsh web

无需手动修改任何 yml —— 插件自带 dsh.bundle patch(cordis.patch.yml),dsh plugin add 检测到后会自动把它加进 dsh.profile.bundles,启动时自动组合 session-link 行配置。上游的 session-reference 服务自 dsh 0.1.0-rc.8 起由官方 web bundle 自行组合,插件不再重复插入(重复 id 会导致启动失败)。

通用 npm 安装(只装包、不进 profile):npm install dsh-session-link 手动安装方式(不依赖 bundle 机制):见快速开始。

┌─ 会话 A ─────────────────┐        ┌─ 会话 B ─────────────────────────┐
│  🔗 复制会话链接          │        │  用户: 请参考这个会话:           │
│  → dsh://session/session-│ ─────▶ │        dsh://session/session-…   │
│    …abc                   │  粘贴  │                                  │
└───────────────────────────┘        │  模型: (收到 A 的快照            │
                                     │         + 提示词,链接变 @label) │
                                     └──────────────────────────────────┘

特性

  • 🔗 一键复制 —— 会话头部「复制会话链接」按钮,输出 dsh://session/<会话ID>(codex:// / claude:// 同款格式)
  • 📖 跨对话读上下文 —— 把链接粘进任意对话,源会话内容被快照(有上限、只读)并注入到你的提示词之前
  • 🖱️ 可点击深链(Windows) —— 注册 dsh 协议处理器后,点击 dsh:// 链接直接打开 Web GUI 并选中该会话
  • 🛡️ 容错 —— 畸形链接、会话不可读、自引用都不会打断对话:链接保留为原文,失败记录在服务端日志

工作原理

本插件复用官方 @deepseek-ai/dsh-session-reference 服务(它已实现规范 URI、mention 解析、快照投影与字节预算保留),再把它接入 agent 循环和 Web 界面:

  • 服务端(lib/index.js) —— cordis 插件,挂在 agent/pre-step 钩子上:用户消息里出现会话深链时,把各种链接形式统一成规范 dsh-session: mention,解析为结构化引用,通过 sessionReferenceResolver.prepare() 快照源会话,并把聚合的只读快照放在直接提示之前。钩子与传输层无关,TUI 里粘贴规范 URI 同样生效。自 dsh 0.1.0-rc.8 起,上游服务自身也会在 agent/pre-step 上处理规范 URI;插件监听器以 prepend 跑在最外层,只处理上游不认识的深链形式(dsh://、web 链接),同一条链接不会被注入两次。
  • 浏览器端(lib/client.js) —— 静态客户端包(dsh.client 声明),在 conversation.session.header.actions 渲染复制按钮,并在以 /?session=<会话ID>(或旧的 /s/<会话ID>、哈希形式 #/s/<会话ID>)打开页面时,等会话目录加载后经 ctx.uiWorkspace.openSession() 选中目标会话(约 10 秒有界重试,最终失败时告警)。

Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →

← 上一个 Prev DIzzy-DSH 下一个 Next dsh-iris →