Sep 2026· Large Language Models and Prompt Engineering· pp. 177-196
Abstract
This chapter explains why fine-tuning is essential for adapting large language models (LLMs) to specialized and high-stakes domains, where general-purpose prompting may be unreliable. This chapter introduces fine-tuning as the process of updating a pretrained model with task-specific data and reviews evidence from healthcare, cybersecurity, ontology engineering, and transportation showing that fine-tuned models achieve higher accuracy, domain compliance, and practical usefulness. This chapter emphasizes that specialization must be paired with rigorous evaluation, highlighting current gaps in reporting on safety, fairness, and bias, and motivating the development of multidimensional assessment frameworks. It then presents a step-by-step data preparation pipeline for collection, cleaning, formatting, splitting, and privacy/bias checks, illustrated using a small synthetic university frequently asked question (FAQ) dataset. Next, it compares major fine-tuning strategies, including full-model fine-tuning, parameter-efficient methods such as low-rank adaptation (LoRA), and instruction tuning. A hands-on walkthrough demonstrates fine-tuning DistilGPT2 with LoRA and interpreting trainable-parameter efficiency. Finally, this chapter introduces intrinsic metrics (BLEU, ROUGE, METEOR, perplexity) and extrinsic metrics (accuracy, precision, recall, F 1) to assess robustness and real-world readiness.
Supporting data, adapters, predictions and code for the article *Low-Cost LoRA Fine-Tuning of Small Language Models for Multi-Step Arithmetic Reasoning* by Jake O'Grady, Asena Isik Gürhan, Chee Fong Ting and Effirul Ramlan (University of Galway). We generated 20,000 GSM8K-derived arithmetic problems with step-by-step s...
O'Grady, Jake, Gürhan, Asena Isik, Chee, Fong Ting et al.· Zenodo (CERN European Organi...· 465 citations
The results are packaged in the Greenfield Startup Model (GSM), which explains the priority of startups to release the product as quickly as possible, and the need to shorten time-to-market, by speeding up the development through low-precision engineering activities.
Carmine Giardino, Nicolò Paternoster, M. Unterkalmsteiner et al.· IEEE Transactions on Softwar...· 178 citations· ⚡14
Software startup companies develop innovative, software-intensive products within limited timeframes and with few resources, searching for sustainable and scalable business models.
M. Unterkalmsteiner, P. Abrahamsson, Xiaofeng Wang et al.· e-Informatica Software Engin...· 157 citations· ⚡17
This study conducts a case survey study based on the secondary data of the major pivots happened in 49 software startups, and demonstrates that customer need pivot is the most common among all pivot types.
Sohaib Shahid Bajwa, Xiaofeng Wang, Anh Nguyen-Duc et al.· Empirical Software Engineeri...· 127 citations· ⚡15
The comparison of adopter and non-adopter sample reveals three potential adoption inhibitor, security, data privacy, and portability, which underlines the importance of the technical and security perspectives for research investigating the adoption of technology.
Nattakarn Phaphoom, Xiaofeng Wang, S. Samuel et al.· Journal of Systems and Softw...· 111 citations· ⚡8
Objective There is dearth of information on the timeliness of antenatal care (ANC) uptake. This study aimed to determine the timely ANC uptake by a medically trained provider (MTP) as per the World Health Organization (WHO) recommendations and the country guideline. Methods Cross-sectional survey was done with 2,731 wo...
B. Sarker, Musfikur Rahman, T. Rahman et al.· PLoS ONE· 89 citations· ⚡7