Run 70B+ large language models on a single low-end GPU with minimal VRAM
AirLLM is an open source Python library that dramatically reduces the memory required to run large language models, letting a 70B parameter model run on a single 4GB GPU without quantization, distillation, or pruning. It extends this same approach to enormous models, including Llama 3.1 405B on 8GB, DeepSeek-V3 at 671B parameters on roughly 12GB, and even Kimi K3, a 2.8 trillion parameter sparse mixture of experts model, on under 4GB of VRAM.
The core technique keeps only one transformer layer on the GPU at any given time, streaming the rest from disk as needed, so VRAM usage depends on layer size rather than total model size. For sparse MoE architectures, AirLLM goes further by streaming only the specific experts a token actually routes to instead of loading an entire layer. An optional block-wise quantization based model compression mode, using 4bit or 8bit settings, can further speed up inference by up to 3x with minimal accuracy loss, since the bottleneck is primarily disk loading rather than compute.
Key features include:
AirLLM is released under the Apache 2.0 license and is actively maintained, with recent updates adding FP8 model support and Kimi K3 compatibility. The project is used through a simple pip install and a single AutoModel.from_pretrained call, and it credits SimJeg's Kaggle competition work as a foundation for its layer streaming approach.
Repository