No preview available
Fine-tuning Llama 3 on Custom Data — Complete Colab Notebook
Description
A complete, well-documented Jupyter notebook for fine-tuning Llama 3 8B on your own dataset using QLoRA — all within Google Colab's free tier.
**What's covered:**
1. Environment setup (unsloth, transformers, trl, bitsandbytes)
2. Loading and preparing your custom dataset (JSONL format)
3. QLoRA configuration for T4 GPU (fits in 15GB VRAM)
4. Training loop with wandb logging
5. Evaluating the fine-tuned model
6. Merging LoRA weights with base model
7. Exporting to GGUF for local use with Ollama
**What you get:**
- .ipynb notebook file (fully runnable, all outputs cleared)
- Example dataset formatter script
- Instructions for uploading your own data
- Troubleshooting guide for common errors
**Tested on:** Google Colab T4 (free), A100 (Pro), local RTX 3090