Every model score in machine learning answers one question: how well will this system do on data it has not seen? Cross-validation is the protocol for answering that question. It was formalized in the mid-1970s, when a refit meant minutes on a mainframe, and it remains the default evaluation procedure in applied machine learning. It is also more fragile than its ubiquity suggests, and large language models have broken its central assumption outright.
The cheating problem
A trained model's accuracy on its own training data means very little. A model with enough capacity can memorize any finite dataset and score perfectly while learning nothing useful. So evaluation has to happen on examples the fitting procedure did not consume.
The simplest design is a single holdout split: carve off, say, 20 percent of the labeled data, train on the rest, score once. The design has two known weaknesses. A 20 percent holdout is 20 percent of the training signal the model never gets, which matters when data is scarce. And one split is one draw: two researchers holding out different random 20 percent of the same dataset can get meaningfully different scores, especially on small datasets.
Cross-validation keeps the honesty and fixes the waste. Its core idea is rotation: everyone gets tested, everyone gets used for training, and no example is scored while the model is looking at its answer.
Two papers from the 1970s
The method is usually dated to a 1974 paper by Michael Stone in the Journal of the Royal Statistical Society, Series B, which applied a generalized "cross-validatory" criterion to the choice between prediction procedures, using examples from univariate estimation and linear regression. Seymour Geisser followed in 1975 in the Journal of the American Statistical Association with "predictive sample reuse," a broader framework that covered many splitting schemes under one roof and cemented the vocabulary. A 2010 survey by Arlot and Celisse, still the standard reference, catalogs the variants and, pointedly, separates what has been proven about them from what has merely been observed.
The reason the method spread, per that survey, is its combination of simplicity and apparent universality. You do not need to know anything about the model class. You just need data and a way to refit.
How k-fold works
Cut the dataset into k roughly equal folds, typically 5 or 10. Then run k rounds. In round one, train on folds 2 through k and test on fold 1. In round two, train on folds 1 and 3 through k and test on fold 2. Continue until every fold has spent exactly one round as the test set. The cross-validation score is the average of the k test scores, and the per-fold spread is a rough read on stability. Class-balance is preserved by stratifying folds so each carries a proportional slice of each label.

The extreme case, k = n, trains a separate model on all-but-one example per round. Leave-one-out uses nearly all data for every fit and was historically popular because for linear regression it reduces to an algebraic shortcut. It is also the variant with the shakiest theoretical footing: Kearns and Ron showed in 1999 that leave-one-out estimates can diverge badly from true error unless the learning algorithm is stable, meaning insensitive to any single training point, and they construct toy algorithms whose leave-one-out estimate is exactly as uninformative as a one-example holdout. The middle ground won by default. In an analysis from COLT 1999, Blum, Kalai and Langford proved that for a wide class of algorithms the k-fold estimate is a more accurate error estimate than testing on a single holdout of the same size, on variance and all higher moments. Refitting k models is the price, and for modern training runs that price can be absurd: cross-validating a frontier fine-tune five times costs five fine-tunes.
What the number does not mean
Cross-validation is sold as a prediction of future performance. Four caveats complicate that sale.
The average hides its own noise. If you want error bars on the cross-validation estimate itself, there is a clean negative result: Grandvalet and Sempe proved in the Journal of Machine Learning Research, 2004, that no unbiased estimator of the variance of k-fold cross-validation exists under permutation-invariance. Papers reporting a single CV mean with no fold-level spread are, in effect, reporting a measurement without saying how rough the instrument is.
CV estimates a slightly different quantity than advertised. Bates, Hastie and Tibshirani (JASA, 2024) proved that for ordinary least squares, cross-validation does not estimate the prediction error of the model you actually have. It estimates the average error of models like it, fit to other unseen training sets from the same population. They show the same slippage affects data splitting, bootstrapping and Mallows' Cp, and that standard CV confidence intervals can badly under-cover because every fold shares training data with every other.
Random folds leak on structured data. If observations are correlated, a random split does not create an unseen test set: a fold can contain the neighbor, the same patient's second visit, or the next frame of the same video. Roberts et al. (Ecography, 2017) surveyed temporal, spatial, hierarchical and phylogenetic structure in ecological data and found random-split cross-validation routinely overstates predictive skill; the fix is blocked folds that respect the structure, which is why spatio-temporal model papers now report both numbers.
Selection eats the margin. If you try 100 hyperparameter settings and report the CV score of the winner, you have selected on noise, and the winner's true performance is lower. The standard remedy is nested cross-validation, where tuning happens inside the training folds only. The scikit-learn model selection guide treats this as a requirement rather than a refinement, and its tooling makes it the default path: GridSearchCV runs 5-fold CV internally unless told otherwise.
The premise LLMs broke
All of the above assumes one thing: the test examples were never seen during training. Pre-training at web scale quietly violates that assumption for every public benchmark.

