Tencent's Hy-Memory Fixes AI Agents That Forget You After 20 Sessions
Tencent's Hy-Memory plugin gives long-running agents a structured, evolving memory that outscores mem0 and Graphiti on every public benchmark

- Tencent releases Hy-Memory, a memory plugin for OpenClaw agents that structures long-term memory across 6 hierarchical layers.
- Top benchmark scores: 85.20% on LongMemEval and 76.91% on PersonaMem, beating mem0 (47%) and Graphiti (68.32%) on both.
- 8x faster writes than Graphiti with 70%+ fewer memory entries and 45%+ higher information density per entry.
- Evolution chains link memories with causal supersedes pointers, letting agents trace the full history of a user's changing preferences, not just the latest state.
- System 1/System 2 dual path: real-time writes during conversation, async background refinement of mental models and intent predictions after sessions end.
- Install via one command in OpenClaw; supports any OpenAI-compatible LLM and embedding endpoint. Currently OpenClaw-only with no standalone SDK announced.
Most AI agents have a memory problem that only reveals itself slowly. You use an agent for a few weeks, and somewhere around session twenty, it starts feeling dumber. It contradicts advice it gave you last month, forgets preferences you've stated three times, and treats every conversation like the first one. Memory-related failures are the most frequently reported category of reliability issues in production agent deployments, and agents that forget instructions mid-task or gradually degrade over long sessions are not edge cases. They're the default.
Tencent's Hunyuan team just shipped Hy-Memory, a memory plugin designed to fix this at the architectural level. It features a 6-layer memory framework, System1/System2 dual systems, and an evolution chain mechanism to address memory fragmentation, information loss, and cognitive iteration issues in long-term collaboration scenarios. It's currently available as a plugin for OpenClaw, the open-source agent framework that has become a major platform in the agent ecosystem.
The problem nobody talks about until it's too late
AI agent memory is a persistent storage layer that lets an agent retain information across sessions. Without it, every conversation starts from zero. With memory, the agent remembers what a user said previously, how their needs changed, and which issues were resolved. Simple enough in theory. The problem is that most implementations just append new facts to a growing list, and that list becomes noise.
The main gap in existing frameworks is the absence of a temporal model: memories are stored and retrieved, not modeled as time-bounded facts that can be superseded. For agents that need to reason about how things changed, this is a meaningful gap. Imagine an agent that remembers you loved a platform you later publicly rejected. It doesn't know you changed your mind, because it stored the old fact and the new fact side by side with no causal link between them.
Hy-Memory focuses on the hardest part of long-running agent collaboration: remembering not just facts, but evolving preferences, causal history, and paths the user has already rejected.
Six layers, two speeds
The core architecture is a 6-layer memory stack, split into two processing paths borrowed from cognitive science. System 1 and System 2 here refer to the dual-process theory of thinking: fast, automatic responses versus slow, deliberate reasoning. Hy-Memory applies the same split to memory writes.
- System 1 (millisecond-level, synchronous): Writes raw conversation traces (L1), extracts atomic facts (L2), updates the identity profile (L3), and compresses a session summary (L4) in real time, during the conversation.
- System 2 (seconds-to-minutes, asynchronous): Runs in the background after the session to build higher-order abstractions: a mental model of the user's cognitive patterns (L5) and forward intent predictions (L6).
System 1 handles real-time writing at millisecond-level, and System 2 performs deep cognitive processing in the background at second-to-minute level, balancing speed and cognitive depth. The practical effect is that the agent stays responsive during conversation while a background process continuously refines its understanding of who you are.
The evolution chain: what makes this different
The most technically interesting piece is the evolution chain. An evolution chain mechanism links old and new memories into a chain via supersedes pointers, ensuring the agent can trace the complete evolution of user preferences rather than just remembering the latest state or losing the intermediate steps.
Here's why that matters in practice. Say a user tries a streaming platform, grows disillusioned, publicly abandons it, then asks their agent about a new release on that platform. A vector-based retrieval system will match the query to the earliest positive memory and the latest rejection, but miss the middle steps that explain the emotional arc. Hy-Memory's supersedes chain links all four states causally, so when the agent retrieves the latest node, the entire history surfaces automatically.
This is something vector similarity search fundamentally cannot do. RAG-backed memory systems retrieve context based on embedding similarity, but embedding similarity does not equal factual relevance. A query might retrieve a stored memory that is semantically close but factually orthogonal, and the agent then incorporates this irrelevant context with high confidence. The supersedes pointer bypasses the similarity problem entirely by using pre-written causal structure.
Benchmark numbers
Hy-Memory has been benchmarked on LongMemEval and PersonaMem, two authoritative evaluations for long-term memory. LongMemEval is the ICLR 2025 benchmark for evaluating long-term memory in conversational AI, developed by UCLA and Tencent AI Lab, measuring how well agents retain and use information across extended conversations.
| Framework | LongMemEval | PersonaMem | Write speed (s/k tokens) | Avg. memories per user |
|---|---|---|---|---|
| mem0 | 47.00% | 65.82% | 15.6 | 309.8 |
| Graphiti | 68.32% | 64.86% | 97.8 | 362.3 |
| Hy-Memory | 85.20% | 76.91% | 12.3 | 82.3 |
Hy-Memory not only outperforms all comparable systems but also achieves the highest scores in four out of six LongMemEval dimensions, particularly excelling in preference (+21.11 percentage points), temporal reasoning (+9.63pp), and knowledge updating (+21.37pp), which are the most demanding aspects of evolutionary capability.
The efficiency numbers are arguably more interesting than the accuracy scores. Memory usage is reduced by over 70%, information density increases by 45%, token consumption drops by 35%, and write speed is eight times faster than Graphiti. Fewer memories at higher density means the agent can pack more actionable context into the same token budget. Hy-Memory's high density enables OpenClaw to access 3-4x more actionable information within the same token budget compared to other memory systems.
Three tiers for different use cases
Hy-Memory ships with three configuration modes, trading off cost and capability:
- Lite (
enable_agent=false): Pure vector write and retrieval, zero LLM cost. Best for teams that need persistence now and can optimize later. - Pro (
enable_agent=true): Adds a MemAgent that synchronously handles extraction, summarization, and deduplication. No background worker required. - Ultra (full pipeline): Runs both System 1 and System 2. The background worker continuously refines the L5 mental model and L6 intent predictions. Best for agents that need to get smarter the longer they run.
How to plug it in
Installation is a single command inside the OpenClaw plugin system. You'll need Python 3.8+, an LLM API key (any OpenAI-compatible endpoint works, including DeepSeek, Hunyuan via OpenRouter, or a local vLLM deployment), and an embedding service. The docs recommend BAAI/bge-m3 via SiliconFlow as the embedding model.
# Install the plugin
openclaw plugins install openclaw-hy-memory --dangerously-force-unsafe-install
# Run the interactive config wizard
openclaw hy-memory init
# Restart the gateway
openclaw gateway restart
# Verify everything is healthy
openclaw hy-memory statusThe --dangerously-force-unsafe-install flag is required because Hy-Memory runs as a local Python subprocess alongside the OpenClaw gateway. OpenClaw blocks external process plugins by default, so you need to explicitly opt in. The config accepts any OpenAI-compatible LLM and embedding endpoint, so you're not locked into Tencent's own models.
The bigger picture
In 2026, memory is treated as a dedicated architectural component separate from the model's context window, not just a longer prompt. The field has moved from "stuff more tokens in" to "build a structured cognitive layer that persists and evolves." Deloitte's 2026 analysis estimates that by 2027, about 50% of companies using generative AI will be running agentic AI pilots or proofs of concept, up from 25% in 2025.
What Hy-Memory contributes to this picture is a concrete answer to the hardest sub-problem: not just "can the agent remember facts" but "can it understand how a user's beliefs, preferences, and decisions have changed over time, and why." The agent memory space will likely see consolidation in H2 2026, as the current proliferation reflects genuine uncertainty about whether this layer belongs in the agent itself, the memory backend, the context loader, or the file system. Hy-Memory bets firmly on a dedicated structured layer with causal pointers, and the benchmark numbers suggest that bet is paying off.
The current limitation worth noting: Hy-Memory is today exclusively a plugin for OpenClaw. If you're building on LangGraph, LlamaIndex, or a custom agent runtime, you can't yet plug this in directly. The team has not announced a standalone SDK or framework-agnostic release. For OpenClaw users, though, this is available now and free to try.