跳到正文

elementor-i/dsh-agentmemory

30最近提交 2026年8月14日

dsh-agentmemory DSH 插件

dsh-agentmemory 将 agentmemory(一个面向编码 agent 的本地内存服务器)连接到 DeepSeek Harness。它暴露全部 54 个 memory_* 工具,自动记录会话、提示词和工具活动的观察结果,并可将召回的内容注入系统提示词。插件通过本地 REST 服务器工作,无需 MCP 桥接。

如何安装 dsh-agentmemory DSH 插件

dsh plugin --profile web add github:elementor-i/dsh-agentmemory

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

dsh-agentmemory DSH 插件数据来源

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

discovered

dsh-agentmemory DSH 插件能做什么

  • 完整工具集:54 个 memory_* 工具(8 个核心)映射到 /agentmemory/* 端点,另加 memory_observe 和 memory_http 逃生口。
  • 自动捕获:会话、提示词、工具使用、子 agent、工作流和审批事件在后台记录为观察结果。
  • 上下文注入:可选;从会话中召回的内容被添加到系统提示词中。
  • 默认安全:凭据脱敏、每次调用超时、非阻塞观察、破坏性工具需通过标志启用。
  • 无需 MCP:通过本地 REST 服务器(localhost:3111)工作,无需 stdio 桥接或子进程。

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

  • 为编码 agent 提供跨会话的持久记忆,用于回忆过去的决策和教训。
  • 自动记录所有工具使用和提示词历史,用于调试和审计 agent 行为。
  • 将相关上下文(如最近的提交、之前的错误)注入系统提示词,以改进 agent 的响应。
  • 在 DSH 工具中使用完整的内存 API(智能搜索、图查询、时间查询等)。
  • 构建高级工作流,使用内存槽、团队共享或哨兵触发器。

dsh-agentmemory DSH 插件适合谁

  • 使用 DeepSeek Harness 并希望为编码 agent 添加持久记忆的开发者。
  • 已经使用 agentmemory 并希望无需编写自定义工具包装即可无缝集成到 DSH 的用户。

dsh-agentmemory DSH 插件的限制

  • 需要同机运行 agentmemory 服务器(默认 http://127.0.0.1:3111)。
  • 部分功能默认关闭,需要显式配置(如 injectContext、dangerousTools)。
  • 如果服务器版本较旧,可能不支持所有端点;新端点可能尚未实现。
  • 破坏性/昂贵工具(governance_delete、heal、consolidate 等)需通过标志启用,默认不可用。

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

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

**agentmemory for DeepSeek Harness** — full `memory_*` tools, automatic capture hooks, and opt-in context injection over the local REST server. [English](./README.md) · [中文](./README.zh-CN.md) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](./LICENSE) [![CI](https://github.com/elementor-i/dsh-agentmemory/actions/workflows/ci.yml/badge.svg)](https://github.com/elementor-i/dsh-agentmemory/actions/workflows/ci.yml) [![dsh](https://img.shields.io/badge/dsh-%3E%3D0.0.1-orange)](https://github.com/deepseek-ai/deepseek-harness) </div> dsh-agentmemory connects [agentmemory](https://github.com/rohitg00/agentmemory), a local memory server for coding agents, to [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) (DSH). It exposes the full `memory_*` tool set, captures observations automatically from sessions, prompts, and tool activity, and can inject recalled context into the system prompt — all over the local REST server, with no MCP bridge required. ## Features - **Full tool surface** — all 54 `memory_*` tools (8 core) mapped to `/agentmemory/*`, plus `memory_observe` and a `memory_http` escape hatch for any endpoint. - **Automatic capture** — ses

阅读完整 README仓库许可: MIT

dsh-agentmemory DSH 插件常见问题

如何安装 dsh-agentmemory?

你可以通过 git clone 加配置补丁的方式安装,或者使用官方 CLI:`npx -p @deepseek-ai/dsh dsh plugin --profile web add github:elementor-i/dsh-agentmemory`,将 `web` 替换为你的配置文件名称。Oh-DSH-Desktop 的插件管理器也可以在插件入库后安装。

我需要单独运行 agentmemory 服务器吗?

是的,dsh-agentmemory 需要同机运行一个 agentmemory 服务器。默认情况下它期望服务器在 `http://127.0.0.1:3111`。请根据 agentmemory 的文档启动服务器。如果服务器不可用,插件会记录警告,memory_* 工具会返回错误,但 DeepSeek Harness 本身会继续正常运行。

安装这个插件后有哪些工具可用?

插件注册了 54 个 memory_* 工具,包括 8 个核心工具(memory_save、memory_recall、memory_smart_search、memory_sessions、memory_lesson_save、memory_consolidate、memory_reflect、memory_diagnose)以及许多其他工具如 memory_commits、memory_graph_query、memory_slots 等。另外还有两个额外工具:memory_observe 用于手动记录观察,memory_http 用于直接调用任意 /agentmemory/* 端点。

自动捕获是如何工作的?

插件挂钩到 DSH 的生命周期事件(会话创建、提示词提交、工具执行、子 agent 启动/停止等),并自动将观察记录发送到 agentmemory 服务器。捕获是非阻塞的——处理程序使用短超时且从不等待。你可以通过配置的 `hooks` 部分控制要捕获哪些事件。

插件支持上下文注入吗?

是的,但需要手动启用。在插件配置中设置 `injectContext: true`。启用后,在会话启动时,插件会从 agentmemory 服务器召回上下文并将其添加到系统提示词中。你可以通过 `injectMaxChars` 控制注入的最大字符数(默认 4000)。