Research note: Model specifications and benchmark results are time-bound. Check the dated primary sources below before using them for a technical or purchasing decision.
Traditional Retrieval-Augmented Generation (RAG) fails for autonomous agents because flat vector similarity has no concept of time, authority, or invalidation. If a user states "I switched our database from MySQL to PostgreSQL last Tuesday," a standard vector search often retrieves old MySQL snippets because the keyword overlap is higher.
To fix this, modern agent systems implement a 4-Scope Hierarchical Memory Model:
| Memory Scope | Lifecycle | Storage Target | Invalidation Trigger |
|---|---|---|---|
| 1. User Scope | Persistent cross-session | Entity Knowledge Graph | Explicit user correction / preference edit |
| 2. Agent Scope | Model lifetime | Learned Heuristic Registry | Post-mortem failure analysis |
| 3. Session Scope | Single task trajectory | Working Memory Buffer | Task completion / PR merged |
| 4. Org Scope | Enterprise repository | AST & Rule Base | Repository commit / schema migration |
Sources & Research Papers
- • Generative Agents Memory Architecture: Park, J. S., et al. (2023). Generative Agents: Interactive Simulacra of Human Behavior. UIST 2023. arXiv:2304.03442.
- • MemGPT Architecture: Packer, C., et al. (2023). MemGPT: Towards LLMs as Operating Systems. arXiv:2310.08560.