MemVault is a local long-term memory service consisting of a SQLite store and a FastAPI/CLI pipeline. However, it functions as a stdio MCP server. Since MCP is a “pull” protocol where the server can only be invoked, there is no channel to push content directly into the model context. Therefore, “memory loading” cannot be achieved from the MCP side; it must be handled by the client, specifically this plugin.
Plugin Positioning¶
dsh-memvault is a memory plugin for DeepSeek Harness (DSH). It aims to bridge the storage layer of MemVault with the context layer of DSH.
Maintainer: zhang66633
License: MIT
Category: Memory
Core Functions¶
The plugin primarily operates across three dimensions:
-
Injection (Read)
Core memory blocks are injected into the system prompt. This is achieved viactx.systemPrompt.context()to provide dynamic runtime context contributions, allowing the model to “have” these memories at every step without needing to call a tool. -
Extraction (Write)
Completed conversation turns accumulate in a window, which is then submitted as a complete dialogue to MemVault’s extraction/vectorization pipeline. The mechanism involves listening forturn/endevents viactx.on('session/event')and subsequently callingpython -m memvault.cli add --stdin. -
Visualization (Panel)
Provides a tangible memory panel. The interface is served via five specific Host routes (/memvault/api/*). The panel includes a conversation tab and a settings page, supporting the viewing of current injected content, reviewing extraction results, editing core blocks, and browsing stored content.
Installation and Activation¶
Since the official CLI installation command was not verified in the provided materials, please install manually via the following steps:
- Clone the repository:
git clone https://github.com/zhang66633/dsh-memvault.git - The plugin is a pure ESM module with no bundler dependencies and requires no additional build steps.
- Reference the module path in the DeepSeek Harness plugin configuration.
Usage Instructions¶
Before use, ensure that the MemVault Python pipeline (CLI subprocess) is running and that the memvault.db file exists locally.
- Configure Paths
In the memory panel, verify that the current storage file, plugin state file, Python script directory, and project directory are correct. The panel will indicate which Scopes are read-only and which are writable. - View and Edit
In the “Memory” tab, you can view the core blocks currently injected into the system prompt. Editing and deletion operations are supported, and you can also create new core blocks. - Review and Track
Via the extraction results page, you can view the output of the last five extraction runs. Clicking on a specific memory entry opens MemVault’s audit chain (history) and relationship graph (relations). You can mark entries for review and directly copy correction requests. - Browse Storage
In the storage browsing view, you can search the memory table via substrings, filter by type and Scope, and paginate results. You can view the type, scope, age, and ID of each memory entry.
Notes¶
- Runtime Dependencies: The plugin itself has zero runtime dependencies, utilizing only built-in Node.js modules (
node:sqlite,node:child_process,node:fs). - Database Access: The plugin connects directly to the SQLite database in read-only mode without relying on an additional HTTP server.
- Restart Safety: The pending window (bounded rendered conversation history) is written to a state file at the end of each turn, so restarts between turns will not result in memory loss.
- Background Extraction: Extraction operations run when the session is idle (e.g., when the user pauses to wait for an answer). They do not block the critical path where the model is waiting for an answer, and a single invocation can cover multiple turns.
Ecosystem Context¶
DeepSeek Harness’s philosophy is “Everything is a Plugin.” This plugin serves as the DSH-specific layer for MemVault and is decoupled from MemVault’s own general-purpose MCP service. With this plugin installed, memory is no longer something the model needs to “remember” to look up, but rather context that is already loaded.