memory-systems

Design short-term, long-term, and graph-based memory architectures

Author

Install

Hot:7

Download and extract to your skills directory

Copy command and send to OpenClaw for auto-install:

Download and install this skill https://openskills.cc/api/download?slug=sickn33-skills-memory-systems&locale=en&source=copy

Memory Systems — Agent Memory System Design Guide

Skill Overview


Memory Systems provides a complete design guide for an agent’s memory architecture, including layered implementations of short-term memory, long-term memory, and temporal knowledge graphs. It helps build AI agents that can persist across sessions, track entity relationships, and perform temporal reasoning.

Use Cases

1. Agents that need persistence across sessions


When an agent must maintain state across multiple conversations, learn user preferences, or accumulate domain knowledge, Memory Systems offers an end-to-end architecture plan—from the file system to a temporal knowledge graph—ensuring information is not lost when a session ends.

2. AI systems that need entity relationship tracking


When the application must identify and track whether “John Doe” in different conversations is the same person, or understand relationships like “Customer A purchased Product B,” the Entity Memory and Knowledge Graph modes can maintain entity consistency and relationship structure.

3. Applications that require temporal reasoning


When you need to answer time-sensitive questions such as “What was the user’s address on date X?”, the Temporal Knowledge Graph sets an effective period for facts. This supports “time travel” queries and prevents conflicts caused by outdated information.

Core Features

Layered memory architecture


Provides a full layered design from working memory (Context Window) to short-term memory, long-term memory, entity memory, and temporal knowledge graphs. Each layer has different latency, capacity, and persistence characteristics, allowing flexible selection based on your needs.

Multiple implementation modes


Covers four core implementation modes: in-memory file system, metadata-enhanced Vector RAG, knowledge graphs, and temporal knowledge graphs. It also provides three retrieval modes—semantic retrieval, entity retrieval, and temporal retrieval—adapting to different levels of query complexity.

Memory integration and optimization


Includes memory consolidation trigger mechanisms and processing workflows, as well as integration strategies with the context system (immediate loading, strategy injection). This ensures the memory store does not grow indefinitely and that retrieved content can be efficiently integrated into the agent’s reasoning process.

Common Questions

What are the differences between Vector RAG and knowledge graphs?


Vector RAG performs semantic retrieval based on embedding similarity, which is suitable for document lookup but loses relationship structure. Knowledge graphs explicitly store relationships between entities, enabling traversal queries and complex reasoning. According to the Deep Memory Retrieval benchmark, Zep (temporal knowledge graph) achieves 94.8% accuracy, while traditional Vector RAG is approximately 60–70%.

How do I choose the right memory architecture for my agent?


If you only need simple persistence, use file-system memory. If you need semantic search, use metadata-enhanced Vector RAG. If you need relationship reasoning, choose a knowledge graph. If you need to handle time-sensitive information (e.g., status changes), use a temporal knowledge graph. The choice should be based on query complexity, infrastructure constraints, and accuracy requirements.

What is a temporal knowledge graph?


A temporal knowledge graph extends a standard knowledge graph by adding “valid_from” and an optional “valid_until” timestamp to each fact, making facts time-effective. This supports time-travel queries like “What was an entity’s state at a particular time point?”, prevents conflicts between outdated and new information, and enables temporal reasoning and analysis of an entity’s historical changes.