SuperAPI AI Directory

TencentDB Agent Memory - Tencent's open-source agent memory management tool

Author: AI小集 · Original source: AI工具集

What is TencentDB Agent Memory

TencentDB Agent Memory is a layered memory management tool for AI Agents open-sourced by the Tencent Cloud Database team under the MIT license. Through its original L0-L3 four-layer progressive memory architecture and context offloading + Mermaid task canvas technology, the tool provides Agents with short-term memory compression and long-term personalized memory capabilities, reducing Token consumption by up to 61.38% and increasing task success rate by 51.52%. It has been adapted for mainstream frameworks such as OpenClaw and Hermes.

TencentDB Agent Memory

Main features of TencentDB Agent Memory

  • Short-term memory compression: Raw tool results are moved to external storage through context offloading, and a Mermaid task canvas is used to retain a structured task graph, so that only summaries and indexes remain in the context.
  • Long-term personalized memory: Builds a four-layer progressive architecture of L0 raw dialogue → L1 atomic memory → L2 scenario chunking → L3 user profile, enabling the accumulation of cross-session user preferences.
  • White-box traceability: All memory layers are saved as human-readable files such as Markdown, JSONL, and Mermaid, supporting layer-by-layer tracing from high-level abstractions down to the underlying raw evidence.
  • Heterogeneous storage backends: By default, it uses local SQLite + sqlite-vec for zero-dependency deployment; advanced usage supports connecting to the Tencent Cloud Vector Database TCVDB to enable BM25 + Vector hybrid retrieval.
  • Multi-framework adaptation: It has been adapted for mainstream Agent frameworks such as OpenClaw and Hermes, supporting one-click plugin installation and integration.

How to use TencentDB Agent Memory

  • Install the plugin: In theOpenClawterminal, run the openclaw plugins install @tencentdb-agent-memory/memory-tencentdb command to install the memory plugin.
  • Restart the service: After installation is complete, run openclaw gateway restart to restart the gateway so the plugin takes effect.
  • Configure storage: By default, the local SQLite + sqlite-vec backend is used with no additional configuration required; for advanced use, you can configure the Tencent Cloud Vector Database TCVDB to enable hybrid retrieval.
  • Verify the effect: After restarting, observe the decrease in Token consumption and task state retention in long-task Agent sessions, and trace memory layer contents through locally readable files.

Core advantages of TencentDB Agent Memory

  • Significant cost reduction and efficiency improvement: In multi-task continuous Session experiments, Token consumption was reduced by up to 61.38%, while task success rate increased by 51.52% relatively, achieving optimization in both cost and experience.
  • White-box debuggability: All memory intermediate products are human-readable files, supporting 100% layer-by-layer tracing and retrieval, avoiding information loss caused by black-box compression.
  • Zero-dependency, ready to use out of the box: By default, it uses local SQLite storage with no need for external APIs or cloud services; installation and deployment can be completed with a single command.
  • Production-grade validation: It has been validated in real production environments on four types of long-chain tasks—programming, research, document analysis, and workflow orchestration—and converges stably.
  • Progressive abstraction: The original four-layer memory architecture increased user profile accuracy from 48% to 76% in the PersonaMem evaluation, nearly 59% higher than native OpenClaw.

Project address of TencentDB Agent Memory

  • GitHub repository:https://github.com/Tencent/TencentDB-Agent-Memory

Comparison of TencentDB Agent Memory with similar competing products

Comparison dimension TencentDB Agent Memory Mem0 Letta
Product positioning Layered memory engine (short-term compression + long-term memory) Lightweight memory layer (personalized fact storage) Full agent runtime (self-editing memory blocks)
Memory architecture L0-L3 four-layer progressive architecture Vector storage + LLM fact extraction Three-layer memory (core/recall/archival)
Short-term compression Context offloading + Mermaid canvas No dedicated short-term compression mechanism Agent autonomous context management
White-box traceability Full-chain human-readable files Black-box system management Black-box agent self-editing
Deployment dependencies Local SQLite with zero dependencies Requires an additional vector database backend GPU support recommended
Integration method OpenClaw/Hermes one-click plugin Broad SDK integration Requires migration to the Letta runtime
Open-source license MIT Apache 2.0 Apache 2.0
Applicable scenarios Long-task context compression and cross-session memory Large-scale user personalized memory Long-term autonomous agent operation

Application scenarios of TencentDB Agent Memory

  • Programming development assistant: Continuously remember coding standards, constraints, and progress milestones across multi-day code projects, avoiding repeated confirmation.
  • In-depth research and analysis: Maintain task state in long-chain tasks such as web search and research analysis, preventing reasoning breaks caused by the loss of intermediate results.
  • Workflow orchestration: Record execution paths and key states in multi-step automated workflows, supporting checkpoint resumption and state recovery for complex tasks.
  • Personalized customer service: Accumulate user preferences, historical requests, and profile information across sessions to provide a consistently personalized service experience.
  • Document analysis and processing: Compress historical context during paragraph-by-paragraph analysis of long documents to maintain the coherence and accuracy of the analysis logic.