Analyzing the Effect of Noise in LLM Fine-tuning
Abstract
Fine-tuning is the dominant paradigm for adapting pretrained large language models (LLMs) to downstream NLP tasks. In practice, fine-tuning datasets may contain various forms of noise arising from annotation errors, preprocessing artifacts, or automated data collection. While prior work has focused on designing robust learning algorithms to mitigate performance degradation under noisy conditions, comparatively little is known about how different types of noise affect the internal learning dynamics of LLMs during fine-tuning. In this work, we systematically study the impact of noise on model behavior across three pretrained model families (GPT-2, Qwen2 and Llama-2) and three diverse NLP tasks. We introduce controlled perturbations corresponding to three common real-world noise types: label noise, grammatical noise, and typographical noise. Beyond task-level performance, we analyze layer-wise representation changes and attention patterns to understand how noise propagates through the network. Our results show that corrupting labels (i.e. label noise) consistently causes the largest performance degradation, whereas grammatical noise and typographical noise can occasionally yield mild regularization benefits. We further find that noise effects are localized primarily to task-specific layers, while attention structures remain comparatively stable.
Figures & tables
| Metric | Analysis Aspect |
| Attention value divergence | |
| Attention priority order | |
| Task-aligned information (classification) | |
| Task-aligned information (generation) | |
| Per-sample directional shift | |
| Inter-sample structural change |
| Baselines | Label Flip | Typo Error | Gramm. Error | |||||||||
| Task | Model | Pretrained | Clean FT | 20% | 30% | 40% | 20% | 30% | 40% | 20% | 30% | 40% |
| Sentiment | GPT-2 | 0.12 | 91.33 | 90.72 | 88.82 | 75.51 | 91.72 | 91.32 | 90.91 | 91.43 | 91.32 | 91.41 |
| Qwen2 | 70.00 | 94.41 | 90.71 | 81.62 | 57.72 | 94.21 | 94.02 | 94.21 | 94.22 | 94.51 | 94.33 | |
| Llama-2 | 1.13 | 94.12 | 91.62 | 95.12 | 85.13 | 94.00 | 94.42 | 94.11 | 94.42 | 94.21 | 93.81 | |
| QA | GPT-2 | 8.11 | 35.51 | 33.68 | 32.64 | 31.58 | 35.28 | 34.93 | 43.97 | 35.84 | 35.72 | 35.72 |
| Qwen2 | 41.02 | 68.00 | 60.91 | 51.9 | 49.72 | 70.01 | 69.63 | 69.62 | 70.71 | 70.51 | 70.63 | |
Appendix figures & tables14 assets
Supplementary material from the paper’s appendix.
Appendix
| Task | Source | Train | Val | Test |
| Sentiment | Yelp Polarity | 10 000 | 1 000 | 1 000 |
| QA | SQuAD v1.1 | 10 000 | 1 000 | 1 000 |
| MT | Tatoeba EN–FR | 20 000 | 1 000 | 1 000 |
| Task | Model | Template |
| Sentiment | All | Review: {text}\nSentiment: {label} |
| QA | GPT-2 | Context: {c}\nQuestion: {q}\nAnswer: {a} |
| LLaMA-2, Qwen-2 | ### Context:\n{c}\n\n### Question:\n{q}\n\n### Answer: {a} | |
| MT | GPT-2, LLaMA-2 | English: {eng}\nFrench: {fra} |
| Qwen-2 | Translate English to French.\n\n### English:\n{eng}\n\n### French: {fra} |
| Task | Original | After Label Flip |
| Sentiment | Text: “The food was terrible and the service was even worse.” Label: Negative | Text: “The food was terrible and the service was even worse.” Label: Positive |
| QA | Context: “The Eiffel Tower was built in 1889 for the World’s Fair. It is located in Paris, France.” Question: “When was the Eiffel Tower built?” Answer: “1889” | Context: (unchanged) Question: (unchanged) Answer: “the 10th century” |
| MT | English: “Swimming at night is dangerous.” French: “Il est dangereux de nager de nuit.” | English: (unchanged) French: “C’est la saison des fraises.” |
| Task | Original | After Typo Injection |
| Sentiment | “The food was terrible and the service was even worse.” | “The fodo was terrible and the service was even wrse .” |
| QA | Context: “The Eiffel Tower was built in 1889 for the World’s Fair.” | Context: “The Eiffel Towr was built in 1889 for the World’s Fair.” |
| MT | English: “Swimming at night is dangerous.” | English: “ Swimmiing at night is dangerous.” |
| Task | Original | After Grammatical Errors |
| Sentiment | “The food was terrible and the service was even worse.” | “The food were terrible and the service were even worse.” |
| QA | Context: “The Eiffel Tower was built in 1889. It is located in Paris.” | Context: “The Eiffel Tower were built in 1889. It are located in Paris.” |
| MT | English: “Swimming at night is dangerous.” | English: “Swimming at night are dangerous.” |
| Model | Task | Dropout | Target Modules | ||
| Qwen-2 | Sentiment | 8 | 32 | 0.10 | All 7 |
| QA | 16 | 32 | 0.05 | All 7 | |
| MT | 32 | 64 | 0.05 | All 7 | |
| LLaMA-2 | Sentiment | 32 | 64 | 0.05 | All 7 |
| QA | 16 | 32 | 0.05 | All 7 | |
| MT | 128 | 256 | 0.05 | All 7 |
| Model | Task | LR | Eff. Batch | Epochs | Warmup | Max Len |
| GPT-2 | Sentiment | 5e-5 | 32 | 3 | 0.03 | 256 |
| QA | 2e-5 | 32 | 3 | 0.03 | 1024 | |
| MT | 5e-5 | 32 | 30 | 0.03 | 256 | |
| Qwen-2 | Sentiment | 5e-5 | 80 | 3 | 0.03 | 256 |
| QA | 2e-5 | 32 | 2 | 0.03 | 1024 | |
| MT | 2e-4 | 32 | 3 | 0.03 | 256 |
| Seed | Clean | Label-flip 40% |
| 1 | 94.5% | 95.7% (+1.2%) |
| 22 | 94.5% | 83.5% ( 11.0%) |
| 7 | 94.0% | 27.2% (collapse) |
| 42 | (default; main experiments) | |
LLM Fine-Tuning
LLM fine-tuning adapts pretrained large language models to tasks, domains, languages, and behaviors through additional training.
See all 754 papers