LlamaFactory

hiyouga/LlamaFactory

Unified Efficient Fine-Tuning of 100+ LLMs & VLMs (ACL 2024)

73k
Stars
8.9k
Forks
1.1k
Open issues
339
Watchers
Python Apache-2.0Last pushed Jul 7, 2026

Unified Efficient Fine-Tuning of 100+ LLMs & VLMs (ACL 2024)

Categories

Tags

Similar tools

Install

pip install LlamaFactory

README

Used by Amazon, NVIDIA, Aliyun, etc.

Supporters ❤️


Easily fine-tune 100+ large language models with zero-code CLI and Web UI

👋 Join our WeChat and NPU user groups.

[ English | 中文 ]

Fine-tuning a large language model can be easy as...

https://github.com/user-attachments/assets/3991a3a8-4276-4d30-9cab-4cb0c4b9b99e

Start local training:

  • Please refer to usage

Start cloud training:

Read technical notes:

[!NOTE] Except for the above links, all other websites are unauthorized third-party websites. Please carefully use them.

Table of Contents

  • Features
  • Blogs
  • Changelog
  • Supported Models
  • Supported Training Approaches
  • Provided Datasets
  • Requirement
  • Getting Started
    • Installation
    • Data Preparation
    • Quickstart
    • Fine-Tuning with LLaMA Board GUI
    • Build Docker
    • Deploy with OpenAI-style API and vLLM
    • Download from ModelScope Hub
    • Download from Modelers Hub
    • Use W&B Logger
    • Use SwanLab Logger
  • Projects using LLaMA Factory
  • License
  • Citation
  • Acknowledgement

Features

  • Various models: LLaMA, LLaVA, Mistral, Mixtral-MoE, Qwen3, Qwen3-VL, DeepSeek, Gemma, GLM, Phi, etc.
  • Integrated methods: (Continuous) pre-training, (multimodal) supervised fine-tuning, reward modeling, PPO, DPO, KTO, ORPO, etc.
  • Scalable resources: 16-bit full-tuning, freeze-tuning, LoRA and 2/3/4/5/6/8-bit QLoRA via AQLM/AWQ/GPTQ/LLM.int8/HQQ/EETQ.
  • Advanced algorithms: GaLore, BAdam, APOLLO, Adam-mini, Muon, OFT, DoRA, LongLoRA, LLaM