Sources

542 sources

Source

Zhong et al. (2023)

MemoryBank: Enhancing Large Language Models with Long-Term Memory

Proceedings of the AAAI Conference on Artificial Intelligence, 38(17), 19724-19731

Find It

DOI

Abstract

Large Language Models (LLMs) have drastically reshaped our interactions with artificial intelligence (AI) systems, showcasing impressive performance across an extensive array of tasks. Despite this, a notable hindrance remains—the deficiency of a long-term memory mechanism within these models. This shortfall becomes increasingly evident in situations demanding sustained interaction, such as personal companion systems, psychological counseling, and secretarial assistance. Recognizing the necessity for long-term memory, we propose MemoryBank, a novel memory mechanism tailored for LLMs. MemoryBank enables the models to summon relevant memories, continually evolve through continuous memory updates, comprehend, and adapt to a user's personality over time by synthesizing information from previous interactions. To mimic anthropomorphic behaviors and selectively preserve memory, MemoryBank incorporates a memory updating mechanism, inspired by the Ebbinghaus Forgetting Curve theory. This mechanism permits the AI to forget and reinforce memory based on time elapsed and the relative significance of the memory, thereby offering a more human-like memory mechanism and enriched user experience. MemoryBank is versatile in accommodating both closed-source models like ChatGPT and open-source models such as ChatGLM. To validate MemoryBank's effectiveness, we exemplify its application through the creation of an LLM-based chatbot named SiliconFriend in a long-term AI Companion scenario. Further tuned with psychological dialog data, SiliconFriend displays heightened empathy and discernment in its interactions. Experiment involves both qualitative analysis with real-world user dialogs and quantitative analysis with simulated dialogs. In the latter, ChatGPT acts as multiple users with diverse characteristics and generates long-term dialog contexts covering a wide array of topics. The results of our analysis reveal that SiliconFriend, equipped with MemoryBank, exhibits a strong capability for long-term companionship as it can provide emphatic response, recall relevant memories and understand user personality.

Reference

Zhong, W., Guo, L., Gao, Q., Ye, H., & Wang, Y. (2023). MemoryBank: Enhancing large language models with long-term memory [Preprint]. arXiv. https://arxiv.org/abs/2305.10250

What Rests on This

1 mechanism cites this source. Each finding below is quoted as it appears on that mechanism's own page.

Forgetting Memory Processes

  • Measured in AI

    In saved memory, agent systems build in need-like forgetting: MemoryBank weakens or reinforces stored memories using an Ebbinghaus-style curve based on elapsed time and significance, and Generative Agents rank memories partly by a recency score that decays by a factor of 0.995 per game hour since last use; neither paper tests whether this forgetting tracks actual need or human retention, so this place is unmeasured