The cleanest evidence comes from a longitudinal study of benchmark releases, which treats model training cutoffs as a natural experiment: for code benchmarks like Codeforces and Project Euler, model pass rates correlate statistically significantly with a problem's GitHub popularity and its release date relative to the cutoff. Popular, old problems are easier not because models are smarter but because solutions are more likely to be in the crawl. This is the holdout premise failing at corpus scale.
The Leaderboard Illusion study (2025) documented the selection problem at industry scale on Chatbot Arena: providers testing many private variants before release and keeping the best scores (27 Meta variants ahead of Llama 4), and data-access asymmetries (Google and OpenAI estimated to have received 19.2 and 20.4 percent of arena data, with extra access worth up to 112 percent relative gains on the arena distribution). Models overfit to one visible exam, which is the exact failure mode rotation was invented to prevent. The field's countermeasures restore rotation in a different form: LiveBench refreshes questions monthly from fresh sources with objectively checkable answers, and MMLU-Pro rebuilt MMLU with harder, noise-filtered, ten-option questions after the original plateaued. For fine-tuning work on private data, classic cross-validation still applies unchanged, and it still catches overfitting before it ships.
Working rules
- Keep one final holdout, touched exactly once, after all decisions are made.
- Put preprocessing and tuning inside the folds. Anything fitted on the full dataset leaks into every "held-out" score.
- Choose folds to match deployment. If the test is tomorrow's traffic or an unseen region, random folds flatter you.
- Report the fold spread alongside the mean. A 5-fold CV score without its variance is an uncalibrated instrument reading.
- Assume any public benchmark predating your model's training cutoff is contaminated, and weight private or rolling evaluations accordingly.
Cross-validation survives because it answers the only question that matters honestly: did the model learn the material, or did it memorize the answer key? The mechanics date to 1974. The cheating did not.
Sources
- M. Stone, "Cross-Validatory Choice and Assessment of Statistical Predictions", JRSS-B, 1974 - https://rss.onlinelibrary.wiley.com/doi/10.1111/j.2517-6161.1974.tb00994.x
- S. Geisser, "The Predictive Sample Reuse Method with Applications", JASA, 1975 - https://www.jstor.org/stable/2285815
- S. Arlot, A. Celisse, "A survey of cross-validation procedures for model selection", Statistics Surveys, 2010 - https://projecteuclid.org/journals/statistics-surveys/volume-4/issue-none/A-survey-of-cross-validation-procedures-for-model-selection/10.1214/09-SS054.full
- M. Kearns, D. Ron, "Algorithmic Stability and Sanity-Check Bounds for Leave-One-Out Cross-Validation", Neural Computation, 1999 - https://direct.mit.edu/neco/article/11/6/1427/6294/Algorithmic-Stability-and-Sanity-Check-Bounds-for
- A. Blum, A. Kalai, J. Langford, "Beating the Hold-Out: Bounds for K-fold and Progressive Cross-Validation", COLT 1999 - https://www.microsoft.com/en-us/research/wp-content/uploads/2016/11/pre2003-Beating_the_Holdout.pdf
- F. Grandvalet, Y. Sempe, "No Unbiased Estimator of the Variance of K-Fold Cross-Validation", JMLR, 2004 - https://www.jmlr.org/papers/volume5/grandvalet04a/grandvalet04a.pdf
- S. Bates, T. Hastie, R. Tibshirani, "Cross-validation: what does it estimate and how well does it do it?", JASA, 2024 - https://arxiv.org/abs/2104.00673
- D. Roberts et al., "Cross-validation strategies for data with temporal, spatial, hierarchical, or phylogenetic structure", Ecography, 2017 - https://digital.csic.es/bitstream/10261/378729/3/cross_validation_Roberts.pdf
- "Data Contamination Through the Lens of Time", arXiv 2310.10628 - https://arxiv.org/abs/2310.10628
- S. Singh et al., "The Leaderboard Illusion", arXiv 2504.20879 - https://arxiv.org/abs/2504.20879
- J. White et al., "LiveBench: A Challenging, Contamination-Limited LLM Benchmark", arXiv 2406.19314 - https://arxiv.org/abs/2406.19314
- Y. Wang et al., "MMLU-Pro", arXiv 2406.01574 - https://arxiv.org/abs/2406.01574
- scikit-learn, "3.1. Cross-validation: evaluating estimator performance" - https://scikit-learn.org/stable/modules/cross_validation.html
