Introduction¶
When DeepSeek Harness (DSH) handles complex tasks, tool logs can quickly blow up the context window. The dsh-memory-canvas plugin solves this problem. It offloads large amounts of tool logs to the local file system while keeping the Mermaid structure of the task canvas in context and using node_id for memory recall. The plugin is maintained by guobinmengxiang-rgb and does not require a background daemon.
Core Features¶
The plugin enables memory management by exposing the following tools for the agent to call:
-
memory_offload
- Parameters:
title(required),body(required). - Result: returns a short
idand file path, then updates the canvas.
- Parameters:
-
memory_recall
- Parameters:
id(required). - Result: returns the stored
body(truncated to 8k characters, with a note indicating truncation).
- Parameters:
-
memory_canvas
- Parameters: None.
- Result: returns the Mermaid markdown for the task canvas.
Storage and Limitations
* By default, storage paths are <cwd>/.dsh-memory/canvas.md and <cwd>/.dsh-memory/refs/{id}.md.
* The root directory can be overridden with the DSH_MEMORY_DIR environment variable.
* Canvas nodes use 24-character titles; the full text is stored under the refs/ directory.
Installation and Enablement¶
- Install the plugin into the specified configuration profile:
dsh plugin --profile web add github:guobinmengxiang-rgb/dsh-memory-canvas
- Check whether the configuration layer has been added (no need to start a process):
dsh --profile web --dump-config
You should see the `dsh-memory-canvas` layer. Once confirmed, start the profile as usual.
Typical Usage¶
The agent must explicitly call the tools above; the plugin does not automatically intercept tool logs. The repository includes a demo.mjs example that demonstrates the full workflow: writing to refs/, printing the canvas, recalling by ID, and asserting that the body matches.
Notes¶
- Developer Preview: DeepSeek Harness is in developer preview and may contain breaking changes.
- Local Runtime: The plugin runs on your machine and does not involve cloud data transfer.
- Tool Distinction: Do not install the wrong
dsh. The official CLI isnpx @deepseek-ai/dsh web. The PyPI packagedeepseek-harness-cliis a different tool (fordsh doctor/dsh chat). - Configuration File: The plugin’s
cordis.patch.ymlbundle uses the package namedsh-memory-canvasrather than a file system path.
Summary¶
dsh-memory-canvas provides a lightweight, file-based memory layer, suitable for DSH agent tasks that need to manage large volumes of tool output. For more details and source code, see the GitHub repository.