How Do Large Language Models Acquire Factual Knowledge During Pretraining?

Hoyeon Chang, Jinho Park, Seonghyeon Ye, Sohee Yang, Youngkyung Seo +2 more
2/3/2026

No official code found. Best implementation: kaistAI/factual-knowledge-acquisition (25 stars, Apache-2.0, last commit 2025-12-12).

Abstract

Despite the recent observation that large language models (LLMs) can store substantial factual knowledge, there is a limited understanding of the mechanisms of how they acquire factual knowledge through pretraining. This work addresses this gap by studying how LLMs acquire factual knowledge during pretraining. The findings reveal several important insights into the dynamics of factual knowledge acquisition during pretraining. First, counterintuitively, we observe that pretraining on more data shows no significant improvement in the model's capability to acquire and maintain factual knowledge. Next, there is a power-law relationship between training steps and forgetting of memorization and generalization of factual knowledge, and LLMs trained with duplicated training data exhibit faster forgetting. Third, training LLMs with larger batch sizes can enhance the models' robustness to forgetting. Overall, our observations suggest that factual knowledge acquisition in LLM pretraining occurs by progressively increasing the probability of factual knowledge presented in the pretraining data at each step. However, this increase is diluted by subsequent forgetting. Based on this interpretation, we demonstrate that we can provide plausible explanations for recently observed behaviors of LLMs, such as the poor performance of LLMs on long-tail knowledge and the benefits of deduplicating the pretraining corpus.

View on arXivView PDF

Code Implementations(1)

Apache-2.0
250C, C++Oct 4, 202410 months agoApache-2.0

Similar Papers

Cite this paper

@article{chang2026large,
  title  = {How Do Large Language Models Acquire Factual Knowledge During Pretraining?},
  author = {Hoyeon Chang and Jinho Park and Seonghyeon Ye and Sohee Yang and Youngkyung Seo and Du-Seong Chang and Minjoon Seo},
  year   = {2026},
  eprint = {2406.11813},
  archivePrefix = {arXiv},
  doi    = {10.48550/arXiv.2406.11813},
  url    = {https://arxiv.org/abs/2406.11813},
  journal = {NEURIPS 2024 2024}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2406.11813.svg)](https://codeofpaper.com/paper/2406.11813)

Discussion