Supervised vs Unsupervised vs Reinforcement Learning
Tell apart the three ways a machine can learn: from answers, from raw data with no answers, and from rewards.
Every learner needs feedback. A toddler, a puppy and a spam filter all get better the same way: something tells them how they’re doing. The three big flavours of machine learning differ in one thing: how much the teacher gives away.
Supervised
“Here are the answers.”Thousands of examples, each with its right answer attached: this photo is a cat, this email is spam. The model learns to produce the answer itself.
Spam filters, face unlock, house prices.
Unsupervised
“No answers. Find the structure.”A heap of unlabelled data. The model groups what looks alike. It can tell you these 300 customers shop the same way. It can’t tell you what to call them.
Customer groups, spotting odd bank payments.
Reinforcement
“Go on, try. I’ll score you.”No right answers at all, only a reward or a penalty after acting. Like training a dog with treats, minus the slobber. The hard part: working out which move earned the treat.
Game-playing AIs, robots learning to walk.
Real systems mix and match. ChatGPT first learned from mountains of text that supplied its own answers (the next lesson shows the trick), then was polished with rewards based on human ratings.
Key takeaways
- supervised learning: learn from examples that come with the right answers attached.
- unsupervised learning: no answers. The model finds groups and structure by itself, but it can’t name what it found.
- reinforcement learning: no answers either. The model acts, collects rewards or penalties, and works out which actions earned them.
- Big real systems combine them. ChatGPT went through several kinds of training, one after another.
Check your understanding
Go deeper (more technical)
The grouping method in the simulation is k-means: pick k centres, give each point to its nearest centre, move each centre to the middle of its group, repeat until nothing moves. It always finds groups, even in data that has none, so a human still has to judge whether they mean anything.
The mouse uses Q-learning (Watkins, 1989). It keeps a score for every move in every square, and after each move nudges that score towards "the reward I just got, plus the best score where I landed". That way the cheese’s value seeps backwards, square by square, to the start. The same idea, scaled up with a neural network, taught DeepMind’s agents to play Atari games from raw pixels (2013–2015).
The classic list has a fourth member: self-supervised learning, where the answers are cut out of the data itself. It powers every modern language model, and it stars in the next lesson.