AI GLOSSARY · AI CONCEPTS

Bias-variance tradeoff

Markdown version · Wikidata Q17003119

Definition

The bias-variance tradeoff is the balance between two sources of model error: bias, predictions off on average, and variance, predictions that shift with the training data. Lowering one can raise the other.

Also called: bias variance, bias and variance, bias-variance, bias variance trade-off, bias-variance dilemma.

In plain language

Imagine fitting a line through scattered points. A very simple model, such as a straight line, may miss the real pattern however much data you give it. That is bias. A very flexible model can follow every wiggle in the points you showed it, including random noise, and then give different answers if you show it different points. That is variance. The tradeoff is that making a model more flexible tends to cut the first problem and worsen the second. Held-out results help assess generalization, but a single train-test comparison does not directly measure the full bias-variance decomposition. The idea describes error in the model; it does not fix poor data or wrong labels.

Technical definition

In a squared-error regression decomposition at a fixed input, expected prediction error can be separated into squared bias, variance across sampled training sets and irreducible outcome noise, under the stated data-generating assumptions. This identity does not apply unchanged to every loss or evaluation setting. Bias and variance need not move in opposite directions in every model comparison.

Worked examples in this catalogue

Catalogue examples point at a skill, guide or coding tool listed on this site, with what to run and what you see. An example marked illustrative describes the item from its own documentation; it was not executed for this page. Platform Scores are our assessment under a published method, not a safety guarantee.

  1. Skill by Skill Almanac · Illustrative, not executed

    split-leakage-check 53/100 · Provisional, not yet measuredScored · Method v0.2 · How we score

    What you see
    The skill checks train, validation and test files for duplicates, shared groups, time and label leakage and prints JSON.
    Why it exercises the concept
    Clean evaluation splits support a generalization estimate. Separating bias and variance needs additional assumptions or repeated training samples; this linked check does not estimate those components.
  2. Skill by Skill Almanac · Illustrative, not executed

    data-analysis-eda 56/100 · Provisional, not yet measuredScored · Method v0.2 · How we score

    What you see
    The skill gives a fixed exploratory-analysis procedure and a CSV profiler that keeps findings descriptive, evidenced and caveated.
    Why it exercises the concept
    Looking at the data before modelling is one way to judge how much structure and noise it has. The skill does not fit models or measure bias and variance.

How it shows up when you use agents

You will not set bias or variance directly when you use Claude Code, Codex or Cursor. The idea appears when an agent helps with data work: fitting a model, choosing between a simple and a flexible one, or reading results. The agent may describe a model as underfitting or overfitting, which are the practical signs of high bias and high variance in IBM's description.

Held-out data helps assess generalization; estimating bias and variance separately requires additional assumptions or repeated training samples. The scikit-learn underfitting example evaluates fit with cross-validation, calculating error on a validation set. As a rule of thumb, not from the scikit-learn example: if a model does poorly on both training and validation data, bias is a likely suspect. If it does well on training data and poorly on new data, variance is. An agent that reports only training error cannot tell you which.

What breaks when this is misunderstood: people keep adding model complexity because training error keeps falling, or keep simplifying a model that already misses the pattern. Next action: ask for the error on a held-out split alongside the training error, and ask what changed between runs. For the data hygiene side, see the contrast skills on this page. See also Machine learning and Regularization.

Worked example (illustrative)

At one toy input, let the true conditional mean be 3 and equally likely trained-model predictions be 2 or 4. Their mean is 3, so bias is zero and prediction variance is 1. Add independent equally likely outcome noise of −0.5 or 0.5, whose variance is 0.25. Averaging squared errors across the four combinations gives 1.25=0²+1+0.25. This is a constructed decomposition, not a measured model study.

Common confusions

  • Bias in this sense versus bias in ethics. Here bias is the difference between expected predictions across training samples and the target regression function. It is not the same as unfair treatment of groups. See AI bias for that meaning.
  • Bias versus the bias term. A model's bias term, or intercept, is a parameter. The bias in this tradeoff is a property of the model's errors.
  • Variance versus noise. The scikit-learn example separates variance from noise, the irreducible part of error due to variability in the data. A better model cannot remove noise.
  • Myth. You must always give up one to gain the other. The scikit-learn bagging example reports a case where overall error fell because variance dropped by more than bias rose; the trade is not one-for-one, and reducing one component does not universally require increasing the other.

Terms that mention Bias-variance tradeoff

1 terms mention this one

More in AI concepts

Next steps

  1. split-leakage-check A skill that exercises it.
  2. Machine learning (ML) Related term.
  3. Machine learning model Related term.
  4. All glossary terms A to Z and by family.

Sources

Definitions are written by Skill Almanac from these sources and were checked against them on 2026-11-24. Wikipedia is never the only source.

Review record

Last verified

Drafted by Claude (original draft) and Codex (automated revisions); sources and example targets checked by Independent automated source review (OpenAI Codex); not human peer review on 2026-11-24. Last verified .

Change log (7)
  • : Independent automated factual/example review completed. Cached US query estimate aligned to receipt; no traffic promise. Final technical gate recorded separately; publication disabled.
  • : First version.
  • : Verifier pass: Qualified rule of thumb and sharpened myth rebuttal.
  • : Learning-method scope and counterexample corrections; independent exact-version review pending.
  • : Aligned related-tool explanations with scoped definitions; no blanket claims about the full catalog.
  • : Removed unrelated sample-size comparison card; retained the direct illustrative decomposition. Independent recheck pending.
  • : Automated review completed; approved for the staged public release. Search indexing is controlled by the release configuration.