Critical Phase Transition in Large Language Models

Kai Nakaishi,Yoshihiko Nishikawa,Koji Hukushima
2024-10-22
Abstract:Large Language Models (LLMs) have demonstrated impressive performance. To understand their behaviors, we need to consider the fact that LLMs sometimes show qualitative changes. The natural world also presents such changes called phase transitions, which are defined by singular, divergent statistical quantities. Therefore, an intriguing question is whether qualitative changes in LLMs are phase transitions. In this work, we have conducted extensive analysis on texts generated by LLMs and suggested that a phase transition occurs in LLMs when varying the temperature parameter. Specifically, statistical quantities have divergent properties just at the point between the low-temperature regime, where LLMs generate sentences with clear repetitive structures, and the high-temperature regime, where generated sentences are often incomprehensible. In addition, critical behaviors near the phase transition point, such as a power-law decay of correlation and slow convergence toward the stationary state, are similar to those in natural languages. Our results suggest a meaningful analogy between LLMs and natural phenomena.
Disordered Systems and Neural Networks,Machine Learning
What problem does this paper attempt to address?
This paper attempts to explore whether qualitative changes in large - language models (LLMs) can be regarded as phase - transition phenomena. Specifically, by analyzing the texts generated by LLMs, the author proposes that phase transitions may occur in LLMs when the temperature parameter is changed. This phase transition occurs at the critical point between the low - temperature region (where LLMs generate sentences with clear repetitive structures) and the high - temperature region (where the generated sentences are usually difficult to understand). Near this point, the statistics exhibit divergent properties, similar to the critical behavior in natural languages. In addition, the paper also explores the analogical relationship between LLMs and natural phenomena, as well as the possibility of understanding LLMs by studying the phase - transition theories and methods in nature. The main contributions of the paper include: 1. Proposing to formalize the qualitative changes in LLMs as phase transitions studied in statistical physics, providing the first strong evidence for the existence of phase transitions in actual LLMs. 2. Conducting a numerical analysis of the statistical characteristics of natural - language datasets and discussing their connection with the criticality of LLMs. 3. Demonstrating that the time structures of the generated texts at high and low temperatures are special from the perspective of statistical physics, which may be due to the complex architectures of LLMs and the training on large - scale corpora with a large number of parameters. These studies not only deepen the understanding of how LLMs work but also provide a theoretical basis for developing more efficient LLMs.