Elamur Research⌕
☰
home / papers / 2026 / Text2Mem: A Unified Memory Operation Language for Memory Operating System

Text2Mem: A Unified Memory Operation Language for Memory Operating System

Paper · 2026 · Leo Wang, Lihai Yang, Boyu Chen et al.

Summary

LLM agents that work across long, multi-session interactions need memory. Yet current memory frameworks mostly offer basic create/read/delete-style primitives. Higher-level controls such as merging, promoting, locking or expiring memories are absent or implemented differently from system to system. Text2Mem addresses this with a language-level specification that turns vague natural-language commands into precise, executable memory operations.

It defines twelve operations grouped into encoding, storage and retrieval stages. Each instruction becomes a JSON schema instance with required fields and invariants. A validator checks it, a parser turns it into a typed object, and an adapter executes it on a SQL-based reference backend or on existing frameworks. How each backend realizes an operation is left to that backend.

The authors also release the Text2Mem Benchmark, which scores schema generation separately from execution effects. Across five LLMs, generated schemas were usually valid and executable, but the resulting memory-state changes often missed the intended outcome. Stateful reasoning about memory therefore remains the main open problem. The work borrows its approach from text-to-SQL and supplies a shared reference point for comparing memory control in agents.

Key points

  • Operation set: twelve operations across three stages (ENC, STO, RET):
    • Encode;
    • Update, Label, Promote, Demote, Merge, Split, Delete, Lock, Expire;
    • Retrieve, Summarize.
  • Pipeline: natural language → JSON schema → validator → type parser → adapter. Adapters cover a SQL prototype backend and frameworks such as mem0, zep, langmem and MemOS. Code is at github.com/MemTensor/text2mem.
  • Metrics:
    • SMA_lev and SMA_cos measure structural similarity to reference schemas;
    • ESR measures whether a schema executes successfully;
    • EMR measures whether the intended state change occurred, checked by SQL assertions.
  • Models tested: GPT-4o, Qwen2.5-72B-Instruct, Claude-4-Sonnet, Gemini-2.5-Pro and GPT-5.
    • ESR mostly exceeded 90%, while EMR was far lower.
    • Example: GPT-4o reached about 0.18 EMR on Chinese and 0.32 on English instructions.
    • GPT-4o had the best SMA, GPT-5 the best ESR and Claude-4-Sonnet the best EMR.
  • Harder cases: English beat Chinese, and single operations beat multi-step workflows (GPT-4o EMR 0.218 vs 0.088). Merge and Split were the hardest operations.

Our summary of the paper, in our own words — not its text. The work belongs to its authors; read it at the links above.

 Institutions

 Fields, topics and concepts

Cite

Cite as Leo Wang, Lihai Yang, Boyu Chen, Kerun Xu, Gongyi Zou, Bo Tang, Feiyu Xiong, Siheng Chen and Zhiyu li. 2026. Text2Mem: A Unified Memory Operation Language for Memory Operating System. Findings of the Association for Computational Linguistics: ACL 2026.

The paper itself, not this page. BibTeX from the library's record of the work. DOI 10.18653/v1/2026.findings-acl.100

