How to finetune LLMs on custom data domains (CPT tutorial with Unsloth)

How to finetune LLMs on custom data domains (CPT tutorial with Unsloth)

🎙 Neural Breakdown with AVB 👥 34K 📅 March 29, 2026 ⏱ 24 min 👁 10K 📄 tutorial 🧭 2026-08-15
Available in: English (current) Français

Keywords

CPTLoRARS-LoRAUnslothevaluation metrics

Summary

This tutorial by Neural Breakdown with AVB focuses on continued pre-training (CPT) of small language models on custom domain data, using the SmolLM-135M model and the Unsloth library. The author explains the goal of CPT: to adapt a general base model to a specific domain, here recent arXiv papers on deep learning. The video covers dataset preparation, including downloading papers via the arXiv API, cleaning text, and handling context length via truncation or packing. It discusses key hyperparameters like max length, batch size, learning rate, gradient accumulation, and gradient clipping, emphasizing their interplay. The author compares full fine-tuning vs. LoRA, finding LoRA more efficient and less prone to catastrophic forgetting. Evaluation uses cross-entropy loss, ROUGE, BLEU, and BERTScore on a held-out validation set. Experiments show that increasing dataset size and cleaning data (removing references) significantly improve performance, while RS-LoRA allows higher ranks without diminishing returns. The video concludes with practical advice and references to the project repository and Unsloth resources.

160 words

Critical Evaluation

Value of the Information & Strength of the Argument

The video provides valuable practical insights into fine-tuning LLMs, emphasizing experimental methodology over mere code. The author clearly explains the reasoning behind each decision, such as choosing LoRA over full fine-tuning due to cost and stability, and using RS-LoRA to overcome scaling limitations. The argumentation is solid, grounded in hands-on experiments and standard ML principles (e.g., overfitting/underfitting). The author also highlights the importance of dataset quality and size, which is often overlooked. The tutorial is well-structured, with clear explanations of hyperparameters and evaluation metrics. However, some claims, like the superiority of RS-LoRA, are presented without deep theoretical backing, but the practical results support them. Overall, the value is high for practitioners seeking to apply CPT.

Scientific Rigor, Source Quality, Title Accuracy

The video demonstrates scientific rigor by following a systematic experimental approach: setting up an evaluation harness, using validation sets, early stopping, and comparing multiple configurations. The author cites relevant resources, including the Unsloth documentation, the SmolLM model on Hugging Face, and the project’s GitHub repository. The title accurately reflects the content, and the video stays on topic. The author also mentions Andrej Karpathy’s approach to auto research, which adds credibility. The sources are appropriate and directly related to the tutorial. No comments were provided for analysis.

216 words

Title / Content Match

The title accurately reflects the content: a tutorial on fine-tuning LLMs on custom data domains using CPT with Unsloth.

Quality & Reliability

8/10

The video provides a clear, practical tutorial on continued pre-training (CPT) with a focus on experimental methodology. The author demonstrates hands-on experience, explains key concepts (LoRA, RS-LoRA, packing/truncating, evaluation metrics) and shares reproducible code. The approach is transparent about limitations and trade-offs, and the claims are supported by practical results. However, the video is a tutorial rather than a peer-reviewed study, and some claims (e.g., about RS-LoRA) are presented without deep theoretical justification.

Key Moments

Cited Sources

Concurring Sources

Contribution & Novelties

The video offers a practical, hands-on guide to continued pre-training (CPT) for domain adaptation, emphasizing experimental methodology and dataset preparation. It provides a clear comparison between full fine-tuning and LoRA, and introduces RS-LoRA as a technique to improve scaling. The author shares his iterative process, including common pitfalls like overfitting and the importance of data cleaning. This is valuable for practitioners looking to fine-tune small models on custom data.

Pour aller plus loin :

145 words

Radar Profile

The radar profile shows high scores in information quantity, quality, and reliability, with a slightly lower technical level. This indicates a well-balanced tutorial that is both informative and trustworthy, though it may require some prior knowledge to fully grasp the technical details.

Reliability 8/10