NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

LoLCATs: On Low-Rank Linearizing of Large Language Models

Michael Zhang, Simran Arora, Rahul Chalamala, Benjamin Frederick Spector, Alan Wu, Krithik Ramesh, Aaryan Singhal, Christopher Re

TL;DR

LoLCATs is a breakthrough two-step method for converting standard, "quadratic" Transformers into efficient, subquadratic models with minimal compute. By training linear layers to mimic original attention outputs and then refining with LoRA, researchers successfully linearized models as large as Llama 3.1 405B—achieving state-of-the-art performance while using 500x fewer tokens than previous methods.

What Problem Does This Paper Address?

Standard Large Language Models (LLMs) like Llama or Mistral are built on "softmax attention," which has a major scaling flaw: its computational cost grows quadratically ($O(n^2)$) with the length of the input sequence. This makes processing long documents or large batches incredibly expensive.

"Linearizing" these models—replacing softmax with subquadratic alternatives—is the holy grail of efficient AI. However, previous attempts faced a "triple threat" of failures:

  1. Quality Loss: Linearized models usually perform significantly worse than their original counterparts.
  2. High Cost: They often required retraining on billions of tokens.
  3. Poor Scalability: Most methods only worked on small models (1B to 7B parameters), leaving the 70B+ giants untouched.

Methods

The authors propose LoLCATs (Low-rank Linear Conversion via Attention Transfer), a highly efficient two-step framework.

Overview of the LoLCATs two-step linearizing process.
  1. Step 1: Attention Transfer (MSE Matching): Instead of retraining the whole model, they replace the softmax attention layers with a hybrid "Linear + Sliding Window" analog. They then train only these new layers to match the outputs of the original softmax layers using a Mean Squared Error (MSE) loss. This "teacher-student" approach allows the new layers to inherit the original model's knowledge quickly.
  2. Step 2: Low-rank Adjusting (LoRA): To fix any remaining approximation errors, they perform a brief end-to-end fine-tuning using Low-Rank Adaptation (LoRA). This step is extremely parameter-efficient, updating less than 0.2% of the model's weights.

To handle massive models like the 405B Llama, they introduced block-by-block training, splitting the model into chunks to manage memory and compute constraints.

Datasets

  • Training/Linearizing: The primary data used was a cleaned version of the Alpaca dataset (50k samples) and subsets of RedPajama.
  • Task-Specific Tuning: CommonsenseQA (CQA) was used to boost MMLU scores, and synthetic passkey-retrieval data was used to improve long-context performance.
  • Evaluation: The models were tested on the LM Evaluation Harness, including benchmarks like MMLU (5-shot), PiQA, ARC, HellaSwag, and Winogrande.

Key Insights and Ideas

  • MSE on Outputs > Weight Matching: Previous works tried to make linear attention weights look like softmax weights. LoLCATs shows it is much more effective to match the final output of the attention head.
  • The Hybrid Advantage: Pure linear attention often struggles with "spiky" distributions (focusing on very specific tokens). By adding a tiny sliding window (just 64 tokens) of standard softmax attention, the model maintains high quality while staying subquadratic.
  • Efficiency is Scalability: Because LoLCATs requires so few tokens (only 40M compared to 20B+ in prior work), it becomes feasible to linearize the world's largest open-weights models on academic-scale hardware.
  • Layer-wise Sensitivity: The authors found that later layers in LLMs are much harder to linearize and produce higher errors, which is why the block-by-block supervision is so critical for larger models.

Key Results

LoLCATs achieves state-of-the-art performance while drastically reducing the required training budget.

LoLCATs achieves higher zero-shot performance with orders of magnitude fewer training tokens.
  • State-of-the-Art: LoLCATs-linearized Llama 3 8B and Mistral 7B outperformed all previous subquadratic models, closing the quality gap with the original Transformers by nearly 80% on MMLU.
  • The First 405B Linearization: LoLCATs successfully converted Llama 3.1 70B and 405B. The 405B model was linearized in just 21 total GPU hours—a fraction of the time it takes to even run a standard fine-tuning.
  • Massive Efficiency Gains: Compared to prior linearization methods, LoLCATs used 0.2% of the parameters and 0.04% of the training tokens.
  • Speedup: The linearized models support 3x higher throughput and 64x larger batch sizes than standard FlashAttention-2 when generating long sequences.

Limitations and Future Work

  • The Remaining Gap: While LoLCATs significantly closes the gap, linearized models still trail the original Transformers by a few points on complex benchmarks like MMLU.
  • Retrieval Issues: Linearized models struggle with "needle-in-a-haystack" tasks unless they are specifically trained on retrieval data.
  • Future Directions: The authors suggest exploring better feature maps to further reduce MSE and investigating how linearization affects the "guardrails" and safety alignment of instruction-tuned models.

Summary updated

BibTeX
@inproceedings{zhang2025lolcats,
  author = {Michael Zhang and Simran Arora and Rahul Chalamala and Benjamin Frederick Spector and Alan Wu and Krithik Ramesh and Aaryan Singhal and Christopher Re},
  title = {{LoLCATs: On Low-Rank Linearizing of Large Language Models}},
  booktitle = {International Conference on Learning Representations},
  year = {2025},
  url = {https://openreview.net/forum?id=8VtGeyJyx9},
}
Figure