What is Fine-Tuning?
Fine-tuning uses a pre-trained model, such as OpenAI’s GPT series, as a foundation.
The process involves further training on a smaller, domain-specific dataset. This approach builds upon the model’s pre-existing knowledge, enhancing performance on specific tasks with reduced data and computational requirements. Fine-tuning transfers the pre-trained model’s learned patterns and features to new tasks, improving performance and reducing training data needs. It has become popular in NLP for tasks like text classification, sentiment analysis, and question-answering.

Types of LLM Fine-Tuning
- Unsupervised Fine-Tuning
This method does not require labelled data. Instead, the LLM is exposed to a large corpus of unlabelled text from the target domain, refining its understanding of language. This approach is useful for new domains like legal or medical fields but is less precise for specific tasks such as classification or summarisation
- Supervised Fine-Tuning (SFT)
SFT involves providing the LLM with labelled data tailored to the target task. For example, fine-tuning an LLM for text classification in a business context uses a dataset of text snippets with class labels. While effective, this method requires substantial labelled data, which can be costly and time-consuming to obtain.
Pre-training vs Fine-tuning

Importance of Fine-Tuning LLMs
- Transfer Learning: Fine-tuning leverages the knowledge acquired during pre-training, adapting it to specific tasks with reduced computation time and resources.
- Reduced Data Requirements: Fine-tuning requires less labelled data, focusing on tailoring pre-trained features to the target task.
- Improved Generalisation: Fine-tuning enhances the model’s ability to generalise to specific tasks or domains, capturing general language features and customising them.
- Efficient Model Deployment: Fine-tuned models are more efficient for real-world applications, being computationally efficient and well-suited for specific tasks.
- Adaptability to Various Tasks: Fine-tuned LLMs can adapt to a broad range of tasks, performing well across various applications without task-specific architectures.
- Domain-Specific Performance: Fine-tuning allows models to excel in domain-specific tasks by adjusting to the nuances and vocabulary of the target domain.
- Faster Convergence: Fine-tuning usually achieves faster convergence, starting with weights that already capture general language features.