stratagate-agentmemory: Layered Memory That Condenses Over Time for DeepSeek Harness

diqierjia/stratagate-agentmemory

Data & KnowledgeVerified
Listed on 2026-09-21
Page last updated 2026-10-04

StrataGate gives DeepSeek Harness local-first layered memory: recent turns stay detailed while older ones condense into events and a knowledge graph, with original records expandable on demand.

stratagate-agentmemory is a memory plugin for DeepSeek Harness that keeps an AI agent's conversation history from piling up unchecked. It splits each conversation block into six detail levels, L0–L5, keeping recent exchanges full while older ones grow concise, and extracts important decisions and preferences into traceable Events backed by a knowledge graph of the current state of people, projects and tools. An evidence gate checks sufficiency before answering, memory stays local-first, and a visual memory UI is included.

How to Install

install
npmdsh plugin --profile web add stratagate-dsh
Category
Data & Knowledge
Platform
DSH Plugin
Author
diqierjia
Distribution
Plugin

stratagate-agentmemory Key Features

L0–L5 layered memory, older turns condenseEvent timeline plus current-state graphEvidence gate re-searches when insufficientOnly actually used memories get reinforcedImport memory from other AI tools
Listed on dsh-plugin.org

stratagate-agentmemory Repo Summary

What Does It Do?

StrataGate is a DSH plugin for DeepSeek Harness that turns an AI agent's conversation history into layered memory which condenses itself over time. It solves the problem of context being flooded by long histories while older details still need to stay recoverable: recent conversations remain detailed, older ones grow concise, and important information persists as events and a knowledge graph. Maintained by diqierjia under the MIT license and written in TypeScript, it keeps memory local-first and ships with a visual memory UI.

Core Features

  • Layered memory views: every conversation block has six detail levels, L0–L5, so as dialogue accumulates older memories shift from full transcripts to key facts, short summaries and title indexes, cutting the context history consumes.
  • Expandable original records: complete source messages and tool records are preserved, so the agent can expand a memory to recover the original wording and context when details need checking.
  • Event timeline plus current-state graph: important decisions, preferences, plans and changes are extracted as Events that keep their source and distinguish when something was mentioned from when it happened, while the knowledge graph represents the current state of people, projects, organizations, tools and places, with new Events able to supplement or supersede earlier states.
  • Evidence gate: before answering, the agent assesses whether retrieved evidence is sufficient, and when it is not it searches again, expands Events or checks the original messages, stating uncertainty if the answer still cannot be confirmed.
  • Use-only reinforcement: search hits and automatic context injection do not reinforce a memory; only evidence actually used in the final answer raises the adoption count and resets the decay anchor, so a memory cannot reinforce itself merely by being retrieved often.
  • External memory import: memories brought in from other AIs become traceable Events and update the knowledge graph, while the original imported text stays preserved.

How to Use This Plugin?

Once enabled in DSH, the plugin takes over session memory automatically: as the conversation proceeds, history is condensed level by level, important information is extracted into Events and written to the knowledge graph, and no manual curation is needed. To verify details, ask the agent to expand the relevant memory and it will recover the original messages and tool records; you can also open the visual memory UI to inspect Event cards, the current-state graph and weight decay. Memories from other AIs can be brought in through the import path, which turns them into traceable Events, and before answering the plugin runs its evidence gate, continuing to search or plainly stating uncertainty when evidence is insufficient.

How to Troubleshoot This Plugin?

The README does not provide a dedicated troubleshooting section, so when something goes wrong, check your configuration against the official quick start and architecture notes and confirm the memory data directory is readable and writable; if retrieval results look off, first check whether the evidence gate declined to answer for lack of evidence, then expand the Event and trace back to the original messages to confirm the source.

This page is an independent rewrite of the plugin's official README — for authoritative documentation and the latest changes, refer to the source: diqierjia/stratagate-agentmemory. The plugin is third-party code that runs on your machine once installed; inclusion does not imply endorsement — please review the source before installing.

Install, update, and uninstall this plugin in the Plugin Market of DeepSeek Harness's DSH Plugin Hub

DSH Plugin FAQ