AI/TLDR

Axolotl

Config-driven fine-tuning for open LLMs, from LoRA to full post-training

Overview

Axolotl is a free, open-source framework for fine-tuning and post-training open large language models. Instead of writing custom training loops, you describe a job in a YAML config file (the model, dataset, and method) and run a single command. It supports common workflows like supervised fine-tuning (SFT), parameter-efficient methods such as LoRA and QLoRA, and preference-tuning methods like DPO and GRPO.

It targets developers and ML engineers who want to adapt existing open models to their own data without building infrastructure from scratch. Axolotl covers many model families, including Llama, Qwen, Mistral, Gemma, and GLM, and handles single-GPU runs as well as multi-GPU and multi-node training through DeepSpeed and FSDP.

Within the fine-tuning framework category, Axolotl sits between low-level training libraries and managed platforms: you keep full control over the training recipe in a reproducible config, while the framework handles data formatting, distributed setup, and the training loop for you.

What it does

  • Config-driven training: define the whole job (model, dataset, method, hyperparameters) in a single YAML file
  • Multiple training methods: SFT, LoRA and QLoRA, plus preference tuning with DPO and GRPO
  • Broad model support across families such as Llama, Qwen, Mistral, Gemma, GLM, and many more
  • Multi-GPU and multi-node training via DeepSpeed and FSDP
  • Ready-made example configs you can fetch and adapt with `axolotl fetch examples`
  • Docker image and uv-based install for reproducible environments

Getting started

Axolotl is a Python framework that needs a CUDA GPU. Install it, fetch the example configs, then start a training run from a YAML file.

Install Axolotl

The project is uv-first. Create a Python 3.12 environment and install Axolotl with the DeepSpeed extra. Set the Torch backend to match your CUDA version.

bashbash
curl -LsSf https://astral.sh/uv/install.sh | sh
export UV_TORCH_BACKEND=cu128
uv venv --python 3.12
source .venv/bin/activate
uv pip install torch==2.10.0 torchvision
uv pip install --no-build-isolation axolotl[deepspeed]

Or run it with Docker

If you prefer not to manage a local environment, use the prebuilt image with GPU access.

bashbash
docker run --gpus '"all"' --ipc=host --rm -it axolotlai/axolotl:main-latest

Fetch the example configs

Download the bundled example YAML files (and optional DeepSpeed configs) to use as starting points.

bashbash
axolotl fetch examples
axolotl fetch deepspeed_configs

Train a model

Point the train command at a config file. This example runs LoRA fine-tuning on a 1B Llama 3 model.

bashbash
axolotl train examples/llama-3/lora-1b.yml

Commands and code are distilled from the project's own documentation — always check the official repo for the latest.

When to use it

  • Adapt an open base model to your own instruction or chat dataset with SFT
  • Fine-tune a large model cheaply on a single GPU using LoRA or QLoRA
  • Align a model to human preferences with DPO or GRPO post-training
  • Scale a training run across multiple GPUs or nodes using DeepSpeed or FSDP

How Axolotl compares

Axolotl alongside other open-source fine-tuning frameworks tools AI/TLDR tracks, ranked by GitHub stars.

ToolStarsWhat it does
LLaMA-Factory★ 72.3kAn end-to-end training suite with a web UI that covers pre-training, supervised fine-tuning, and RLHF for hundreds of LLMs and multimodal models.
Unsloth★ 66.9kA library that speeds up LoRA and QLoRA fine-tuning while cutting memory use, aimed at training models on a single GPU.
PEFT★ 21.3kHugging Face's library of parameter-efficient fine-tuning methods such as LoRA, DoRA, and prompt tuning that train small adapters instead of full models.
FinGPT★ 20.5kFinGPT is an open-source project of financial LLMs, fine-tuned with LoRA on news and tweet data for tasks like sentiment analysis, relation extraction, and stock-move forecasting.
ms-swift★ 14.6kModelScope's framework for fine-tuning and deploying 600+ LLMs and 300+ multimodal models, supporting PEFT and full-parameter SFT, DPO, and GRPO.
LitGPT★ 13.4kAn open-source toolkit from Lightning AI to pretrain, finetune, and serve 20+ large language models, each written from scratch for speed and full control.
Axolotl★ 12.1kConfig-driven fine-tuning for open LLMs, from LoRA to full post-training
Ludwig★ 11.7kLudwig is a low-code framework that lets you train, fine-tune, and deploy LLMs, multimodal, and tabular models using a YAML config instead of boilerplate Python.