@inproceedings{wang2026text2mem,
  title = {{Text2Mem: A Unified Memory Operation Language for Memory Operating System}},
  author = {Leo Wang, Lihai Yang, Boyu Chen, Kerun Xu, Gongyi Zou, Bo Tang, Feiyu Xiong, Siheng Chen and Zhiyu li},
  booktitle = {Findings of the Association for Computational Linguistics: ACL 2026},
  year = {2026},
  doi = {10.18653/v1/2026.findings-acl.100},
  url = {https://doi.org/10.18653/v1/2026.findings-acl.100}
}

References

31 references, 12 of them with a card of ours. ↗ leads to the work, «find» searches for one we have no id for yet.

  1. Prateek Chhikara, Dev Khant, Saket Aryan, Taranjeet Singh, and Deshraj Yadav. 2025. Mem0: Building production-ready ai agents with scalable long-term memory. Preprint, arXiv:2504.19413.
  2. Longxu Dou, Yan Gao, Mingyang Pan, Dingzirui Wang, Wanxiang Che, Dechen Zhan, and Jian-Guang Lou. 2022. Unisar: A unified structure-aware autoregressive language model for text-to-sql. Preprint, arXiv:2203.07781. — [arXiv:2203.07781](https://arxiv.org/abs/2203.07781) find
  3. Bernal Jimenez Gutierrez, Yiheng Shu, Yu Gu, Michihiro Yasunaga, and Yu Su. 2024. HippoRAG: Neurobiologically inspired long-term memory for large language models. In The Thirty-eighth Annual Conference on Neural Information Processing Systems.
  4. Bernal Jiménez Gutiérrez, Yiheng Shu, Weijian Qi, Sizhe Zhou, and Yu Su. 2025. From rag to memory: Non-parametric continual learning for large language models. CoRR, abs/2502.14802. find
  5. Zijin Hong, Zheng Yuan, Qinggang Zhang, Hao Chen, Junnan Dong, Feiran Huang, and Xiao Huang. 2025. Next-generation database interfaces: A survey of llm-based text-to-sql. Preprint, arXiv:2406.08426. — [arXiv:2406.08426](https://arxiv.org/abs/2406.08426) find
  6. Jimin Lee, Ingeol Baek, Byeongjeong Kim, Hyunkyung Bae, and Hwanhee Lee. 2025. Safe-sql: Self-augmented in-context learning with fine-grained example selection for text-to-sql. Preprint, arXiv:2502.11438. find
  7. Jinyang Li, Binyuan Hui, Ge Qu, Jiaxi Yang, Binhua Li, Bowen Li, Bailin Wang, Bowen Qin, Ruiying Geng, Nan Huo, Xuanhe Zhou, Chenhao Ma, Guoliang Li, Kevin C.C. Chang, Fei Huang, Reynold Cheng, and Yongbin Li. 2023. Can llm already serve as a database interface? a big bench for large-scale database…
  8. Zhiyu Li, Shichao Song, Chenyang Xi, Hanyu Wang, Chen Tang, Simin Niu, Ding Chen, Jiawei Yang, Chunyu Li, Qingchen Yu, Jihao Zhao, Yezhaohui Wang, Peng Liu, Zehao Lin, Pengyuan Wang, Jiahao Huo, Tianyi Chen, Kai Chen, Kehang Li, and 20 others. 2025. Memos: A memory os for ai system. arXiv preprint a… — [arXiv:2507.03724](https://arxiv.org/abs/2507.03724) find
  9. Xun Liang, Simin Niu, Zhiyu Li, Sensen Zhang, Shichao Song, Hanyu Wang, Jiawei Yang, Feiyu Xiong, Bo Tang, and Chenyang Xi. 2024. Empowering large language models to set up a knowledge retrieval indexer via self-learning. CoRR, abs/2405.16933. — [arXiv:2405.16933](https://arxiv.org/abs/2405.16933) find
  10. Dominik Lindorfer. 2023. Sql-llama: Text-2-sql using an instruction-following llama-2 model. https://github.com/dominiklindorfer/SQL-LLaMA. ↗
  11. Tao Liu, Xutao Mao, Hongying Zan, Dixuan Zhang, Yifan Li, Haixin Liu, Lulu Kong, Jiaming Hou, Rui Li, YunLong Li, aoze zheng, Zhiqiang Zhang, Luo Zhewei, Kunli Zhang, and Min Peng. 2025a. Logiccat: A chain-of-thought text-to-sql benchmark for complex reasoning. Preprint, arXiv:2505.18744. — [arXiv:2505.18744](https://arxiv.org/abs/2505.18744) find
  12. Yifu Liu, Yin Zhu, Yingqi Gao, Zhiling Luo, Xiaoxia Li, Xiaorong Shi, Yuntao Hong, Jinyang Gao, Yu Li, Bolin Ding, and Jingren Zhou. 2025b. Xiyan-sql: A novel multi-generator framework for text-to-sql. Preprint, arXiv:2507.04701. — [arXiv:2507.04701](https://arxiv.org/abs/2507.04701) find
  13. Junyu Luo, Weizhi Zhang, Ye Yuan, Yusheng Zhao, Junwei Yang, Yiyang Gu, Bohan Wu, Binqi Chen, Ziyue Qiao, Qingqing Long, Rongcheng Tu, Xiao Luo, Wei Ju, Zhiping Xiao, Yifan Wang, Meng Xiao, Chenwu Liu, Jingyang Yuan, Shichang Zhang, and 7 others. 2025. Large language model agent: A survey on methodo…
  14. Charles Packer, Sarah Wooders, Kevin Lin, Vivian Fang, Shishir G. Patil, Ion Stoica, and Joseph E. Gonzalez. 2024. Memgpt: Towards llms as operating systems. Preprint, arXiv:2310.08560. find
  15. Ge Qu, Jinyang Li, Bowen Li, Bowen Qin, Nan Huo, Chenhao Ma, and Reynold Cheng. 2024. Before generation, align it! a novel and effective strategy for mitigating hallucinations in text-to-SQL generation. In Findings of the Association for Computational Linguistics: ACL 2024, pages 5456–5471, Bangkok,… find
  16. Preston Rasmussen, Pavlo Paliychuk, Travis Beauvais, Jack Ryan, and Daniel Chalef. 2025. Zep: A temporal knowledge graph architecture for agent memory. CoRR, abs/2501.13956. find
  17. Bailin Wang, Richard Shin, Xiaodong Liu, Oleksandr Polozov, and Matthew Richardson. 2020. RAT-SQL: Relation-aware schema encoding and linking for text-to-SQL parsers. In Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, pages 7567–7578, Online. Association for…
  18. Lei Wang, Chen Ma, Xueyang Feng, Zeyu Zhang, Hao Yang, Jingsen Zhang, Zhiyuan Chen, Jiakai Tang, Xu Chen, Yankai Lin, Wayne Xin Zhao, Zhewei Wei, and Jirong Wen. 2024. A survey on large language model based autonomous agents. Frontiers of Computer Science, 18(6).
  19. Jiale Wei, Xiang Ying, Tao Gao, Fangyi Bao, Felix Tao, and Jingbo Shang. 2025a. Ai-native memory 2.0: Second me. Preprint, arXiv:2503.08102. — [arXiv:2503.08102](https://arxiv.org/abs/2503.08102) find
  20. Xiaolong Wei, Yuehu Dong, Xingliang Wang, Xingyu Zhang, Zhejun Zhao, Dongdong Shen, Long Xia, and Dawei Yin. 2025b. Beyond react: A planner-centric framework for complex tool-augmented llm reasoning. arXiv preprint arXiv:2511.10037. — [arXiv:2511.10037](https://arxiv.org/abs/2511.10037) find
  21. Xiaolong Wei, Zerun Zhu, Simin Niu, Xingyu Zhang, Peiying Yu, Changxuan Xiao, Yuchen Li, Jicheng Yang, Zhejun Zhao, Chong Meng, Long Xia, and Daiting Shi. 2026. Unicreative: Unifying long-form logic and short-form sparkle via reference-free reinforcement learning. Preprint, arXiv:2604.05517.
  22. Qingyun Wu, Gagan Bansal, Jieyu Zhang, Yiran Wu, Shaokun Zhang, Erkang Zhu, Beibin Li, Li Jiang, Xiaoyun Zhang, and Chi Wang. 2023. Autogen: Enabling next-gen LLM applications via multi-agent conversation framework. CoRR, abs/2308.08155.
  23. Wujiang Xu, Zujie Liang, Kai Mei, Hang Gao, Juntao Tan, and Yongfeng Zhang. 2025a. A-mem: Agentic memory for llm agents. Preprint, arXiv:2502.12110.
  24. Ziwen Xu, Shuxun Wang, Kewei Xu, and 1 others. 2025b. Easyedit2: An easy-to-use steering framework for editing large language models. Preprint, arXiv:2504.15133. find
  25. Hongkang Yang, Zehao Lin, Wenjin Wang, Hao Wu, Zhiyu Li, Bo Tang, Wenqiang Wei, Jinbo Wang, Zeyun Tang, Shichao Song, Chenyang Xi, Yu Yu, Kai Chen, Feiyu Xiong, Linpeng Tang, and Weinan E. 2024. Memory 3 : Language modeling with explicit memory. Journal of Machine Learning, 3(3):300– 346. find
  26. Tao Yu, Rui Zhang, Heyang Er, Suyi Li, Eric Xue, Bo Pang, Xi Victoria Lin, Yi Chern Tan, Tianze Shi, Zihan Li, Youxuan Jiang, Michihiro Yasunaga, Sungrok Shim, Tao Chen, Alexander Fabbri, Zifan Li, Luyao Chen, Yuwen Zhang, Shreya Dixit, and 5 others. 2019. Cosql: A conversational text-to-sql challen… find
  27. Tao Yu, Rui Zhang, Kai Yang, Michihiro Yasunaga, Dongxu Wang, Zifan Li, James Ma, Irene Li, Qingning Yao, Shanelle Roman, Zilin Zhang, and Dragomir Radev. 2018. Spider: A large-scale human-labeled dataset for complex and cross-domain semantic parsing and text-to-SQL task. In Proceedings of the 2018…
  28. Ningyu Zhang, Yunzhi Yao, Bozhong Tian, and 1 others. 2024. A comprehensive study of knowledge editing for large language models. Preprint, arXiv:2401.01286. find
  29. Wayne Xin Zhao, Kun Zhou, Junyi Li, Tianyi Tang, Xiaolei Wang, Yupeng Hou, Yingqian Min, Beichen Zhang, Junjie Zhang, Zican Dong, Yifan Du, Chen Yang, Yushuo Chen, Zhipeng Chen, Jinhao Jiang, Ruiyang Ren, Yifan Li, Xinyu Tang, Zikang Liu, and 3 others. 2025. A survey of large language models. Prepri…
  30. Victor Zhong, Caiming Xiong, and Richard Socher. 2017. Seq2sql: Generating structured queries from natural language using reinforcement learning. Preprint, arXiv:1709.00103.
  31. Wanjun Zhong, Lianghong Guo, Qiqi Gao, He Ye, and Yanlin Wang. 2024. Memorybank: enhancing large language models with long-term memory. In Proceedings of the Thirty-Eighth AAAI Conference on Artificial Intelligence and Thirty-Sixth Conference on Innovative Applications of Artificial Intelligence and… find

Updated

↑ back to top

This page in Markdown → https://md.research.elamur.ai/free/en/papers/wang-2026-text2mem-unified-memory-operation-language/