Fine-TuningMLModels

Hugging Face smol-course: Fine-Tuning Language Models

by Hugging Face

IntermediateCourseFree~7 units, 3–4 hours/week each, self-paced

Fine-tune and align small LLMs end-to-end on hardware you already own — no paid APIs.

Start LearningReviewed July 9, 2026

Overview

The 🤗 smol-course is Hugging Face's free, open, code-first course on fine-tuning language models, built around their SmolLM3 and SmolVLM2 models so every notebook runs on most local machines with minimal GPU and no paid services. It moves from theory to practice across units on instruction tuning and supervised fine-tuning (SFT), model evaluation, preference alignment with DPO, vision-language models, reinforcement learning optimization, and synthetic data generation. Each unit pairs conceptual material with runnable notebooks and a real-world assignment, using Hugging Face's own libraries (Transformers, TRL, PEFT). The techniques transfer directly to larger models, making it a practical on-ramp to the full LLM post-training stack.

At a Glance

Topic
Fine-Tuning
Level
Intermediate
Format
Course
Cost
Free
Duration
~7 units, 3–4 hours/week each, self-paced
Provider
Hugging Face
Hands-on
Yes — code/exercises
Certificate
None

What You’ll Learn

  • Run supervised fine-tuning (SFT) and instruction tuning on small LLMs with Transformers and TRL
  • Align models to human preferences using Direct Preference Optimization (DPO)
  • Evaluate fine-tuned models to measure real improvement
  • Fine-tune vision-language models (VLMs) like SmolVLM2
  • Apply reinforcement learning optimization and generate synthetic training data
  • Adapt small, cost-efficient models to a specific domain and run them locally

Highlights

  • Everything runs on a consumer/local GPU — no paid APIs required
  • Uses Hugging Face's production libraries (Transformers, TRL, PEFT) rather than toy code
  • Covers the full post-training arc: SFT → DPO → RL → synthetic data, plus VLMs
  • Recently re-released on Hugging Face Learn with per-unit assignments

Who It’s For

Best For

  • AI/ML engineers who want to fine-tune LLMs without cloud costs
  • Developers building small, domain-specialized or on-device models
  • Practitioners moving from prompting to owning the post-training pipeline

Prerequisites

  • Working Python and PyTorch familiarity
  • Basic understanding of transformers / how LLMs are trained
  • A local or free-tier GPU (e.g. Colab) to run the notebooks

FAQ

What is Hugging Face smol-course: Fine-Tuning Language Models?

A free, hands-on Hugging Face course that teaches software engineers how to fine-tune and align small language models (SmolLM3, SmolVLM2) from instruction tuning through preference alignment and RL. Built for developers who want practical fine-tuning skills that run on a local or consumer GPU.

Is Hugging Face smol-course: Fine-Tuning Language Models free?

Hugging Face smol-course: Fine-Tuning Language Models is free to access.

What level is Hugging Face smol-course: Fine-Tuning Language Models for?

Hugging Face smol-course: Fine-Tuning Language Models is aimed at a intermediate audience. Recommended background: Working Python and PyTorch familiarity, Basic understanding of transformers / how LLMs are trained, A local or free-tier GPU (e.g. Colab) to run the notebooks.

How long does Hugging Face smol-course: Fine-Tuning Language Models take?

Expect roughly ~7 units, 3–4 hours/week each, self-paced. Most learners work through it at their own pace.

What will I learn from Hugging Face smol-course: Fine-Tuning Language Models?

You'll learn: Run supervised fine-tuning (SFT) and instruction tuning on small LLMs with Transformers and TRL; Align models to human preferences using Direct Preference Optimization (DPO); Evaluate fine-tuned models to measure real improvement; Fine-tune vision-language models (VLMs) like SmolVLM2; Apply reinforcement learning optimization and generate synthetic training data; Adapt small, cost-efficient models to a specific domain and run them locally.

Topics

fine-tuningSFTDPOsmall language modelsTRLPEFT