dsh-auto-memory: Persistent Cross-Session Memory for DeepSeek Harness
asktheway/dsh-auto-memory
Native persistent memory for DeepSeek Harness: typed Markdown memory files with a MEMORY.md index auto-injected into the system prompt, so your agent remembers across sessions with no external services.
dsh-auto-memory is a DSH plugin that gives DeepSeek Harness the memory subsystem it lacks, so the agent no longer starts from zero in every new session. Memories are kept as ordinary local Markdown files while an index is auto-injected into the system prompt, with no external services, databases, or embeddings involved. Memories come in user, feedback, project, and reference types, layered by workspace and user scope to prevent cross-project leakage, and stay hand-editable, grep-able, and git-friendly. It is maintained by AskTheWay under the MIT license and written in TypeScript.
How to Install
dsh plugin --profile web add dsh-auto-memory- Category
- Data & Knowledge
- Platform
- DSH Plugin
- Author
- asktheway
- Distribution
- Plugin
dsh-auto-memory Key Features
dsh-auto-memory Repo Summary
What Does It Do?
asktheway/dsh-auto-memory is a DSH plugin for DeepSeek Harness that brings Claude Code-style persistent memory to the harness natively. It solves the problem that DSH ships with no memory subsystem at all, so every new session starts from zero. Memories are stored as plain Markdown files on disk, and an index is auto-injected into the system prompt with no external services, databases, or embeddings required. It is maintained by AskTheWay under the MIT license, written in TypeScript, and last updated in 2026-09.
Core Features
- Automatic index injection: every request carries one system-prompt section, re-evaluated per step and byte-budgeted, costing zero tokens when the store is empty.
- Typed memories: user, feedback, project, and reference types, written with a dedupe-and-update discipline, absolute dates only, and double-bracket cross-links between memories.
- Workspace and user scope layers: memories are layered by scope so nothing leaks across projects.
- File-only storage: memories are ordinary Markdown files under the DSH home directory, hand-editable, grep-able, and git-friendly.
- Hardened internals: cross-process locks with orphan-lock self-healing, symlink-read protection, malformed-file tolerance, stable index ordering, plus guards against reserved-name collisions on case-insensitive filesystems and brace sequences that could poison prompts.
How to Use This Plugin?
After enabling it in DSH, simply tell the agent something worth remembering, such as "Remember: I'm a Python backend engineer preparing for interviews," and the model calls the memory write, read, list, and delete tools on its own. Open a brand-new session the next day, ask what it knows about you, and it recalls the record. To see it first, run the bundled demo script, which needs no API key or browser and walks through write, index, inject, recall, and forget. Memory files live in the memory directory under the DSH home path, and behavior can be adjusted by overriding config values in your profile.
How to Troubleshoot This Plugin?
A memory write that appears to succeed but loses the record usually happens on case-insensitive filesystems where a memory name collides with the index file name; the plugin blocks this with a reserved-name guard. If every model request in a workspace suddenly fails, a memory likely contained three literal braces, a risk the plugin neutralizes with a converging sanitizer. If the memory store seems locked, rely on orphan-lock self-healing and repair it as described in the official documentation.
This page is an independent rewrite of the plugin's official README — for authoritative documentation and the latest changes, refer to the source: asktheway/dsh-auto-memory. The plugin is third-party code that runs on your machine once installed; inclusion does not imply endorsement — please review the source before installing.
