The core value of DSH lies in its flexible plugin architecture. However, in real-world development, agents often struggle to retain previous conversation context, user preferences, or the currently active project. ly028716/dsh-memory-plugin solves this problem. It is a smart memory system plugin designed for DeepSeek Harness (DSH).
Introduction¶
This plugin is maintained by ly028716, uses the MIT License, and is categorized as a memory plugin. Its core goal is to automatically recommend models, agents, and tool configurations based on historical data, helping developers reduce repetitive configuration and improve workflow efficiency.
Core Features¶
The plugin provides the following core capabilities:
* Intelligent Recommendation Engine: Automatically recommends models, agents, and tool configurations based on historical data.
* Tool Usage Tracking: Automatically records the usage frequency of commonly used tools (such as read, write, edit, etc.).
* Preference Memory: Remembers commonly used agents, LLMs, language settings, and code style.
* Project Context: Tracks active projects, access history, and project tags.
* Session History: Records discussion topics, completed tasks, and work patterns.
* Persistent Storage: Stores data locally in JSON format, supporting automatic saving, import, and export.
* Privacy Protection: All data is stored locally, with no cloud synchronization, giving users full control over their data.
* Web Viewer: Provides a polished visual interface for viewing memory data.
Installation and Activation¶
Install the plugin using an npm package:
dsh plugin --profile <name> add @ly028716/dsh-memory-plugin
Typical Usage¶
The plugin provides a JavaScript API through the ctx.memory object, allowing developers to make explicit calls:
// 获取智能推荐
const recs = ctx.memory.getRecommendations('coding');
// 设置偏好
await ctx.memory.setPreference('defaultModel', 'qwen3.7-plus');
// 记录会话
await ctx.memory.recordTopic('implement authentication');
// 添加项目
await ctx.memory.addProject({ path: '/projects/my-app', name: 'my-app', tags: ['react', 'typescript'] });
// 查看统计
const stats = ctx.memory.getStats();
Notes¶
- No Automatic Collection by Default: The plugin does not collect data automatically by default. The
trackswitch isfalseby default. - Local Storage: All data is stored locally, with no cloud synchronization.
- Compatibility Range: The required DSH CLI compatibility range is
>=0.1.1-rc.2 <0.2.0. - Clearing Memory: The
forgettool requiresallowClearMemory: trueto be configured before it can be used.
Summary¶
If you are looking for a controllable, localized memory solution to enhance DSH’s intelligent capabilities, this plugin provides a fact-based solution. For more details, refer to the community directory or the GitHub repository.