Long-term memory for DSH: injects your Markdown memory file at each session start, adds read/write/recall/undo tools with backup and audit, and lists your detailed profile files (interests / profile / project notes) with guidance on when to read them. Zero dependencies; never opens a network connection.
Install
# from GitHub (first run asks for allowBuilds approval — follow the hint, retry)
dsh plugin --profile web add github:wojiao42/dsh-long-term-memory
Any plugin you install runs third-party code with your own permissions — it can read your files, use your credentials, and reach the network, and tool approvals don’t sandbox it. GitHub-sourced plugins also run build scripts at install time — pnpm blocks those until you allow them, so an install can stop with ERR_PNPM_GIT_DEP_PREPARE_NOT_ALLOWED or ERR_PNPM_IGNORED_BUILDS; dsh prints the exact key to add under allowBuilds in your profile’s pnpm-workspace.yaml, and the install works on the next run. Allowing a build is a trust decision: only install sources you trust, and pin a commit (github:owner/repo#sha).
README
Renamed from
dsh-memory-filein v2.0.0. Data format and config are fully compatible.
简体中文(完整版) · English (abridged)
This is an abridged English version. The Chinese README is the source of truth; details that change often (design notes, changelog, screenshots) live there.
File-backed long-term memory for DeepSeek Harness: injects your own Markdown memory file at each session start, and adds tools to write it, queue uncertain lines for review, undo a bad write, and audit what it actually read. Reads no conversations by default, never opens a network connection, never deletes files.
What it does
- Injects your Markdown memory file once per session (the first
pre-step), so it is not re-sent on every turn. - 7 agent tools:
memory_add,memory_recall,memory_list,memory_undo,memory_pending,memory_scan,memory_status. - Every write is backed up in full first;
memory_undorestores the previous file; low-confidence lines go toMEMORY.pending.mdinstead of the memory file. - Optional
autoScan(default off): reads local session logs only to surface your own recent lines, so the agent can file them. memory_statusreportsDSH_HOMEand session counts, so a moved harness home does not look like "all history is gone".
Quick start
GUI (recommended on desktop): Settings (Ctrl+,) → Plugin market → Custom install → github:wojiao42/dsh-long-term-memory, then restart DSH.
The desktop profile is app-managed: running
dsh plugin --profile desktop addmay be rejected; if it is, use the GUI step above.
Command line (Web profile):
dsh plugin --profile web add github:wojiao42/dsh-long-term-memory
Refresh the page afterwards.
Local source: Plugin market → Custom install → the absolute path on your machine; restart DSH after code changes (the install is a copy, not a link).
Key limits
- Reads no
messages: the only subscription isagent/pre-step, whose arguments never destructure them. - Session logs are not read unless
autoScan: true; that scan is read-only, capped at 8MB per file and 32MB per run. - No network calls, no
child_process, norm/rename/chmod. - Writes only to the memory file, its
backup/,MEMORY.pending.mdand.autoscan.json; all paths are derived, never passed in. memory_recallis literal keyword search, not semantic search.memory_adddoes not deduplicate.memory_undorolls back the whole file, not one line.
Compatibility
- Install sources: npm / github / local path.
- Host-side plugin for DSH Desktop and DSH Web; no client UI, so no
dsh.client(enabled viadsh.bundle.patch). - Dependencies: only
@deepseek-ai/dsh-llmand@deepseek-ai/dsh-tools, both provided by the host. No third-party packages. - No
enginesorpeerDependenciesdeclared. Node must providezlib.zstdDecompressSync(Node 22.15 / 23.8+). - Self-test, both offline:
node smoke.mjs(51 assertions) andnode tools/publish-test.mjs(25 assertions).
License
MIT. See LICENSE.
Links
More in this category
vectorize-io/hindsight#coding-agents★ 61388
Hindsight, agent memory that learns: long-term project memory with auto recall and retain, knowledge pages, deep reflection, and per-repo memory banks.
volcengine/OpenViking#examples/dsh-memory-plugin★ 42311
OpenViking memory and context bundle for DeepSeek Harness: pre-step auto-recall and profile injection, session capture, `viking://` URI guarding, and recall/write memory tools backed by an OpenViking server.
MemTensor/MemOS#memos-local-plugin★ 12417
Local-first memory plugin for DeepSeek Harness: layered L1/L2/L3 memory with automatic capture, manual memos_* retrieval tools, and a built-in memory viewer.
agentscope-ai/ReMe#dsh★ 3812
Connects DeepSeek Harness to ReMe's local-first, self-evolving personal knowledge base: automatically captures completed main-agent conversations as user-owned Markdown memory, searches conversations and source material through reme_search with BM25, optional embeddings, and wikilink expansion, and schedules daily memory consolidation.
zilliztech/memsearch#MemSearch★ 2889
Shared Markdown memory for DSH and other coding agents, with automatic capture, pre-step context injection, searchable recall, and memory-to-skill self-evolution through a review panel.
vshulcz/deja-vu#extensions/dsh★ 1578
Cross-session memory and context recovery across forty-five other coding agents (45+) on this machine, reading session files they already wrote before install (Claude Code, Codex, Cursor, Windsurf, Trae, Antigravity, VS Code Copilot Chat, opencode, OpenClaw, Hermes, Kimi, Qoder, Cline, Zed, Magpie and more): six tools (deja_recall, deja_session, deja_blame, deja_fix, deja_how, deja_remember), a /deja command, and optional automatic recall injected into runtime context. Local BM25 CLI/MCP index, no LLM, no embeddings, no network (dsh plugin --profile web add dsh-deja).
Community comments
Comments are public GitHub Discussions. Loading them connects to GitHub and Giscus; a GitHub account is required to post.