MemoryRepository for AI NPC
Open accessThe DOI matches its Crossref record; 33 of the 36 references it cites were found in a registry or an index; 6 of the 11 sources its claims cite were checked for support.
Abstract
Since the release of ChatGPT, large language models (LLMs) have played a huge role in various industries. In the field of games, we have used LLMs to act as intelligent AI NPC, which makes NPCs more intelligent. However, there is still an obvious obstacle -the LLMs lacks long-term memory and human-like memory mechanism.This flawed memory mechanism prevents NPCs from Long-term interaction and humanized memory based on conversation records.Recognizing the necessity of long-term memory and humanized memory, we proposed MemoryRepository, a memory mechanism for LLMs specifically used in the AI NPC field.MemoryRepository enables the model to have short-term memory and long-term memory. Short-term memory is more detailed and full, while long-term memory are more concise and partial. MemoryRepository is inspired by human memory and forgetting mechanisms. This mechanism allows AI NPCs to forget and summarize past conversation records, thereby providing long-term interaction capabilities. More importantly, this process of forgetting and summarizing the details of short-term memory into general long-term memories makes NPCs more human-like. MemoryRepository is versatile and can adapt to closed source models such as ChatGPT and open source models such as ChatGLM. To Intuitively verify the effectiveness of MemoryRepository in the field of AI NPC, we created an example in which all NPCs are represented by LLMs adapted to MemoryRepository. The example shows that by embedding LLM in MemoryRepository and fine-tuning NPCs character dialogue data, AI NPC can conduct better long-term conversations and appear more human-like during the interaction process. To validate the effectiveness of MemoryRepository, one hundred pieces of NPCs dialogue data were created and then quantitatively analyzed through evaluation indicators. The analysis results show that NPCs equipped with MemoryRepository can summarize and forget past memories, which enables it to have the ability to hold long-term conversations and conduct more human-like conversations.
Overview
CoChat Summary
TL;DR
MemoryRepository is a human-inspired memory mechanism for LLM-driven AI NPCs that adds short-term and long-term memory with periodic summarization and forgetting. In a StarUniverse case study and 400-question evaluation, it improved human-like interaction and contextual coherence over base LLMs, while retrieval and correctness did not consistently improve.
Key findings
- In the 100th dialogue round, MemoryRepository-embedded GPT-3.5 scored Human Like 0.861 vs MemGPT 0.718, Coherence 0.886 vs 0.874, Retrieval 0.806 vs 0.831, and Correctness 0.705 vs 0.713.
- Against baseline LLMs, integration did not significantly improve correctness and retrieval declined; the authors attribute this to selective forgetting/summarization retaining correct but less detailed memory. It improved contextual coherence and human-like scores over time, with GPT-4 outperforming GPT-3.5, which outperformed ChatGPT-3.
- Long-term interaction demo: after hundreds of unrelated records over several days, a MemoryRepository NPC recalled a prior “How to become a Jedi Master?” question while the base LLM did not. Human-like demo: an Anakin NPC with MemoryRepository recognized Luke as a Jedi and his son, saying “I am proud of you” and “May the Force be with you,” while the base model responded mechanically.
- Robustness tests found MemoryRepository performance almost unaffected by temperature and top-p; retrieval declined with higher temperature, correctness decreased with higher temperature but increased with dialogue turns, and top-p had negligible effect on retrieval with a slight correctness decrement.
Methods
- Architecture: each NPC has a MemoryRoom with Short-Term and Long-Term Memory Rooms; Memory Interaction uses an Interactive Dual-Tower DSSM and Approximate Nearest Neighbor Indexing akin to FAISS; Memory Renewal combines forgetting and enhancement. Short-term memory stores up to ten dialogue rounds; every m turns, the last m talks are summarized into one Summary, added to long-term memory, and removed from short-term memory.
- Case study: StarUniverse, where all NPCs are LLM-based; the LLM was fine-tuned on open-source NPC dialogue data (the introduction reports 50k dialogues from game characters) and integrated via LangChain prompt engineering, with prompt structure P = Pm + Ps + Pl + Pt.
- Evaluation: local multi-GPU server with 20 CPU cores and 4 NVIDIA RTX 3090 GPUs; 400 exploratory questions (200 ChatGPT-generated, 200 manually developed) from the dataset; human annotators scored memory retrieval accuracy, response correctness, contextual coherence, and human-like interaction on 0/0.5/1 scales; compared GPT-4, GPT-3.5, ChatGLM, and MemGPT; varied temperature (0.2, 0.7, 1, 2) and top-p (0.1, 0.4, 0.7, 1).
Limitations
- The paper does not include a dedicated limitations section. It acknowledges that retrieval declined and that forgetting sacrifices short-term detail, though it argues this is acceptable for NPC human-likeness.
- Evident from the text: evaluation relies on human annotators without reported inter-annotator agreement or statistical significance tests, and many results are described through figures rather than numeric tables, limiting reproducibility from the text alone.
- Evident from the text: baseline and MemGPT comparisons are limited—Table 3 reports only the 100th round for GPT-3.5—and model naming is inconsistent (“ChatGPT-3” vs GPT-3.5), so generalizability across models and dialogue rounds is not fully established.
Model-written summary. Check it against the paper before relying on it.
Integrity signals
Registry
Cites
Statistics
Verification
Claims the paper makes
2 Valid · 6 Not valid · 5 Not checked · 78 Own results and interpretations
The cited sources that could be checked couldn’t confirm or dispute this claim.
In the paper
“Despite these developments, both scripting and behavior trees require substantial designer intervention to attain realism, a constant since their introduction.”
- Also stated in: § I. INTRODUCTION · plain
“This reliance on intensive designer input underscores the limitations of these methods in achieving truly lifelike, adaptive NPCs behavior, thus underscoring the ongoing quest for more advanced solutions in modern game design [8].”
§ MemoryRepository for AI NPC > I. INTRODUCTION
What the sources say
- Could not verifycites [8] Zhao, 2023, A survey of large language models, arXiv:2303.18223 sourceExperimental — accuracy not yet measured
The Basic agent workflow section (p. 20) discusses LLM-agent planning and execution, not scripting or behavior trees. Searches for “behavior trees” and for scripting, realism, and designer intervention found no passage in our copy addressing whether those methods require substantial designer intervention. (LLM, conf=0.75)
plainstates a cause- Asserted: passes — The authors put it forward as true.
- Checkable: passes — It can be checked against evidence.
- Load-bearing: passes — The paper’s conclusions depend on it.
- Based: passes — The paper gives a reason why it holds.
- Also stated in: § I. INTRODUCTION · plain
The cited sources support only part of this claim — read each source’s verdict below.
In the paper
“The superior language processing prowess of LLMs empowers NPCs to produce unique, context-sensitive responses.”
§ MemoryRepository for AI NPC > I. INTRODUCTION
What the sources say
- Partly supportedcites [13] Wang, 2023, Augmenting language models with long-term memory, arXiv:2306.07174 sourceExperimental — accuracy not yet measured
The Introduction (p. 1) says LLMs have advanced language understanding and generation, and the Results (p. 8) report improvements on an open-ended generation task. But the paper does not discuss NPCs or show that LLMs enable them to produce unique, context-sensitive responses; its experiments concern long-context modeling and in-context learning. (LLM, conf=0.86)
plainstates a cause- Asserted: passes — The authors put it forward as true.
- Checkable: passes — It can be checked against evidence.
- Load-bearing: passes — The paper’s conclusions depend on it.
- Based: passes — The paper gives a reason why it holds.
- Partly supported
Every source the paper cites for this claim was checked and supports it.
In the paper
“Roberto Gallotta et al., in “Large Language Models and Games: A Survey and Roadmap” demonstrated how LLMs can generate dynamic and contextually rich dialogues for NPCs [10].”
§ MemoryRepository for AI NPC > I. INTRODUCTION
What the sources say
- Supportedcites [10] Gallotta, 2024, Large language models and games: A survey and roadmap, arXiv:2402.18659 source
Section 3.2 (p. 4) states that LLMs used as NPC dialogue systems can generate dynamic, contextually appropriate responses to player input. It also explains that NPC dialogue can account for the game’s narrative, the character’s role, and player actions, supporting the paraphrase. (LLM, conf=0.93)
boostedstates a cause- Asserted: passes — The authors put it forward as true.
- Checkable: passes — It can be checked against evidence.
- Load-bearing: passes — The paper’s conclusions depend on it.
- Based: passes — The paper gives a reason why it holds.
- Supported
The cited sources that could be checked couldn’t confirm or dispute this claim.
In the paper
“Firstly, its adaptability to various situations is evidenced by the fine-tuning of 50k dialogues from game characters, enhancing its effectiveness as an NPCs [17].”
§ MemoryRepository for AI NPC > I. INTRODUCTION
What the sources say
- Could not verifycites [17] sourceExperimental — accuracy not yet measured
The Experiments section (p. 2) describes approximately 11,000 dialogues between crowdworkers using assigned personas, not 50,000 dialogues from game characters. The passages found for “50k dialogues,” “MemoryRepository,” and “NPC” do not address the claimed fine-tuning or its effect on NPC performance. (LLM, conf=0.75)
boostedstates a cause- Asserted: passes — The authors put it forward as true.
- Checkable: passes — It can be checked against evidence.
- Load-bearing: passes — The paper’s conclusions depend on it.
- Based: passes — The paper gives a reason why it holds.
- Could not verify
A result the paper reports from its own data — it cites no other source for it, so there is none to check. The quote shows it is in the paper.
In the paper
“The NPC without a MemoryRepository responded mechanically, just like a standard LLM.”
§ MemoryRepository for AI NPC > 2) Human-Like
plain- Asserted: passes — The authors put it forward as true.
- Checkable: passes — It can be checked against evidence.
- Load-bearing: passes — The paper’s conclusions depend on it.
- Based: passes — The paper gives a reason why it holds.
29 more claims
Create a free account to see all 91 claims and every source verdict.
- Probably not a substantial claim. 38
- It may state two separate claims as one. 37
- The quote only partly states this claim. 2
Self-check
Percentages, sums and reported differences re-computed from the paper’s own numbers.
Each contradiction between two passages listed here was confirmed by an independent check.
Rated major: it would touch a result — a value a result rests on, reported and recomputed p-values on opposite sides of the significance level, two passages that conflict with no sign which is right, or a cited work retracted before this paper was published.
In the paper
§ MemoryRepository for AI NPC > 2) Memory enhancement mechanism
“Then clear the contents of short-term memory to zero.”
§ MemoryRepository for AI NPC > 2) Memory enhancement mechanism
“while the short-term memory that remains after forgetting remains in the short-term memory chamber.”
Rated minor: it would not touch a result — a value no result rests on, a p-value that stays on the same side of the significance level, or a conflict that is clerical, resolved elsewhere in the paper, or outside its own findings.
In the paper
§ MemoryRepository for AI NPC > A. EXPERIMENTAL SETUP
“In addition, the server runs Ubuntu 20.04 LTS operating system and PyTorch 1.7.0 software environment.”
§ MemoryRepository for AI NPC > VII. CONCLUSION
“| System | Ubuntu 22.04, Pytorch 2.1.0 | |”
Citations
Cites
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
Devlin, J., Chang, M.-W., Lee, K., & Toutanova, K. (2019) · Proceedings of the 2019 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies, Volume 1 (Long and Short Papers) · doi:10.18653/v1/n19-1423 · Cited by 54,325
Language Models are Few-Shot Learners
Brown, T. B., Mann, B., Ryder, N., Subbiah, M., Kaplan, J., Dhariwal, P., Neelakantan, A., Shyam, P., Sastry, G., Askell, A., et al. (2020) · arXiv · doi:10.48550/arxiv.2005.14165 · Cited by 23,372
Grandmaster level in StarCraft II using multi-agent reinforcement learning
Vinyals, O., Babuschkin, I., Czarnecki, W. M., Mathieu, M., Dudzik, A., Chung, J., Choi, D. H., Powell, R., Ewalds, T., Georgiev, P., et al. (2019) · Nature · doi:10.1038/s41586-019-1724-z · Cited by 3,455 · cited 1×
“An in-memory store of conversations was created, spanning ten days and involving diverse virtual user personas, each characterized with unique personalities as portrayed by ChatGPT [18].”
BackgroundTransformer-XL: Attentive language models beyond a fixed-length context
Dai, Z., Yang, Z., Yang, Y., Carbonell, J., Le, Q., & Salakhutdinov, R. (2019) · Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics · doi:10.18653/v1/p19-1285 · Cited by 3,169 · cited 1×
“For MANNs, despite the progress in the field of LLMs, their long-term interaction capacity is constrained by memory limitations, which hinder sustained interactions and the input of sufficient preset information to achieve interactions more akin to human-like ones [26], [27].”
BackgroundGenerative Agents: Interactive Simulacra of Human Behavior
Park, J. S., O'Brien, J., Cai, C. J., Morris, M. R., Liang, P., & Bernstein, M. S. (2023) · Proceedings of the 36th Annual ACM Symposium on User Interface Software and Technology · doi:10.1145/3586183.3606763 · Cited by 2,187 · cited 2×
“The practical application of LLMs in NPCs development has been validated by works such as ‘Genera-tive Agents: Interactive Simulacra of Human Behavior’ Park et al. [7], showcasing the feasibility of LLMs in this domain.”
BackgroundMethodGenerative Agents: Interactive Simulacra of Human Behavior
Park, J. S., O'Brien, J. C., Cai, C. J., Morris, M. R., Liang, P., & Bernstein, M. S. (2023) · arXiv · doi:10.48550/arxiv.2304.03442 · Cited by 2,173
A Survey of Large Language Models
Zhao, W. X., Zhou, K., Li, J., Tang, T., Dong, Z., Hou, Y., Zhang, B., Min, Y., Zhang, J., Liu, P., et al. (2026) · Frontiers of Computer Science · doi:10.1007/s11704-026-60308-3 · Cited by 2,093 · cited 1×
“This reliance on intensive designer input underscores the limitations of these methods in achieving truly lifelike, adaptive NPCs behavior, thus underscoring the ongoing quest for more advanced solutions in modern game design [8].”
BackgroundA Survey of Large Language Models
Zhao, W. X., Zhou, K., Li, J., Tang, T., Wang, X., Hou, Y., Min, Y., Zhang, B., Zhang, J., Dong, Z., et al. (2023) · arXiv · doi:10.48550/arxiv.2303.18223 · Cited by 2,090
Meta-learning with memory-augmented neural networks
Santoro, A., Bartunov, S., Botvinick, M., Wierstra, D., & Lillicrap, T. (2016) · International Conference on Machine Learning · Cited by 1,504
GQA: A New Dataset for Real-World Visual Reasoning and Compositional Question Answering
Hudson, D. A., & Manning, C. D. (2019) · 2019 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR) · doi:10.1109/cvpr.2019.00686 · Cited by 1,451 · cited 1×
“Integrating long-term and human-like interaction capabilities into LLMs for AI NPC applications remains an unmet but critically essential need [28], [29].”
Background
Research works printed but not linked: 4
- Koster, 2019, Postmortems From Game Developer: Insights From the Developers of Unreal Tournament, Black and White, Age of Empire, and Other Top-Selling Games
- Pérez, Creativity in intelligent technologies and the non-player characters dilemma, 3
- Radford, 2019, Language models are unsupervised multitask learners, OpenAI Blog, 1, 9
- Achiam, 2024, GPT-4 Technical Report
Cited by
Christiansen, F. R., Hollensberg, L. N., Jensen, N. B., Julsgaard, K., Jespersen, K. N., & Nikolov, I. A. (2024) · ACM Symposium on Virtual Reality Software and Technology (VRST) · doi:10.1145/3641825.3687716 · Cited by 42
GPT for Games: An Updated Scoping Review (2020–2024)
Yang, D., Kleinman, E., & Harteveld, C. (2025) · IEEE Transactions on Games · doi:10.1109/tg.2025.3563780 · Cited by 50
“GPT for character generation (n = 18, [43], [72], [73], [74], [75], [76], [77], [78], [79], [80], [81], [82], [83], [84], [85], [86], [87], [88]): In 2024, the use of GPT to generate in-game characters has attracted significant research attention ( n = 15 ).”
How LLMs Are Shaping the Future of Virtual Reality
Özkaya, S., Berrezueta-Guzmán, J., & Wagner, S. (2025) · IEEE Access · doi:10.1109/access.2025.3631594 · Cited by 29
“Together, these studies show how LLMs can support adaptive, responsive, and intelligent control of VR game environments.”
Troussas, C., Krouska, A., Phivos Mylonas, B., Sgouropoulou, C., & Voyiatzis, I. (2025) · Computers · doi:10.3390/computers14030089 · Cited by 16
Jemetz, M., & Motschnig, R. (2024) · IEEE Frontiers in Education Conference (FIE) · doi:10.1109/fie61694.2024.10893585 · Cited by 6
Metadata
- Authors
- Zheng, S., He, K., Yang, L., & Xiong, J.
- Affiliations
- Yangtze University (CN)
- OgCloud Ltd, Guangzhou, China
- Guangdong University of Technology (CN)
- Venue
- IEEE Access
- Published
- 2024
- Volume
- 12
- Pages
- 62581-62596
- ISSN
- 2169-3536 (ISSN-L)
- OpenAlex
- W4395447431
- Cited by
- 18
- References
- 36
- Citations by year
- 2026: 7 · 2025: 8 · 2024: 3
- FWCI
- 2.66
- Type
- journal article
- Language
- it
- Open access
- gold
- doi.org
- Licence
- Locations
- IEEE Access (publishedVersion, cc-by-nc-nd)
- DOAJ (DOAJ: Directory of Open Access Journals) (submittedVersion, cc-by-sa)
- Topics
- Physical Sciences › Computer Science › Artificial Intelligence › Artificial Intelligence in Games
- Physical Sciences › Computer Science › Artificial Intelligence › Speech and dialogue systems
- Physical Sciences › Computer Science › Artificial Intelligence › Topic Modeling
- Keywords
- long-term memory, short-term memory, forgetting mechanism, large language models, game AI, ChatGLM, ChatGPT
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.
The claim verdicts this report counts are experimental: their accuracy is not yet measured.
A language model drew the claims from the paper on 2026-10-01, under version 3 of the claim definition (model deepseek-v4.1-flash, prompt extract-v3).
A second model labelled each claim on 2026-10-01 (model jev-1.13-20260917, definition revision gold-guideline-v0.2).
Cited sources are checked with a language model’s help (gpt-6-sol).
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
How to cite
Cite CoChat for the checks on this page, and the paper for its own findings.
- This page
- CoChat. (2026). Citation check: MemoryRepository for AI NPC. https://app.cochat.ai/papers/10.1109/access.2024.3393485
- The paper
- Zheng, S., He, K., Yang, L., & Xiong, J. (2024). MemoryRepository for AI NPC. IEEE Access. https://doi.org/10.1109/access.2024.3393485
Data sources
Bibliographic data: Semantic Scholar, OpenAlex, Crossref.
Contains information from the Semantic Scholar Academic Graph Datasets, made available under the ODC Attribution License (ODC-BY 1.0).
Semantic Scholar’s data is described in: Kinney, R., et al. (2023). The Semantic Scholar Open Data Platform. arXiv:2301.10140.