Table of Contents
Fetching ...

Artificial Entanglement in the Fine-Tuning of Large Language Models

Min Chen, Zihan Wang, Canyu Chen, Zeguan Wu, Manling Li, Junyu Liu

Abstract

Large language models (LLMs) can be adapted to new tasks using parameter-efficient fine-tuning (PEFT) methods that modify only a small number of trainable parameters, often through low-rank updates. In this work, we adopt a quantum-information-inspired perspective to understand their effectiveness. From this perspective, low-rank parameterizations naturally correspond to low-dimensional Matrix Product States (MPS) representations, which enable entanglement-based characterizations of parameter structure. Thereby, we term and measure "Artificial Entanglement", defined as the entanglement entropy of the parameters in artificial neural networks (in particular the LLMs). We first study the representative low-rank adaptation (LoRA) PEFT method, alongside full fine-tuning (FFT), using LLaMA models at the 1B and 8B scales trained on the Tulu3 and OpenThoughts3 datasets, and uncover: (i) Internal artificial entanglement in the updates of query and value projection matrices in LoRA follows a volume law with a central suppression (termed as the "Entanglement Valley"), which is sensitive to hyper-parameters and is distinct from that in FFT; (ii) External artificial entanglement in attention matrices, corresponding to token-token correlations in representation space, follows an area law with logarithmic corrections and remains robust to LoRA hyper-parameters and training steps. Drawing a parallel to the No-Hair Theorem in black hole physics, we propose that although LoRA and FFT induce distinct internal entanglement signatures, such differences do not manifest in the attention outputs, suggesting a "no-hair" property that results in the effectiveness of low rank updates. We further provide theoretical support based on random matrix theory, and extend our analysis to an MPS Adaptation PEFT method, which exhibits qualitatively similar behaviors.

Artificial Entanglement in the Fine-Tuning of Large Language Models

Abstract

Large language models (LLMs) can be adapted to new tasks using parameter-efficient fine-tuning (PEFT) methods that modify only a small number of trainable parameters, often through low-rank updates. In this work, we adopt a quantum-information-inspired perspective to understand their effectiveness. From this perspective, low-rank parameterizations naturally correspond to low-dimensional Matrix Product States (MPS) representations, which enable entanglement-based characterizations of parameter structure. Thereby, we term and measure "Artificial Entanglement", defined as the entanglement entropy of the parameters in artificial neural networks (in particular the LLMs). We first study the representative low-rank adaptation (LoRA) PEFT method, alongside full fine-tuning (FFT), using LLaMA models at the 1B and 8B scales trained on the Tulu3 and OpenThoughts3 datasets, and uncover: (i) Internal artificial entanglement in the updates of query and value projection matrices in LoRA follows a volume law with a central suppression (termed as the "Entanglement Valley"), which is sensitive to hyper-parameters and is distinct from that in FFT; (ii) External artificial entanglement in attention matrices, corresponding to token-token correlations in representation space, follows an area law with logarithmic corrections and remains robust to LoRA hyper-parameters and training steps. Drawing a parallel to the No-Hair Theorem in black hole physics, we propose that although LoRA and FFT induce distinct internal entanglement signatures, such differences do not manifest in the attention outputs, suggesting a "no-hair" property that results in the effectiveness of low rank updates. We further provide theoretical support based on random matrix theory, and extend our analysis to an MPS Adaptation PEFT method, which exhibits qualitatively similar behaviors.
Paper Structure (28 sections, 8 theorems, 97 equations, 43 figures, 1 table)

This paper contains 28 sections, 8 theorems, 97 equations, 43 figures, 1 table.

Key Result

Theorem 2.1

Under Assumption ass:outlier_bulk, let $T$ be the sequence length (number of tokens). In the limit $T\to\infty$, the von Neumann entropy scales as: where the prefactor $\mathcal{C}_{\mathrm{attn}}$ (termed as the Effective Attention Charge) is determined by the bulk spectrum spread parameter $\sigma>0$ of the limiting quartercircular law $Q_\sigma$ for the rescaled singular values of $\sqrt{T}\,A

Figures (43)

  • Figure 1: Key Findings. (i) Projection matrices ($\Delta W_Q$ and $\Delta W_V$) exhibit volume-law internal entanglement profiles with distinctive entanglement valleys that differ between FFT, LoRA and MPS adaptation. (ii) Attention matrices show area-law scaling with logarithmic corrections. Random matrix theory explains this through the Attention Cardy Formula. (iii) Despite internal differences, external attention outputs remain invariant, revealing a no-hair–like effect where the attention mechanism acts as a coarse-graining operator.
  • Figure 2: Artificial entanglement profiling of a random Gaussian matrix. The orange curve ($\chi$ = $\infty$) corresponds to the full SVD at each bond and closely matches the Page-curve prediction for Haar-random states (green dashed line). The blue curve ($\chi=32$) demonstrates the effect of truncating the MPS bond dimension the entropy saturates once the Schmidt rank exceeds $\chi$, forming a plateau, while the true entropy (the orange) continues to increase toward the Page limit.
  • Figure 3: Artificial entanglement profiling of $\Delta W_Q$ (a) and $\Delta W_V$ (b) across different bi-partition positions $k$ during FFT. Each curve corresponds to a training step, which shows how $S$ evolves and gradually converges as fine-tuning progresses.
  • Figure 4: Artificial entanglement profiling of $\Delta W_Q$ (a) and $\Delta W_V$ (b) during LoRA fine-tuning, similar to FIG. \ref{['fig:full_wq_wv']}.
  • Figure 5: Artificial entanglement profiling of $\Delta W_Q$ and $\Delta W_V$ as a function of LoRA rank $r$ in different steps. (a) $S_{\Delta W_Q}$ at the early time of fine-tuning (Step 1) and the late time (Step 1000). (b) $S_{\Delta W_V}$ at the early time of fine-tuning (Step 1) and the late time (Step 1000). These reveal how differing $r$ and training time jointly shape the entanglement structure of the learned updates.
  • ...and 38 more figures

Theorems & Definitions (13)

  • Theorem 2.1: The Attention Cardy Formula
  • Lemma 2.2: Stable rank implies small entanglement
  • Theorem 2.3: Output entanglement collapse
  • Theorem 8.1: Entanglement of the attention matrix: generally $\Theta(\log T)$
  • proof
  • Lemma 8.2: Stable rank control implies small entanglement
  • proof
  • Theorem 8.3: Output entanglement collapse (token--feature), conditional
  • proof
  • Lemma 10.1: Entanglement bound at the row--column cut
  • ...and 3 more