hiyouga/LlamaFactory
LLaMA-Factory is a comprehensive framework for training and serving large language models, supporting pretraining, supervised fine-tuning, and reinforcement learning methods like DPO, KTO, and PPO. It provides a modular architecture for distributed training (FSDP2, DeepSpeed, Megatron Bridge) and flexible inference via Hugging Face, vLLM, and SGLang backends. The system includes a unified CLI, an OpenAI-compatible API server, and a Gradio-based web UI for model management and evaluation.
53.0
Adequate · 2 August 2026
45k
lines of production code
Python
primary language
1
bus factor · 306 authors in all
3
measurements over time
How it got here
2023–2024 · Modular training architecture and API server
The project underwent a comprehensive architectural overhaul, replacing legacy scripts with a unified CLI and modular training backends for SFT, DPO, KTO, and pretraining. This period also introduced an OpenAI-compatible API server, a Gradio-based Web UI, and extensive unit and end-to-end tests to support the new modular design.
40 changes
2025 · LlamaFactory v1 architecture and plugin system
This period focused on building the new v1 training and inference engine, introducing a modular plugin system for models, kernels, and data processing. The work established the core infrastructure for distributed training, optimized hardware-specific kernels, and added comprehensive test coverage for the new architecture.
24 changes
2026 · v1 training infrastructure and parallelism
This period focused on building the core v1 training pipeline, introducing new utilities for batching, checkpointing, and inference. Significant work was done to support advanced distributed training via FSDP2, Ulysses sequence parallelism, and the HyperParallel backend. The changes also included adding the Muon optimizer and structured callback systems to enhance training extensibility and logging.
11 changes
Survey your own repository
hiyouga/LlamaFactory was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point the surveyor at a repository you know and see whether you agree with it.
About this page
- The description of this project is derived from its own commit history, not from its README.
- The score is its highest published measurement, taken on 2 August 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit 62ae362455 — the exact code this score is about.
- Scored under rubric rubric-2026.08.18. Score the same commit under that rubric and you get the same number.