Data Difficulty and the Generalization--Extrapolation Tradeoff in LLM Fine-Tuning

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Liu, Siyuan, Chen, Tinghong, Li, Xinghan, Wang, Yifei, Zhang, Jingzhao
Format: Preprint
Veröffentlicht: 2026
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866914598728237056
author Liu, Siyuan
Chen, Tinghong
Li, Xinghan
Wang, Yifei
Zhang, Jingzhao
author_facet Liu, Siyuan
Chen, Tinghong
Li, Xinghan
Wang, Yifei
Zhang, Jingzhao
contents Data selection during supervised fine-tuning (SFT) can critically change the behavior of large language models (LLMs). Although existing work has studied the effect of selecting data based on heuristics such as perplexity, difficulty, or length, the reported findings are often inconsistent or context-dependent. In this work, we systematically study the role of data difficulty in fine-tuning from both empirical and theoretical perspectives, and find that there is no universally optimal difficulty level; rather, its effectiveness depends on the dataset size. We show that for a fixed data budget, there exists an optimal data difficulty for SFT, and that this optimal difficulty shifts toward harder data as the data budget increases. To explain this phenomenon, we conduct controlled synthetic experiments that reveal a simple underlying mechanism: the interplay between the (in-distribution) generalization gap and the extrapolation gap. We further support this mechanism through a theoretical analysis using PAC-Bayesian generalization bounds. Overall, our results clarify how data size and difficulty jointly affect the trade-off between generalization and extrapolation in SFT, providing guidance for difficulty-based data selection under certain model and data conditions.
format Preprint
id arxiv_https___arxiv_org_abs_2605_12906
institution arXiv
publishDate 2026
record_format arxiv
spellingShingle Data Difficulty and the Generalization--Extrapolation Tradeoff in LLM Fine-Tuning
Liu, Siyuan
Chen, Tinghong
Li, Xinghan
Wang, Yifei
Zhang, Jingzhao
Machine Learning
Artificial Intelligence
Data selection during supervised fine-tuning (SFT) can critically change the behavior of large language models (LLMs). Although existing work has studied the effect of selecting data based on heuristics such as perplexity, difficulty, or length, the reported findings are often inconsistent or context-dependent. In this work, we systematically study the role of data difficulty in fine-tuning from both empirical and theoretical perspectives, and find that there is no universally optimal difficulty level; rather, its effectiveness depends on the dataset size. We show that for a fixed data budget, there exists an optimal data difficulty for SFT, and that this optimal difficulty shifts toward harder data as the data budget increases. To explain this phenomenon, we conduct controlled synthetic experiments that reveal a simple underlying mechanism: the interplay between the (in-distribution) generalization gap and the extrapolation gap. We further support this mechanism through a theoretical analysis using PAC-Bayesian generalization bounds. Overall, our results clarify how data size and difficulty jointly affect the trade-off between generalization and extrapolation in SFT, providing guidance for difficulty-based data selection under certain model and data conditions.
title Data Difficulty and the Generalization--Extrapolation Tradeoff in LLM Fine-Tuning
topic Machine Learning
Artificial Intelligence
url https://arxiv.org/abs/2605.12906