Skip to main content

How to use dsh-mneme

Provides cross-session persistent memory for DeepSeek Harness using SQLite + editable Markdown dual mirroring, with automatic background deduplication, merging, and session summarization.

This article is auto-derived from indexed fields (wiki / faq / compatibility_json), not freshly AI-generated.

This article is derived from the plugin's already-indexed fields (wiki / faq / compatibility_json / readme), not freshly generated by AI. Source field is noted at the end of each section.

Quick start

dsh-mneme

— source: plugin_wiki.wiki_content

Install & verify

dsh plugin --profile web add @modusensus/dsh-mneme

Run the command above in your DSH Web Profile. Then enable the plugin in the plugin list.

— source: plugins.install

Key points

  • 跨会话记忆 — 对话中 AI 自动记录关键信息,新会话自动注入相关记忆
  • 自动整理 — 后台自动去重、合并、归档,记忆库越用越精炼
  • 删对话 ≠ 删记忆 — 删除聊天窗口不会丢掉已保存的记忆(可配置)
  • 你的数据你做主 — 所有记忆以 Markdown 格式存于本地,随时打开查看和编辑
  • 完全离线 — 默认无需 API Key,所有处理在本地完成

— source: plugin_wiki.readme_en (fallback readme_raw)

FAQ

Is it ready to use after installation? Does it need internet connection?

Ready to use by default. The default embedProvider=openai uses external Embeddings API; to be completely offline, just change the config item embedProvider to local (enables local ONNX model).

Where is memory stored? Can it be manually edited?

Stored by default in ~/.dsh/memory/, divided into two parts: memory.db is the SQLite main database; preferences.md / projects.md / decisions.md / history.md / summary.md are human-editable Markdown mirrors, and manual edits will be prioritized and written back to the main database on next sync.

Does deleting a session also delete the associated memory?

By default no (sessionLifecycleEnabled=false). Deleting a session only clears the DSH internal window; to use it as an 'archive point', enable this switch so that when a session is deleted, its born memories are softly hidden (no longer injected/retrieved, but still restorable).

How to delete a specific unwanted memory?

Have the model call the memory_delete tool, pass id to precisely delete, or pass query to let the system select the best match for deletion by text description. Archive (memory_archive) and suppress injection (memory_forget) can be restored; memory_delete is physical deletion.

Why do background autoDream? Will it be expensive?

autoDream is a threshold-triggered lightweight organization (default triggers when memory count ≥10 or total characters ≥5000), running asynchronously without blocking conversation. If it feels too frequent, you can raise dreamThresholdCount / dreamThresholdChars, or turn off autoDream. Each run writes an audit table dream_runs for traceability.

Does it support vector/semantic search?

Yes. The frontend 'Memory' panel has a 'Semantic' toggle; the backend supports three embedProvider options: openai (compatible with SiliconFlow / Zhipu / self-hosted), local (local ONNX, zero network), oollama. Vector failure automatically falls back to keyword search, not affecting basic functionality.

Worried about prompts being stolen and uploaded by memory?

All data is stored locally in ~/.dsh/memory/, with no tracking, no remote logs. External Embeddings API calls only happen when you explicitly configure embedProvider=openai and provide baseUrl/apiKey to DSH; in local mode, even this step is skipped.

— source: plugin_wiki.faq_json

Compatibility

  • DSH: >= 0.1.0-rc.6
  • Node: >= 24.0.0

— source: plugin_wiki.compatibility_json

Pitfalls

Review the upstream repo before installing. This guide is auto-derived from indexed fields and may lag the latest release. If anything contradicts the official docs, treat the upstream source as authoritative.

— source: general rule