llamafactory vs nanochat

Two of the top projects in Training and fine-tuning, side by side: who leads on each score part and who each one suits, then setup, license, activity and what each review found.

11st of 5 in Training and fine-tuning

llamafactory

Fine-tuning toolkit for 100+ LLMs with a CLI and Gradio web UI

#44th of 5 in Training and fine-tuning

nanochat

Minimal PyTorch codebase to train and chat with a small GPT-2-class LLM

49 out of 100

Verdict

llamafactory ranks higher, 74 to 49. Of the 4 score parts we measure for both, llamafactory leads on 4, nanochat on none.

  • Adoptionllamafactory leads by 30 points, 92 to 62: a wide gap.
  • Freshnessllamafactory leads by 5 points, 100 to 95.
  • Maintenancellamafactory leads by 36 points, 38 to 2: a wide gap.
  • Agent-readyllamafactory leads by 40 points, 55 to 15: a wide gap.

Pick llamafactory if you are

Engineers fine-tuning open LLMs on their own GPUs, with or without code

  • Broad method coverage: SFT, PPO, DPO, KTO, ORPO, LoRA, QLoRA via AQLM/AWQ/GPTQ/HQQ/EETQ
  • Supports GaLore, BAdam, APOLLO, Muon, DoRA, PiSSA, plus Unsloth and Liger Kernel speedups

Pick nanochat if you are

Researchers and engineers learning or experimenting with end-to-end LLM training

  • Covers tokenizer, pretraining, SFT, RL, eval and inference in one repo
  • Single `--depth` dial sets all other hyperparameters automatically
llamafactory vs nanochat: score parts and facts
What we comparellamafactorynanochat
Score parts, out of 100
Adoption92, widely used62, popular
Freshness100, active95, active
Maintenance38, patchy2, weak
Easy to runNot scored for this kindNot scored for this kind
Agent-ready55, partly15, none
Facts from GitHub and the README
Stars75.5k58.6k
LicenseApache-2.0 (permissive)MIT (permissive)
Last commitOct 2026Jul 2026
Last releaseMay 2026None published
LanguagePythonPython
DockerYesNo
GPURequiredRequired
arm64 or Apple SiliconMentionedMentioned

llamafactory

LlamaFactory fine-tunes language and multimodal models through YAML-configured CLI runs or the LLaMA Board Gradio UI. It covers pre-training, SFT, reward modeling, PPO, DPO, KTO and ORPO, with full-tuning, freeze-tuning, LoRA and 2 to 8-bit QLoRA. Trained models can be served through an OpenAI-style API using vLLM or SGLang workers.

Who it is for: Engineers fine-tuning open LLMs on their own GPUs, with or without code

Strengths

  • Broad method coverage: SFT, PPO, DPO, KTO, ORPO, LoRA, QLoRA via AQLM/AWQ/GPTQ/HQQ/EETQ
  • Supports GaLore, BAdam, APOLLO, Muon, DoRA, PiSSA, plus Unsloth and Liger Kernel speedups
  • Covers multimodal and audio models such as Qwen3-VL, LLaVA and Qwen2-Audio
  • Runs on NVIDIA, AMD ROCm and Ascend NPU, with hosted Colab and PAI-DSW notebooks

Weaknesses

  • Official documentation is marked WIP in the README
  • No VRAM or RAM figures in the visible README; hardware requirements unknown here
  • Web UI is for training and chat, not a production serving layer
  • Many optional backends (vLLM, SGLang, Unsloth, KTransformers) add install complexity
  • GPU required
  • Docker + Compose
  • Needs PyTorch, Hugging Face Transformers, Gradio, vLLM (optional), SGLang (optional)
  • Models: LLaMA, LLaVA, Mistral, Mixtral-MoE, Qwen3

nanochat

nanochat covers tokenizer training, pretraining, SFT, RL, evaluation and a CLI chat interface in one small Python codebase. A single `--depth` setting derives width, heads, learning rate and training horizon, so one knob produces a compute-optimal model series. The reference speedrun trains a GPT-2-grade model in about 1.65 hours on an 8xH100 node per the leaderboard.

Who it is for: Researchers and engineers learning or experimenting with end-to-end LLM training

Strengths

  • Covers tokenizer, pretraining, SFT, RL, eval and inference in one repo
  • Single `--depth` dial sets all other hyperparameters automatically
  • Public time-to-GPT-2 leaderboard with commits and CORE scores
  • Same scripts run on one GPU via gradient accumulation, or on CPU/MPS

Weaknesses

  • Reference speedrun needs an 8xH100 node, roughly $48 of rented compute
  • Under 80GB VRAM requires manually lowering `--device-batch-size`
  • CPU/MPS path only trains a tiny model with weak results
  • Chat is CLI-only in the README; resulting model is small and hallucinates
  • GPU required
  • Needs PyTorch, uv, wandb
  • Models: nanochat GPT (depth-scaled), bfloat16, float32, float16

More in Training and fine-tuning

Building with these?

We help teams pick an open-source AI stack and run it in production. Client work never changes a rank.