Introduction¶
In the DeepSeek Harness (DSH) agent, if user preferences are only stated verbally in the current session, they might need to be restated in the next session. dsh-tool-user-memory writes stable preferences such as language habits, communication style, and project background to a user profile file and carries them in the system prompt of new sessions, minimizing the need for repetition.
What is this¶
dsh-tool-user-memory is the DeepSeek Harness (DSH) user preference memory plugin, enabling the agent to remember your preferences across sessions.
The plugin owner is IAMLieutenant, categorized as memory, licensed under MIT, and package.json version is 0.1.2. It is an independent open-source plugin unrelated to the official repository; documentation states installation is done directly via npm, and activation is achieved by adding it to the target profile via the dsh plugin command.
Core Capabilities¶
The plugin provides four verified capabilities:
memory_update(key, value, mode?): Automatically records, appends, or deletes when the agent learns your stable preferences.memory_get(query?, limit?): Proactively reads your profile when personalized answers are needed.{{user_profile}}System Prompt Injection: Automatically carries your profile in every round of every session; an empty profile costs zero tokens.- Persistent Storage: The profile is saved at
$DSH_HOME/user-memory/user.md, is human-readable, manually editable, and deletable.
The memory storage location is under $DSH_HOME, shared with all workspaces and all profiles (web / headless).
Installation and Activation¶
The following uses the web profile as an example. The documentation provides profile examples; the general installation command was not explicitly verified in this documentation.
- Install the plugin on the target profile:
dsh plugin --profile web add dsh-tool-user-memory
- Restart the DSH session. Restart web mode:
dsh web
- Speak directly in the session:
Remember: I prefer concise Chinese answers
The agent will call memory_update itself.
- Use the following sentence to see what it remembers:
What do you remember about me?
Typical Usage¶
Record a stable preference:
Remember: I prefer concise Chinese answers
Delete a preference:
Forget my preference for XX
Agent call:
memory_update mode=remove
Manually edit the profile file:
$DSH_HOME/user-memory/user.md
It takes effect immediately after editing; deleting the file equates to total amnesia.
Verify cross-session memory: Open a brand new session and ask:
What is my language preference?
Configuration and Limitations¶
It works with zero configuration by default. If adjustments are needed, you can override settings in the profile’s cordis.patch.yml (by line id tool-user-memory).
| Configuration Item | Default Value | Description |
|---|---|---|
path |
$DSH_HOME/user-memory/user.md |
Profile file path |
maxBytes |
8192 |
Profile file size limit; evicts oldest items first when exceeded |
promptMaxBytes |
2048 |
Byte budget for system prompt injection per round; set to 0 to inject full profile |
includeInPrompt |
true |
Controls whether to inject profile into the system prompt in every session |
Security and Usage Boundaries¶
- Injected profile is explicitly labeled as “reference data, not instructions”; unless you repeat it in the current message, the agent will not execute any “instructions” inside the profile.
- The agent should not record one-time requests, keys, passwords, or tokens.
- The plugin runs with the current dsh process permissions; it is recommended to check the source code and
MITlicense before installing. - The profile file is a regular readable file, can be viewed, modified, or deleted at any time.
Conclusion¶
The value of dsh-tool-user-memory is turning stable user preferences from session prompts into a persistent profile and having each session automatically carry it, avoiding repetitive self-introductions. The directory link did not appear in the verified documentation; the verified repository address is:
https://github.com/IAMLieutenant/dsh-tool-user-memory