unsloth

Guides LLM fine-tuning with Unsloth using LoRA, QLoRA, and GRPO reinforcement learning.

5|2|Updated Aug 10, 2026
One-click install
npx skills add https://github.com/MedTiLab/Auto-meta-analysis --skill unsloth-medtilab
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: unsloth
Source: https://github.com/MedTiLab/Auto-meta-analysis/tree/main/skills/fine-tuning/unsloth
Command: npx skills add https://github.com/MedTiLab/Auto-meta-analysis --skill unsloth-medtilab

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires unsloth, torch, transformers, trl, datasets, peft, and includes references (resource) components.

What problem does it solve? Fine-tuning large language models locally is slow, memory-hungry, and error-prone, and developers often struggle to choose the right quantization, hyperparameters, and export formats for their hardware. ## Core Features & Use Cases - Fast Fine-Tuning Guidance: Provides official documentation for training Llama, Qwen, Gemma, Mistral, Phi, and gpt-oss models 2x faster with up to 70-80% less VRAM using LoRA and QLoRA. - Reinforcement Learning Support: Covers GRPO, GSPO, DPO, ORPO, and KTO training for reasoning models, including vision RL for multimodal models. - Model Export & Deployment: Documents saving fine-tuned models to GGUF, Ollama, vLLM, and SGLang formats for local inference and deployment. - Use Case: A developer with a single consumer GPU wants to fine-tune Llama 3.1 (8B) on a custom dataset and run it in Ollama; this Skill provides the exact VRAM requirements, hyperparameter guidance, and export steps. ## Quick Start Ask how to fine-tune a specific model like Qwen3 or Llama 3.1 with Unsloth on your available GPU and dataset.

Frequently Asked Questions about unsloth

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fine-tune Llama 3.1 with Unsloth?▼

Install Unsloth via pip, load the model with FastLanguageModel.from_pretrained using 4-bit quantization, attach LoRA adapters, and train with the TRL SFTTrainer on your dataset. Free Colab notebooks are available for Llama 3.1 (8B) and many other models.

How much VRAM do I need for QLoRA fine-tuning?▼

QLoRA 4-bit fine-tuning requires about 3.5 GB for 3B models, 5 GB for 7B, 6 GB for 8B, and 41 GB for 70B models. LoRA 16-bit training needs significantly more, roughly 19 GB for 7B and 164 GB for 70B models.

LoRA vs QLoRA: which one should I use?▼

QLoRA is recommended as the starting point because it combines LoRA adapters with 4-bit quantization, dramatically lowering memory usage. With Unsloth's dynamic 4-bit quants, accuracy loss compared to 16-bit LoRA is negligible.

Does Unsloth work on Windows and AMD GPUs?▼

Unsloth supports Linux and Windows (including WSL), and works on NVIDIA GPUs with CUDA capability 7.0 or higher, plus AMD and Intel GPUs. An official Docker image is also available for setup-free training.

How do I run a fine-tuned model in Ollama or vLLM?▼

After training, save the model to GGUF format for Ollama, llama.cpp, and Open WebUI, or merge to 16-bit for vLLM and SGLang deployment. The documentation includes step-by-step saving and troubleshooting guides.

Can Unsloth train reasoning models with reinforcement learning?▼

Yes, Unsloth supports GRPO, GSPO, DPO, ORPO, and KTO reinforcement learning with up to 80% less VRAM than other libraries. It includes tutorials for training reasoning models like DeepSeek-R1 and vision RL for multimodal models.