Skip to content
anythingai.space
AI Foundationsbeginner14 min · 10 steps

Supervised Learning: Regression & Classification

Learn a mapping from inputs to known answers — numbers (regression) or categories (classification) — and check it on data the model has never seen.

trainpredictTRAINING ROWS (X → Y)“WIN $$$ now” → spam“Lunch at 1?” → ham120 m² → $310k75 m² → $205kLabeled examplesfeatures + answerModelf(x; w)Predictionon unseen x
dataresponse
1 / 10
ProblemStep 1 of 10

Learning from examples that come with answers

In supervised learning every training example is a pair: the input features (an email's words, a house's size) and the label — the correct answer someone already knows (spam / not spam, the sale price).

Training searches for a function f(x) whose outputs match those labels. The payoff is the last box: predicting answers for new inputs whose labels nobody has yet.

InsightLabels are the expensive part. Most supervised projects are limited by how many trustworthy labeled examples they can collect.

Lesson 15 of 34 in AI Foundations