跳到正文

solknight48/dsh-memoryhub

30最近提交 2026年8月15日

dsh-memoryhub DSH 插件

dsh-memoryhub 将 MemoryHub 基于检查点的记忆系统接入 DeepSeek Harness。它会在会话开始时自动加载过往记忆,提供六个 mh CLI 工具(mh_load、mh_save 等),并在 Web UI 中添加一个“记忆”标签页,内嵌 mh ui 的检查点地图。插件还注册了一个工作流技能,指导模型何时加载和保存记忆。

如何安装 dsh-memoryhub DSH 插件

dsh plugin --profile web add github:solknight48/dsh-memoryhub

复制不会执行命令。安装 dsh-memoryhub DSH 插件前请核对仓库和版本。

dsh-memoryhub DSH 插件数据来源

dsh-memoryhub DSH 插件快照日期:2026年8月16日

discovered

dsh-memoryhub DSH 插件能做什么

  • 会话开始时自动加载记忆:在工作区运行 `mh load` 并注入检查点上下文。
  • 六个 mh 工具:mh_load、mh_save、mh_status、mh_list、mh_search、mh_checkpoint——封装常用 CLI 操作。
  • 会话到记忆的桥接:将 dsh 会话事件转换为 pi 格式 JSONL,并通过 mh save --transcript 保存。
  • Web UI 记忆标签页:在聊天和轨迹旁内嵌实时 mh ui 检查点地图,支持按工作区发现。
  • 工作流技能:教导模型何时加载、如何保存(包括紧凑摘要)以及记忆库规则。
  • 可配置的自动加载、工具注册、技能、UI 标签页和超时时间。

dsh-memoryhub DSH 插件适合哪些场景

  • 跨多个 dsh 会话持久化项目上下文,无需手动重新提示。
  • 将会话中的关键决策和摘要保存为版本化检查点,供日后回顾。
  • 通过 mh_search 直接在聊天中搜索过去的记忆检查点。
  • 在 Web UI 中查看检查点的时间线和令牌预算的可视化图表。
  • 将 dsh 与 MemoryHub 现有工作流集成(例如使用 mh compact save 生成干净摘要)。

dsh-memoryhub DSH 插件适合谁

  • 希望跨会话持久化记忆的 DeepSeek Harness 用户。
  • 已在使用 MemoryHub (mh) 并希望将其与 dsh 统一的开发者。
  • 偏好图形化记忆时间线的 dsh Web UI 用户。

dsh-memoryhub DSH 插件的限制

  • 需要安装 MemoryHub (mh) 并确保其在 PATH 中(uv tool install git+...)。
  • 仅支持 mh 自己的检查点格式;v1 版本不桥接引导消息和文件附件。
  • 自动加载按令牌预算选择加入;默认无预算(加载所有会话)。
  • 测试套件尚未针对真实模型会话执行(需要 API 密钥)。
  • mh ui --budget 选项需要 2026-08-14 或更高版本的 mh(用于 uiBudget: none 默认值)。

dsh-memoryhub DSH 插件的仓库 README 摘录

以下文字摘自 dsh-memoryhub DSH 插件的上游仓库 solknight48/dsh-memoryhub 的 README,版权归原作者,仅作引用。

English | [简体中文](README.zh-CN.md) [MemoryHub](https://github.com/solknight48/memoryhub) (`mh`) integration for [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) (`dsh`). MemoryHub keeps project memory as **purified sessions in git-versioned checkpoints** under `.memoryhub/`. This plugin wires that into dsh: - **Auto-load on session start** — runs `mh load` in the session workspace and injects the checkpoint memory as durable plugin context. No prompt, no tool call; the model simply starts with its memory back. - **`mh_save` bridges dsh sessions to mh** — dsh session files are not among the transcript formats mh discovers (Claude Code / pi / Codex), so the plugin renders the live session's durable event log as a pi-format JSONL transcript (in the temp dir) and saves through mh's existing `--transcript` path. Purified saves and agent-written compact saves both work, under a stable per-session identity: re-saving **replaces**, never duplicates. - **Six tools** — `mh_load`, `mh_save`, `mh_status`, `mh_list`, `mh_search`, `mh_checkpoint` wrap the CLI; the model never has to shell out for the common operations. Rarer operations (`mh link`, `mh bac

阅读完整 README仓库许可: MIT

dsh-memoryhub DSH 插件常见问题

我需要单独安装 MemoryHub 吗?

是的。插件会调用 `mh` CLI,因此你必须安装 MemoryHub 并将其加入 PATH。使用 `uv tool install git+https://github.com/solknight48/memoryhub` 安装(需要 git ≥ 2.32 和 Python ≥ 3.12)。没有它插件无法工作。

如何配置自动加载的令牌预算?

在插件配置中设置 `loadBudget`(例如 `loadBudget: 6000`)来限制自动加载的令牌数。如果省略,则使用 mh 的默认预算(加载所有会话)。你也可以在 `mh_load` 工具中单独传入 `budget` 参数。

保存会话会导致记忆检查点重复吗?

不会。插件通过稳定 ID 识别每个 dsh 会话。再次保存时,它会替换该会话之前的检查点(mh 为每个会话只保留一个表示)。桥接每次都会重建,因此你始终获得最新快照。

没有 Web 服务器时可以使用记忆标签页吗?

记忆标签页仅在 dsh Web UI 运行时可用(插件注册了 `/plugins/memoryhub/mh-ui` 路由)。无头模式从不显示此功能。如果你在没有 Web 服务器的情况下运行 dsh,记忆标签页根本不会出现。

如果工作区没有 .memoryhub 目录会怎样?

当 `noHubHint: false`(默认值)时,插件完全静默:不注入任何内容,也不产生日志。记忆标签页会显示一个带重试按钮的空状态。自动加载不做任何操作。你可以设置 `noHubHint: true` 来注入一行提示。