A student who memorized the answers to past exams and got a perfect score, yet could not solve the slightly reworded questions on the real test—you have probably heard a story like this. The very same kind of failure happens to AI. It is called overfitting.
Overfitting is one of the most important pitfalls you cannot avoid when discussing machine learning. You train an AI model on your company’s data, get high accuracy, and then find it useless on real production data—overfitting is usually lurking behind this. And one of the reasons you cannot take a new AI model’s “high benchmark score” at face value is, in fact, deeply tied to overfitting.
This article explores what overfitting is from four angles—definition, causes, detection, and countermeasures—using almost no mathematics. It also touches on “double descent,” a paradoxical phenomenon observed in recent large models that overturns textbook common sense. As literacy for reading AI performance numbers correctly, this is a topic well worth knowing.
What Overfitting Is: “Memorizing,” Not “Learning”
The English Wikipedia defines overfitting as “the production of an analysis that corresponds too closely or exactly to a particular set of data, and may therefore fail to fit to additional data or predict future observations reliably”1.
Put plainly, overfitting is the phenomenon where a model fits the training data too closely and becomes unable to handle new data. Wikipedia explains that overfitting occurs “when a model begins to ‘memorize’ training data rather than ‘learning’ to generalize from a trend”1. The exam analogy above is exactly this: rather than learning the essence (the trend) of how to solve problems, the student memorized the answers themselves (the training data).
The key counterpart term here is generalization. Generalization is the ability to function correctly even on unseen data that was not used in training, and this is what machine learning is truly aiming for. Wikipedia notes that a fitted model typically performs worse on new data than on the original training data—a phenomenon called “shrinkage”1. High accuracy at training time does not necessarily guarantee performance in production.
Contrast with Underfitting: Aiming Between Two Extremes
On the opposite side of overfitting is underfitting. Wikipedia defines underfitting as occurring “when a mathematical model cannot adequately capture the underlying structure of the data”1. This corresponds to a student who has not studied enough to even grasp the patterns in past exams.
In machine learning, you need to aim for the “just right” point between these two extremes. A model that is too simple cannot capture the essence of the data (underfitting); a model that is too complex memorizes even the noise (overfitting).
| State | Score on training data | Score on new data | Analogy |
|---|---|---|---|
| Underfitting | Low | Low | Hasn’t studied, can’t grasp patterns |
| Just right (generalization) | High | High | Understands how to solve |
| Overfitting | Very high | Low | Just memorized the answers |
What stands out is that an overfitted model looks excellent only on the training data. That is exactly what makes it dangerous: if you look only at training-time numbers, you mistakenly conclude “we built an excellent model.” Its true ability can only be measured on data not used in training.
Why Overfitting Happens
The main causes of overfitting can be organized into two broad categories.
One is that the model is too complex. If the model’s expressive power (such as its parameter count) is excessive relative to the amount and complexity of the data, the model has spare capacity to dutifully memorize not just the essential trends in the data but also noise and exceptions that happened to slip in. When the “capacity” to memorize is too large, the model is prone to resorting to rote memorization.
The other is that the data is scarce or biased. If there is little training data, the model gets excessively dragged around by the details of a few examples. Wikipedia, too, points out that more training data helps the model fit “the underlying patterns rather than the noise”1. Just as you end up memorizing the answers if you solve a small set of past exams over and over, the less diverse the data, the more prone overfitting becomes.
How to Detect It: The Train/Validation/Test Split
Overfitting is invisible on the training data. So how do you detect it? The basic practice is to divide your data into three parts with different roles.
- Training set: Used for the actual learning of the model.
- Validation set: Used to check performance partway through learning and to tune settings. Not used directly for learning.
- Test set: Used once at the very end to measure true ability under a simulated production scenario.
The key is not to use the validation and test sets for learning. Performance on data not used in learning is the yardstick for generalization to unseen data. If the score on the training data keeps rising but the score on the validation data starts to worsen partway through, that is a sign overfitting has begun.
error
│\
│ \____ validation error (rises partway = overfitting begins)
│ \ /
│ \/………………………… ← ideal to stop training here
│ /\
│ / \______ training error (keeps falling)
│ /
└──────────────────────► training progress
One reason you cannot take a new model’s “high benchmark score” at face value lies here, too. If the test questions used for evaluation have leaked into the training data (data contamination), it is the same as taking an exam whose answers you already know, which overestimates the model’s true generalization ability. We cover this point in our article on how to read AI benchmarks as well.
The Bias-Variance Tradeoff
A framework that organizes the relationship between overfitting and underfitting one level deeper is the bias-variance tradeoff. Wikipedia states that “the bias–variance tradeoff is often used to overcome overfit models”1.
- Bias: Off-target error caused by the model’s assumptions being too simple. High bias leads to underfitting.
- Variance: Scatter caused by reacting too sensitively to small differences in the training data. High variance leads to overfitting.
In Wikipedia’s framing, underfitting produces “high bias and low variance,” while overfitting produces “low bias and high variance”1.
| Bias | Variance | State | |
|---|---|---|---|
| Too-simple model | High | Low | Underfitting |
| Too-complex model | Low | High | Overfitting |
Using a target-shooting analogy, bias is “the aim being off the center of the target,” and variance is “the arrows scattering even when the aim is right.” You cannot drive both to zero at once, and lowering one tends to raise the other—hence the word “tradeoff.” A good model is one in which these two errors are balanced.
Countermeasures Against Overfitting
Many methods have been developed to prevent overfitting. Wikipedia lists representative ones: “model comparison, cross-validation, regularization, early stopping, pruning, Bayesian priors, or dropout”1. Let us organize the key ones.
Add more data. The most straightforward countermeasure. The more data, and the more diverse it is, the more the model is forced to learn essential patterns rather than memorize details.
Regularization. A general term for methods that impose a “penalty” on model complexity, steering it away from solutions more complex than necessary. By keeping weights from becoming extremely large, it prevents excessive fitting to particular data.
Early stopping. As in the figure above, training is cut off at the point where validation performance begins to worsen. A simple and effective method: stop studying before resorting to rote memorization.
Dropout. A representative method for neural networks. Its origin is the 2014 paper “Dropout: A Simple Way to Prevent Neural Networks from Overfitting” by Nitish Srivastava, Geoffrey Hinton, and three co-authors2. The paper’s abstract states: “Dropout is a technique for addressing this problem. The key idea is to randomly drop units (along with their connections) from the neural network during training. This prevents units from co-adapting too much”2.
What makes dropout interesting is that, by randomly putting some neurons “to rest” each time, it raises a network that does not depend too heavily on any particular combination of neurons. The paper reports that this method “significantly reduces overfitting and gives major improvements over other regularization methods”2. It is close to the image of a team where everyone develops broad capability so the work gets done even if someone is randomly missing.
| Countermeasure | What it does | Intuitive analogy |
|---|---|---|
| Add more data | Increase the amount and diversity of training data | Practice with many problems |
| Regularization | Impose a penalty on complexity | Dock points for needlessly elaborate answers |
| Early stopping | Stop training when validation score worsens | Wrap up before rote memorization |
| Dropout | Randomly rest some neurons | Build a team that runs even when someone is out |
A Modern Paradox: Double Descent
So far we have looked at the classical common sense that “making a model too complex causes overfitting.” Yet in recent large models, a strange phenomenon that overturns this common sense has been observed: double descent.
What spread this phenomenon to the modern machine learning community was the 2019 paper “Reconciling modern machine learning practice and the bias-variance trade-off” by Mikhail Belkin and colleagues3. The paper showed that increasing model capacity beyond the “interpolation point”—that is, the point where the model perfectly fits the training data—causes performance to improve again3.
In classical common sense, as you make a model more complex, performance should first improve and then worsen due to overfitting (drawing a U shape). Yet when you make the model so huge that it can perfectly memorize the training data and then make it even larger, performance starts to improve once more. This two-stage behavior—error “falling, rising, then falling again”—is the origin of the name double descent. Belkin et al.’s framework encompasses the conventional U-shaped bias-variance relationship while serving as a clue to why modern overparameterized models (such as huge neural networks) generalize well even when they perfectly fit the training data3.
This is not unrelated to today’s LLM tendency that “the more parameters, the smarter.” That said, double descent is a phenomenon still under research and interpretation, and it is important to note this is not a simple story of “make it bigger and it always generalizes.”
What It Means for Business
Overfitting carries practical meaning when adopting AI in business. You must not blindly trust the “high training-time accuracy” of a model fine-tuned on your own data. A model’s quality must always be evaluated on data not used in learning. And the benchmark scores a vendor presents can be overestimated depending on how the evaluation data is handled—all of these can only be judged correctly if you understand the concept of overfitting.
“Good score on training data” does not equal “good performance in practice.” This seemingly obvious yet easily overlooked fact is the heart of the topic of overfitting. If you want to further sharpen your ability to read AI numbers, reading our articles on how to read AI benchmarks, which organizes what scores mean, or on parameter count, which expresses model size, will bring AI performance evaluation into more three-dimensional view.
Sources
- Overfitting - Wikipedia (overfitting, underfitting, bias-variance, countermeasures)
- Dropout: A Simple Way to Prevent Neural Networks from Overfitting - Srivastava, Hinton et al., JMLR 15:1929-1958 (2014). The origin of dropout
- Reconciling modern machine learning practice and the bias-variance trade-off - Belkin et al., 2019. The origin of double descent