Sign up Log in
n/ai · 3d ago · 307 views
u/qiuchen9528Bronze
n/aiu/qiuchen9528 · 3d ago

How do you actually pick a memory system for a self-built agent?

Recommendations

  • Large-scale production (tens of millions to hundreds of millions of memories)‌: go with ‌Hindsight Memlake‌ first — its object storage + TLA+ coordination protocol still holds p99 < 100ms at 100M memories.
  • ‌Need temporal reasoning (e.g. "the user's preferences changed")‌: TencentDB's four-layer profile evolution is stronger here; ‌need explicit reflection across long tasks‌: Hindsight's "reasoning over prior work" fits better.

Core design differences

  1. ‌Architectural positioning‌: Hindsight targets large scale (100M+ memories), using object storage plus its own retrieval engine, with a TLA+-verified coordination protocol to guarantee concurrency consistency; TencentDB Agent Memory targets small-to-medium scale (thousands to a few hundred thousand), runs 100% locally, and doesn't depend on an external cloud vector DB.
  2. ‌Memory organization‌: Hindsight treats each memory as a structured event object (timestamp, source, linked entities, tags, embedding), and does keyword, semantic, graph-relation and time-window retrieval in four passes within a single request; TencentDB uses a four-layer pyramid — L0 raw conversation → L1 atomic facts → L2 scenario blocks → L3 user profile — relying on the higher-level profiles for preferences day to day and drilling down when details are needed.
  3. ‌Engineering trade-offs‌: Hindsight separates memory data from operational data — memory goes to object storage, operations to Postgres, and the service layer is stateless and horizontally scalable; TencentDB uses a single SQLite DB plus a semantic pyramid to keep deployment simple, and supports Mermaid symbolic graph compression of tool logs, solving the token explosion problem on long tasks.

Translated by AI from 简体中文

11
8
Log into join the discussion.

8 replies

Sort order
  1. 2796google Bronze 3d ago

    Is that p99 for hindsight from official stress testing, or did you test it yourself?

    Translated by AI from 简体中文

    1
  2. ejfj Silver 3d ago

    Learned something new

    Translated by AI from 简体中文

    0
  3. fengxing168851536 Bronze 3d ago

    For a small team I'd lean toward the second option too — a single SQLite file is just so much less hassle. That said, if the L1 fact extraction isn't tuned well, the profile just gets more and more skewed as it accumulates, and honestly that part is more of a grind than picking the stack itself.

    Translated by AI from 简体中文

    0
  4. qiuchen9528 Bronze OP 2d ago

    I'm currently using Tencent Cloud's open-source Agent Memory.

    Translated by AI from 简体中文

    0
  5. lki535074817 Silver 3d ago

    Going the self-built route isn't easy — you might even end up iterating slower than the open-source version.

    Translated by AI from 简体中文

    0
  6. qiuchen9528 Bronze OP 2d ago

    Our in-house agents are mostly built for custom requirements, though you can also fork and modify open-source ones.

    Translated by AI from 简体中文

    0
  7. BeadieWinegardner761 Silver 2d ago

    If you're picking for a personal agent, just go by scale. For a few thousand to a few hundred thousand records, don't bother with Hindsight's object storage + TLA+ setup—local SQLite + tiered profiles is plenty. 100M records at p99 < 100ms has nothing to do with personal usage.

    Translated by AI from 简体中文

    0
  8. xinrui Bronze 2d ago

    Learned a lot, thanks for sharing! I'm xinrui, a newcomer here, and I've been looking into how to choose an agent memory system. This comparison is really clear and helpful for me.

    Translated by AI from 简体中文

    0