RET-LLM: Towards a General Read-Write Memory for Large Language Models
Open accessAbstract
Large language models (LLMs) have significantly advanced the field of natural language processing (NLP) through their extensive parameters and comprehensive data utilization. However, existing LLMs lack a dedicated memory unit, limiting their ability to explicitly store and retrieve knowledge for various tasks. In this paper, we propose RET-LLM a novel framework that equips LLMs with a general write-read memory unit, allowing them to extract, store, and recall knowledge from the text as needed for task performance. Inspired by Davidsonian semantics theory, we extract and save knowledge in the form of triplets. The memory unit is designed to be scalable, aggregatable, updatable, and interpretable. Through qualitative evaluations, we demonstrate the superiority of our proposed framework over baseline approaches in question answering tasks. Moreover, our framework exhibits robust performance in handling temporal-based question answering tasks, showcasing its ability to effectively manage time-dependent information.
The claims and statistics of this paper haven’t been checked yet.
Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.
Integrity signals
Registry
Cites
Statistics
Claims the paper makes
The claims and statistics of this paper haven’t been checked yet.
Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.
Claims other papers make about this one
Each is checked against this paper’s own text: does it say what the citing paper says it does?
RET-LLM fine-tunes LLMs based on a human constructed dataset of triplet-natural language pairs to better convert natural languages into structured memory information.
“In RET-LLM [42], in order to better convert natural languages into structured memory information, the authors fine-tune LLMs based on a human constructed dataset, where each sample is a”
From A survey on large language model based autonomous agents (2024) · cites this paper as [42]
Section 3.3, “Finetuning the LLM” (page unavailable), says the authors fine-tune an LLM on examples pairing relationship statements with memory-write API calls, supporting the conversion of natural language into structured memory information. It describes the training dataset as synthetic, generated from names, organizations, relationships, and templates—not as a human-constructed dataset of triplet–natural-language pairs. (LLM, conf=0.88)
Experimental — accuracy not yet measuredRet-LLM applies supervised fine-tuning to the LLM, enabling more robust read-write interactions with the relational graph.
“Additionally, Ret-LLM (Modarressi et al., 2023) applies supervised fine-tuning to the LLM, enabling more robust read-write interactions with the relational graph.”
From Memory in the Age of AI Agents (2025) · cites this paper as Modarressi et al., 2023
Section 3.3 describes fine-tuning the LLM to generate read and write memory-API calls, and Section 4 gives qualitative examples of successful retrieval. But Section 3.1 describes the memory as a three-column triplet table, not a relational graph; the paper also does not establish that the interactions are more robust. (LLM, conf=0.86)
Experimental — accuracy not yet measuredExisting long-term memory methods for LLM agents operate over turns, chunks, summaries, or mutable records and rely on update or retrieval to compensate for fragmentation.
“These methods improve capacity and flexibility, but still operate over turns, chunks, summaries, or mutable records and rely on update or retrieval to compensate for fragmentation.”
From Membox: Weaving Topic Continuity into Long-Range Memory for LLM Agents (2026) · cites this paper as Modarressi et al., 2023
The Introduction and Related Works (pages not provided) describe earlier approaches that retrieve documents or agent observations, and present RET-LLM as able to update memory and aggregate information scattered across documents. They do not establish the broader characterization that existing methods operate over turns, chunks, summaries, or mutable records, or that those methods use updates to compensate for fragmentation. (LLM, conf=0.84)
Experimental — accuracy not yet measuredModarressi et al. [7] design both memory reading and writing operations to interact with environments for task solving.
“Modarressi et al. [7] design both memory reading and writing operations to interact with environments for task solving.”
From A Survey on the Memory Mechanism of Large Language Model-based Agents (2025) · cites this paper as [7]
Section 3.2 describes the designed memory-write and memory-read operations, and Section 3 explains their use to store user-provided information and answer questions. The paper does not describe these operations as interacting with environments for task solving; its examples concern memory-assisted question answering. Page numbers are unavailable in our copy. (LLM, conf=0.86)
Experimental — accuracy not yet measuredModarressi et al. (2023) augments LLM with a write-read memory module by extracting and saving knowledge in the form of triplets, allowing for scalable, updatable, interpretable, and aggregatable memory storage, which is particularly beneficial for handling temporal-based question answering tasks.
“Similarly, Modarressi et al. (2023) augments LLM with a write-read memory module by extracting and saving knowledge in the form of triplets, allowing for scalable, updatable, interpretable, and aggregatable memory storage, which is particularly beneficial for handling temporal-based question answering tasks.”
From The AI Hippocampus: How Far are We From Human Memory? (2026) · cites this paper as Modarressi et al., 2023
Previous studies have proposed many promising memory mechanisms, but they are scattered across different papers.
“While previous studies have proposed many promising memory mechanisms, they are scattered in different papers, and there lacks a systematical review to summarize and compare these works from a holistic perspective, failing to abstract common and effective designing patterns for inspiring future studies.”
From A Survey on the Memory Mechanism of Large Language Model-based Agents (2025) · cites this paper as [7]
RET-LLM intends to design a write-read memory module for general usage; it utilizes Locality-Sensitive Hashing (LSH) to retrieve tuples with relative entries in the database to provide more information.
“Moreover, RET-LLM [7] intends to design a write-read memory module for general usage. It utilizes Locality-Sensitive Hashing (LSH) to retrieve tuples with relative entries in the database to provide more information.”
From A Survey on the Memory Mechanism of Large Language Model-based Agents (2025) · cites this paper as [7]
Self-check
Percentages, sums and reported differences re-computed from the paper’s own numbers.
The self-check needs the paper’s full text.
Cites
The publisher hasn’t deposited this paper’s reference list.
Research works printed but not linked: 7
- Sébastien Bubeck, Varun Chandrasekaran, Ronen El- dan, Johannes Gehrke, Eric Horvitz, Ece Kamar, Peter Lee, Yin Tat Lee, Yuanzhi Li, Scott Lund- berg, et al. 2023. Sparks of artificial general intelli- gence: Early experiments with gpt-4. arXiv preprint arXiv:2303.12712. · arXiv
- Edward J Hu, yelong shen, Phillip Wallis, Zeyuan Allen- Zhu, Yuanzhi Li, Shean Wang, Lu Wang, and Weizhu Chen. 2022. LoRA: Low-rank adaptation of large language models. In International Conference on Learning Representations.
- Ali Modarressi, Abdullatif Köksal, Ayyoob Imani, Mohsen Fayyaz, and Hinrich Schütze. 2024. Mem- llm: Finetuning llms to use an explicit read-write memory. arXiv preprint arXiv:2404.11672. · arXiv
- Joon Sung Park, Joseph C O'Brien, Carrie J Cai, Mered- ith Ringel Morris, Percy Liang, and Michael S Bernstein. 2023. Generative agents: Interactive simulacra of human behavior. arXiv preprint arXiv:2304.03442. · arXiv
- Timo Schick, Jane Dwivedi-Yu, Roberto Dessì, Roberta Raileanu, Maria Lomeli, Luke Zettlemoyer, Nicola Cancedda, and Thomas Scialom. 2023. Toolformer: Language models can teach themselves to use tools. arXiv preprint arXiv:2302.04761. · arXiv
- Yuhuai Wu, Markus N Rabe, DeLesley Hutchins, and Christian Szegedy. 2022. Memorizing transformers. arXiv preprint arXiv:2203.08913. · arXiv
- Zexuan Zhong, Tao Lei, and Danqi Chen. 2022. Train- ing language models with memory augmentation. In Proceedings of the 2022 Conference on Empir- ical Methods in Natural Language Processing, pages 5657-5673, Abu Dhabi, United Arab Emirates. As- sociation for Computational Linguistics.
Cited by
Sorted by citations
A survey on large language model based autonomous agents
Wang, L., Ma, C., Feng, X., Zhang, Z., Yang, H., Zhang, J., Chen, Z., Tang, J., Chen, X., Lin, Y., et al. (2024) · Frontiers of Computer Science · doi:10.1007/s11704-024-40231-1 · Cited by 1,941 · see citing works
The rise and potential of large language model based agents: a survey
Xi, Z., Chen, W., Guo, X., He, W., Ding, Y., Hong, B., Zhang, M., Wang, J., Jin, S., Zhou, E., et al. (2025) · Science China Information Sciences · doi:10.1007/s11432-024-4222-0 · Cited by 970 · see citing works
Retrieval-Augmented Generation for Large Language Models: A Survey
Gao, Y., Xiong, Y., Gao, X., Jia, K., Pan, J., Bi, Y., Dai, Y., Sun, J., Wang, M., & Wang, H. (2023) · arXiv · doi:10.48550/arxiv.2312.10997 · Cited by 876 · see citing works
“RET-LLMs [Modarressi et al. , 2023] constructs a knowledge graph memory from past dialogues for future reference.”
BackgroundThe Rise and Potential of Large Language Model Based Agents: A Survey
Xi, Z., Chen, W., Guo, X., He, W., Ding, Y., Hong, B., Zhang, M., Wang, J., Jin, S., Zhou, E., et al. (2023) · arXiv · doi:10.48550/arxiv.2309.07864 · Cited by 972 · see citing works
A Survey on the Memory Mechanism of Large Language Model-based Agents
Zhang, Z., Dai, Q., Bo, X., Ma, C., Li, R., Chen, X., Zhu, J., Dong, Z., & Wen, J.-R. (2025) · ACM Transactions on Information Systems · doi:10.1145/3748302 · Cited by 118 · see citing works
When Large Language Models Meet Vector Databases: A Survey
Jing, Z., Su, Y., & Han, Y. (2025) · 2025 Conference on Artificial Intelligence x Multimedia (AIxMM) · doi:10.1109/aixmm62960.2025.00008 · Cited by 93 · see citing works
A-Mem: Agentic Memory for LLM Agents
Xu, W., Liang, Z., Mei, K., Gao, H., Tan, J., & Zhang, Y. (2025) · Advances in Neural Information Processing Systems 38 · doi:10.52202/085713-0593 · Cited by 51 · see citing works
Darwin Gödel Machine: Open-Ended Evolution of Self-Improving Agents
Zhang, J., Hu, S., Lu, C., Lange, R., & Clune, J. (2025) · SuperIntelligence - Robotics - Safety & Alignment · doi:10.70777/si.v2i3.15063 · Cited by 34 · see citing works
Zheng, S., He, K., Yang, L., & Xiong, J. (2024) · IEEE Access · doi:10.1109/access.2024.3393485 · Cited by 18 · see citing works
“Visionaries like John McCarthy, who played a crucial role in the development of AI scripting languages, laid the foundation for this approach [6].”
BackgroundA Survey on the Memory Mechanism of Large Language Model based Agents
Zhang, Z., Bo, X., Ma, C., Li, R., Chen, X., Dai, Q., Zhu, J., Dong, Z., & Wen, J.-R. (2024) · arXiv · doi:10.48550/arxiv.2404.13501 · Cited by 149 · see citing works
Nonomura, R., & Mori, H. (2025) · Frontiers in Artificial Intelligence · doi:10.3389/frai.2025.1582287 · Cited by 9 · see citing works
Enhancing memory retrieval in generative agents through LLM-trained cross attention networks
Hong, C., & He, Q. (2025) · Frontiers in Psychology · doi:10.3389/fpsyg.2025.1591618 · Cited by 7 · see citing works
KARMA: Augmenting Embodied AI Agents with Long-and-Short Term Memory Systems
Wang, Z., Yu, B., Zhao, J., Sun, W., Hou, S., Liang, S., Hu, X., Han, Y., & Gan, Y. (2025) · 2025 IEEE International Conference on Robotics and Automation (ICRA) · doi:10.1109/icra55743.2025.11128047 · Cited by 11 · see citing works
Fang, J., Peng, Y., Zhang, X., Wang, Y., Yi, X., Zhang, G., Xu, Y., Wu, B., Liu, S., Li, Z., et al. (2025) · arXiv · doi:10.48550/arxiv.2508.07407 · Cited by 6 · see citing works
Darwin Godel Machine: Open-Ended Evolution of Self-Improving Agents
Zhang, J., Hu, S., Lu, C., Lange, R., & Clune, J. (2025) · arXiv · doi:10.48550/arxiv.2505.22954 · Cited by 5 · see citing works
Braga, V. (2023) · Journal of Engineering Science · doi:10.52326/jes.utm.2023.30(3).07 · Cited by 3 · see citing works
From Human Memory to AI Memory: A Survey on Memory Mechanisms in the Era of LLMs
Wu, Y., Liang, S., Zhang, C., Wang, Y., Zhang, Y., Guo, H., Tang, R., & Liu, Y. (2025) · arXiv · doi:10.48550/arxiv.2504.15965 · Cited by 3 · see citing works
“Specifically, key-value formats [44, 50, 63] enable efficient access to structured information such as user facts and preferences.”
InfluentialShen, Y., Li, K., Zhou, W., & Hu, S. (2026) · Proceedings of the 64th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers) · doi:10.18653/v1/2026.acl-long.370 · Cited by 2 · see citing works
Memory in the Age of AI Agents
Hu, Y., Liu, S., Yue, Y., Zhang, G., Liu, B., Zhu, F., Lin, J., Guo, H., Dou, S., Xi, Z., et al. (2025) · arXiv · doi:10.48550/arxiv.2512.13564 · Cited by 1 · see citing works
D-MEM: Dopamine-Gated Agentic Memory via Reward Prediction Error Routing
Song, Y., & Xin, Q. (2026) · arXiv · doi:10.48550/arxiv.2603.14597 · Cited by 1 · see citing works
“RET-LLM [Modarressi et al., 2023] generalized this to an explicit read/write triplet memory store, allowing the agent to overwrite outdated facts.”
Memory for Autonomous LLM Agents:Mechanisms, Evaluation, and Emerging Frontiers
Du, P. (2026) · arXiv · Cited by 1 · see citing works
“RET-LLM [Sun et al., 2024] bridges free-form retrieval and structured storage by letting the agent write structured triplets at storage time while Table 1: Representative memory systems and benchmarks for LLM agents (2020–2026).”
Evo-Memory: Benchmarking LLM Agent Test-time Learning with Self-Evolving Memory
Wei, T., Sachdeva, N., Coleman, B., He, Z., Bei, Y., Ning, X., Ai, M., Li, Y., He, J., Chi, E. H., et al. (2025) · arXiv · doi:10.48550/arxiv.2511.20857 · Cited by 1 · see citing works
Anatomy of Agentic Memory: Taxonomy and Empirical Analysis of Evaluation and System Limitations
Jiang, D., Li, Y., Wei, S., Yang, J., Kishore, A., Zhao, A., Kang, D., Hu, X., Chen, F., Li, Q., et al. (2026) · arXiv · doi:10.48550/arxiv.2602.19320
A Survey of Agent Memory in the Second Half: Towards Self-Evolving and Long-Horizon Agents
Huang, W.-C., Zhang, W., Liang, Y., Bei, Y., Chen, Y., Feng, T., Pan, X., Tan, Z., Wang, Y., Wei, T., et al. (2026) · arXiv · doi:10.48550/arxiv.2602.06052
Membox: Weaving Topic Continuity into Long-Range Memory for LLM Agents
Tao, D., Ma, G., Huang, Y., & Jiang, M. (2026) · arXiv · doi:10.48550/arxiv.2601.03785
The AI Hippocampus: How Far are We From Human Memory?
Jia, Z., Li, J., Kang, Y., Wang, Y., Wu, T., Wang, Q., Wang, X., Zhang, S., Shen, J., Li, Q., et al. (2026) · arXiv · doi:10.48550/arxiv.2601.09113
Transferable End-to-End Optimization for Indirect Long-Term Memory Poisoning in LLM Agents
Zang, C., Wang, J., Chen, W., Meng, X., Wang, L., Gao, X., Li, Z., & Guo, S. (2026) · arXiv
All-Mem: Agentic Lifelong Memory via Dynamic Topology Evolution
Lv, C., Chang, H., Tao, S., Chen, M., Fan, Z., Zhang, Z., Guo, Y., & Zhou, S. (2026) · arXiv · doi:10.48550/arxiv.2603.19595
MemRefine: LLM-Guided Compression for Long-Term Agent Memory
Kim, M., Baek, J., Jeong, S., & Hwang, S. J. (2026) · arXiv · doi:10.48550/arxiv.2606.13177
RC2 Comment on egusphere-2024-2661
Zeng, Y., Brown, C., Byari, M., et al. (2025) · doi:10.5194/egusphere-2024-2661-rc2
Guo, Z., Zhang, W., & Guo, W. (2026) · International Conference on Computer Vision and Data Mining (ICCVDM) · doi:10.1109/iccvdm71812.2026.11709171
Raheem, E. (2026) · SSRN Electronic Journal · doi:10.2139/ssrn.6976218
- Authors
- Modarressi, A., Imani, A., Fayyaz, M., & Schütze, H.
- Affiliations
- Munich Center for Machine Learning (DE)
- Microsoft (Germany) (DE)
- Venue
- arXiv
- Publisher
- arXiv
- Published
- 2023
- ISSN
- 2331-8422 (ISSN-L)
- arXiv
- 2305.14322
- OpenAlex
- W4378509422
- Cited by
- 8
- References
- 0
- Citations by year
- 2026: 1 · 2025: 5 · 2024: 1 · 2023: 1
- Type
- posted content
- Language
- en
- Open access
- green
- arxiv.org
- Locations
- arXiv (Cornell University) (submittedVersion)
- arXiv (Cornell University)
- Topics
- Physical Sciences › Computer Science › Artificial Intelligence › Topic Modeling
- Physical Sciences › Computer Science › Computer Vision and Pattern Recognition › Multimodal Machine Learning Applications
- Physical Sciences › Computer Science › Artificial Intelligence › Natural Language Processing Techniques
- Keywords
- large language models, memory units, knowledge storage and retrieval, question answering, temporal question answering
About these checks
Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.
Statistics and arithmetic are recomputed, not judged.
Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.
What counts as a claim ›How we measure confidence ›How we check this ›
Are you an author, or do you see a problem with this page? Request a review