Lizard: An Efficient Linearization Framework for Large Language Models

Chien Van Nguyen, Ruiyi Zhang, Hanieh Deilamsalehy, Puneet Mathur, Viet Dac Lai +7 more
7/11/2025
cs.CLcs.LG

No confident code implementation found for this paper. 2 possible matches can be shown below.

Abstract

We propose Lizard, a linearization framework that transforms pretrained Transformer-based Large Language Models (LLMs) into subquadratic architectures. Transformers faces severe computational and memory bottlenecks with long sequences due to the quadratic complexity of softmax attention and the growing Key-Value (KV) cache that makes inference memory-bound by context length. Lizard addresses these limitations by introducing a subquadratic attention mechanism that closely approximates softmax attention while preserving model quality. Unlike prior linearization methods constrained by fixed, non-adaptive structures, Lizard augments the architecture with compact, learnable modules that enable adaptive memory control and robust length generalization. Moreover, we introduce a hardwareaware algorithm that solves numerical instability in gated attention to accelerate training. Extensive experiments show that Lizard achieves near-lossless recovery of its teacher model's performance, significantly outperforming previous methods by up to 9.4 - 24.5 points on the 5-shot MMLU benchmark and demonstrating superior associative recall.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 2 weaker matches are hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{nguyen2025lizard,
  title  = {Lizard: An Efficient Linearization Framework for Large Language Models},
  author = {Chien Van Nguyen and Ruiyi Zhang and Hanieh Deilamsalehy and Puneet Mathur and Viet Dac Lai and Haoliang Wang and Jayakumar Subramanian and Ryan A. Rossi and Trung Bui and Nikos Vlassis and Franck Dernoncourt and Thien Huu Nguyen},
  year   = {2025},
  eprint = {2507.09025},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2507.09025v3}
}

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/2507.09025.svg)](https://codeofpaper.com/paper/2507.09025)

Discussion