lhdrc/dsh-df-memory
Project Overview项目介绍
This is a native plugin built specifically for DeepSeek Harness (DSH) Cordis framework. It connects the core memory functionality of the independent df-memory system from the lhdrc-agent-memory repository to DSH’s agent tool interface. Version 0.5.1 is currently published on npm, and there are two supported installation methods. Most users can install it via the DSH CLI plugin command, which will automatically pull the core dependency as an npm package without extra manual steps. Developers who want to modify or debug the plugin can clone both repos and link the plugin locally for development.
The plugin exposes over a dozen dedicated tools for DSH agents to interact with the df-memory system, covering every step from memory initialization to retrieval, writing, archiving, index rebuilding, skill management, and metric trend queries. After installation, it automatically adds a usage convention to the system prompt that reminds the model to use the provided tools instead of directly reading raw memory files. It is intended for DSH users and developers who want to add persistent layered memory capabilities to their AI agents, improving long-term task performance and knowledge retention over repeated interactions.
Users can configure multiple parameters via the cordis.yml config file, including memory repository root path, default brain ID, LLM bridge toggle, maximum character and count limits for skill injection, and number of injected memories. The plugin comes with several automatic hooks that work without manual trigger, including automatic session content ingestion, gated knowledge injection before steps, and experience injection on session start. If you get a "memory.yml not found" error on first run, you can either set an absolute path in the plugin config or call the memory_init tool to initialize a new memory repository for your workflow.
这是一个专为DeepSeek Harness(DSH)Cordis框架开发的原生插件,作用是将独立核心仓库lhdrc-agent-memory(df-memory)的分层记忆能力接入DSH的Agent工具接口。当前版本0.5.1已经发布到npm公源,支持两种安装方式:推荐普通用户使用DSH自带的插件命令安装,开发调试插件可以通过git克隆源码后本地链接安装。核心依赖会自动拉取,无需用户手动操作。
插件为DSH Agent提供了十余个记忆操作工具,覆盖记忆检索、读取、写入、归档、索引重建、技能管理、指标趋势查询等全流程功能。安装完成后会自动在系统提示词中添加使用约定,提醒模型严格按照规范调用工具,不直接读取记忆库的底层文件。适合需要为DSH Agent添加长期分层记忆能力的开发者和普通用户使用。
用户可以通过cordis.yml配置多个参数,包括记忆库根路径、默认脑ID、LLM桥接开关、技能注入字符和数量上限、注入条数等。插件自带多个自动挂钩行为,比如会话内容自动摄入、步骤前知识门控注入、启动时成熟经验注入,这些都无需用户手动触发。首次使用若提示找不到memory.yml,可手动配置绝对路径,或调用memory_init工具初始化新的记忆库。
请帮我安装这个 DSH 插件。安装前先完成【兼容性检查 + 安全性检查】,检查通过再动手。
插件:dsh-df-memory(lhdrc/dsh-df-memory)
仓库:https://github.com/lhdrc/dsh-df-memory
本站详情页:https://www.yhbd.top/plugins/lhdrc-dsh-df-memory/
本站登记:类型 plugin · 归类 原生 DSH 插件 · 许可证未声明 · ⭐ 2 · 最近提交 2026-08-17 · 主语言 TypeScript
按下面顺序执行,每步先把结论告诉我,再进入下一步:
【1 兼容性检查】
① 我这边:DSH 版本、Node 版本、操作系统、当前 profile(web / desktop)。
② 读它的 README、package.json、插件 manifest,列出它要求的 DSH 版本 / Node 版本 / 操作系统 / 外部依赖 / 需要另外先装的运行时。
③ 逐条比对,结论只写「满足 / 不满足 / 未知」三种;不满足的给出可行替代方案。
④ 检查是否和我已装的插件冲突:命令名重复、skill / tool 重名、端口占用、重复注册的 MCP server。
【2 安全性检查】
① 仓库可信度:和上面「本站登记」是否一致;star / fork 数、创建时间、最近提交,是否归档或长期停更。
② 安装脚本:逐行看 package.json 的 preinstall / install / postinstall,以及 install.sh、setup.ps1 之类脚本。出现 curl|bash、下载后直接执行、混淆代码、访问与插件功能无关的域名,立刻停下来告诉我,不要继续装。
③ 依赖:列出新增依赖,标出无人维护、或与知名包拼写近似的可疑包(typosquatting)。
④ 权限与副作用:它会读写哪些目录、访问哪些域名、需要哪些 DSH 权限(filesystem / network / shell / clipboard 等),以及怎么卸载和回滚。
⑤ 如果它要求 sudo / 管理员权限,或权限明显超出功能所需,先停下来问我。
【3 安装】
上面两步没有「不满足」和「高危项」时才执行;用官方推荐方式安装,不要自行提权。
【4 汇报】
用表格输出:检查项 / 结论 / 依据 / 是否需要我决策。拿不准的一律写「未知」并说明要我怎么确认——不要猜,也不要替我决定。
Send this message to DSH in your current session: it verifies compatibility and security first (answering met / not met / unknown item by item) and only installs once everything checks out — it will stop and ask you if it finds a high-risk item. The box scrolls; the copy is the full prompt. CLI install commands may not be accurate across systems, so DSH is the safer route.把上面这条消息直接发给当前会话里的 DSH:它会先核对兼容性与安全性(逐条给「满足 / 不满足 / 未知」),确认没问题再安装,有高危项会停下来问你。框内可滚动,复制到的是完整提示词;安装命令不一定准确,发给 DSH 更稳。
- No license declared - all rights reserved by default; ask the author before commercial use or redistribution未声明开源许可证 —— 默认「保留所有权利」,商用或再分发前先问作者
- Only 2 stars - very few users, little community feedback星标只有 2,几乎没人在用,遇到问题缺少社区反馈
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-df-memory
把 lhdrc/dsh-df-memory 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-df-memory
DeepSeek Harness(Cordis)插件:把 lhdrc-agent-memory(df-memory 核心仓)的记忆能力接入 agent 工具面。
当前版本 0.5.1(npm 已发布)。
安装
方式一:npm 安装(推荐)
dsh plugin --profile web add dsh-df-memory
# 或
cd <profile 目录> && pnpm add dsh-df-memory
核心库会作为依赖自动从 npm 拉取,无需手动安装。
方式二:clone 本地安装(开发用)
git clone https://github.com/lhdrc/lhdrc-agent-memory
git clone (https://github.com/lhdrc/dsh-df-memory.git)
# 本地 link 安装插件(改动插件源码即时生效)
dsh plugin --profile web add ./dsh-df-memory
# 或
dsh --patch ./dsh-df-memory/cordis.patch.yml
clone 方式下插件的核心依赖指向 npm;若需直接使用本地 core 源码,请手动改为
file:../lhdrc-agent-memory/packages/core。
安装后若 bundles 列表未自动更新,检查 profile package.json 的 dsh.profile.bundles 包含 dsh-df-memory。
主 API 是工具,不是读仓文件
Agent 应通过以下工具访问记忆,不要把 cat brains/… 或直接读 markdown 当作主路径:
| 工具 | 用途 |
|---|---|
memory_query |
检索相关记忆;可选 type 过滤(decision|lesson|note|experience|skill),命中带 schema_type 层标签。默认排除 skill 与 *.overview.md/*.abstract.md 侧车(显式 type=skill 时豁免;侧车原文仍可 memory_read)。experience/skill 命中额外带 eta_score/support/source_paths(snippet 优先 trigger)。可选 brain 覆盖本次调用的 brain |
memory_read |
读单个节点原文;可选 brain |
memory_remember |
LLM 编译写入(默认异步:返回 accepted+task_id;wait=true 同步等到 kept;无 Key 且无 bridge → E_DISABLED)。可选 brain |
memory_job_status |
查询 remember/compile 任务状态(.dfmemory/jobs/{brainId}/)。只给 task_id 时只查当前默认 brain,不扫其它 brain;可另传 brain |
memory_capture |
零 LLM 显式写一条 L0 笔记(captureNode,ADD-only,llm.provider=off 也可用)。可选 metric/value/unit/period 为该次 facts 记量纲(value 必须有 metric,metric 需至少一条 facts) |
memory_init |
在工作区初始化记忆仓(initMemoryRepo;git: init|existing|off) |
memory_tree |
只读盘点仓内目录/文件(listTree/renderTree) |
memory_forget |
软归档节点(status=archived,D17,记 ledger) |
memory_sync |
显式把 dirty 刷进 git 账本(flushRepoLedger explicit,等价 sync --commit) |
memory_brain |
brain 管理:list(含 sources / is_default)/ create(已有则保持) |
memory_rebuild_index |
从 md 重建索引(rebuildIndex;D1 索引可丢可重建) |
memory_events |
列出近期 ledger 事件(listLedgerEvents) |
memory_skill |
规则层:list / find / read / inject;skill 不混默认 memory_query。inject 经宿主 ctx.skills.register 登记为会话 skill(trigger + procedure 摘要,非全文)。可选 brain |
memory_skill_outcome |
显式打分 { name, success, note? } → eta_score/support/status;不因 success 自动 activate |
memory_trend |
查指标趋势 { metric, threshold?, direction?, brain? } → 扫 facts 的 metric/value 检测回归;points:[] 是合法结果(不报错)。数据用 memory_capture + metric/value 写入 |
Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →
ruvnet/ruflo
Tencent/WeKnora
EverMind-AI/EverOS
MemTensor/MemOS
plastic-labs/honcho
agentscope-ai/ReMe
zilliztech/memsearch
vshulcz/deja-vu