maxtext
FreeA simple, performant and scalable Jax LLM!
About maxtext
MaxText is a high-performance, highly scalable, open-source LLM library and reference implementation written in pure Python/JAX, targeting Google Cloud TPUs and GPUs for training. It provides a library of high-performance models including Gemma, Llama, DeepSeek, Qwen, and Mistral (with newer models such as Qwen3, Kimi-K2, and GPT-OSS added regularly). MaxText supports pre-training at scale (up to tens of thousands of chips) and scalable post-training using techniques like Supervised Fine-Tuning (SFT), Group Relative Policy Optimization (GRPO), and Group Sequence Policy Optimization (GSPO). The library achieves high Model FLOPs Utilization (MFU) and tokens/second from single-host to very large clusters while remaining simple and largely optimization-free due to the power of JAX and the XLA compiler. It serves as a launching point for ambitious LLM projects in both research and production. MaxText is open source on GitHub under the AI-Hypercomputer organization.
Key Features
Pros & Cons
- High performance and scalability from single host to thousands of chips
- Supports a wide range of popular LLM architectures out of the box
- Advanced training techniques (SFT, GRPO, GSPO) integrated for post-training
- Simple and optimization-free code thanks to JAX and XLA compiler
- Open source with permissive license and active development
- Works on both TPUs and GPUs on Google Cloud
- Primary support is for Python 3.12; other Python versions may encounter compatibility issues
- Optimized for Google Cloud TPU/GPU hardware, which may limit portability to other environments
- Requires familiarity with JAX and distributed training concepts for best use
- Breaking changes occasionally (e.g., removal of legacy post-training shims) require migration