Understanding Catastrophic Forgetting In LoRA via Mean-Field Attention Dynamics

Hugo Koubbi, Louis Hernandez, Matthieu Boussard

Low-Rank Adaptation (LoRA) has emerged as the gold standard for parameter-efficient fine-tuning of Large Language Models (LLMs). By updating only a tiny, low-rank matrix rather than billions of parameters, LoRA offers an incredibly favorable compute-to-performance trade-off. However, it remains plagued by a persistent issue: catastrophic forgetting. As the model acquires new skills, it often rapidly loses its original capabilities.

Because full-scale LLMs operate as mathematical "black boxes," pinpointing exactly why these relatively small parameter updates cause such dramatic degradation in base performance is notoriously difficult. Recent research bridges this gap by introducing a tractable mathematical "toy model" that mimics information flow through a Transformer, allowing us to study the geometric and dynamical roots of catastrophic forgetting.

The Mean-Field Transformer Framework

To make the complex inner workings of an LLM mathematically solvable, the researchers employ a Mean-Field Transformer viewpoint. This approach relies on several key conceptual shifts:

  • Tokens as Particles: The forward pass of a Transformer is modeled as a system of interacting particles (tokens) moving through a geometric space.
  • Depth as Time: Leveraging the Neural ODE framework, the layers of a Transformer are treated as continuous time steps in a dynamical system.
  • Tied-Weights Assumption: The model assumes a single attention head with weights that are "tied" (identical) across layers, simplifying the math while preserving core dynamics.
  • Geometric Forgetting: Forgetting is defined not merely as a drop in accuracy, but as a geometric drift. If a LoRA update shifts the "clusters" of token representations too far from their original positions—measured via Wasserstein distance—the model is considered to have "forgotten" its prior state.

By analyzing the eigenvalues and eigenvectors of the attention weight matrices ($Q, K, V$), the authors can observe how the "shape" of the model's internal logic warps during fine-tuning.

Key Insights: The Geometry of Forgetting

1. The "Stability Window" and Phase Transitions

One of the most significant findings is that forgetting is not a linear process. There exists a "stability window" where the model can absorb small perturbations without losing its base capabilities. However, once the norm of the LoRA update or the depth of the model exceeds a specific threshold, the system hits a phase transition (or bifurcation). At this point, the representation geometry suddenly collapses or shifts into a "forgotten" state.

2. The Protective Power of the Eigengap

The stability of a model is heavily dictated by its "spectral gap"—the mathematical distance between its largest eigenvalue and the rest. A larger eigengap acts like a deep "potential well," anchoring the token representations and making the model highly resistant to the geometric drift that causes forgetting.

3. LoRA is Not Isotropic

Theoretically, random updates to a model's weights shouldn't cause targeted interference. However, the researchers found that learned LoRA updates are highly biased. During fine-tuning, LoRA tends to "lock on" to the most important, stable directions of the base model. This direct alignment is precisely what causes interference and precipitates catastrophic forgetting.

4. Bifurcation Depth

Forgetting does not happen uniformly across the model. It initiates at a specific depth (layer). As fine-tuning progresses and the LoRA update grows, this "bifurcation point" creeps backward, moving from the later layers of the model toward the earlier ones.

Empirical Validation

The authors validated their theoretical bounds—which show that representational drift grows doubly exponentially with depth but is controlled by perturbation size—using both synthetic and real-world datasets:

  • Qwen 3 (0.6B): Experiments tracking evaluation perplexity confirmed the existence of phase transitions. As the Frobenius norm of the LoRA update increased, researchers observed a sharp "jump" in loss on the original task, perfectly mirroring the theoretical shift from a "Stable Regime" to a "Collapsed Regime."
  • Llama 2 (7B) & ALBERT: Spectral analysis of real-world attention matrices verified the clustering behavior of tokens. Interestingly, experiments showed that for random updates, the rank ($r$) of the matrix doesn't matter—only the total norm does. But for trained updates, lower-rank adapters actually exhibited a stronger tendency to interfere with the base model's stable directions.

Limitations and the Path Forward

While the mean-field toy model provides profound intuition, it relies on a "tied-weights" assumption (averaging weights across layers) that misses the nuanced layer-by-layer contributions found in real Transformers. Furthermore, the study primarily focuses on the effects of updates at inference time, leaving the complex optimization dynamics of gradient descent for future exploration. Real-world models like Llama 2 also possess significantly more intricate spectral properties than the toy model suggests.

Despite these limitations, this geometric framework opens an exciting door for future research. By understanding that forgetting is tied to specific spectral directions, future developers could design "forgetting-resistant" versions of LoRA—for instance, by mathematically projecting fine-tuning updates away from the base model's most stable eigenvectors.

Summary updated

BibTeX
@inproceedings{koubbi2026understanding,
  author = {Hugo Koubbi and Louis Hernandez and Matthieu Boussard},
  title = {{Understanding Catastrophic Forgetting In LoRA via Mean-Field Attention Dynamics}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=MXvuMNd3oI},
}
Figure