How Does AI Learn?
A primary lesson on how AI learns: training data, examples, practice and feedback, getting better over time, and why bad data leads to bad results.
Key takeaways
- AI learns from training data: lots of labelled examples
- It practises, gets feedback on mistakes, and slowly improves
- Good, fair examples make good AI; bad or unfair examples make biased AI
- AI keeps following patterns and does not understand like a person
Learning by example
Think about how you learned to tell a cat from a dog. Nobody gave you a list of rules. You saw lots of cats and lots of dogs, and your brain learned the difference.
AI learns in a similar way. We show it lots of examples, and it finds the patterns.
If you are new to AI, start with Meet Artificial Intelligence.
Training data
The examples we give an AI are called training data.
To teach an AI to spot cats, we collect thousands of photos. We label each one: "cat" or "not a cat." 🐱
The AI studies all these labelled photos. It is training. The more good examples it sees, the better it gets.
Practice and feedback
AI does not learn perfectly the first time. It learns by practising.
Here is the loop:
- The AI guesses an answer for an example.
- We check: was it right or wrong?
- If it was wrong, the AI makes a small adjustment.
- It tries again, and again, thousands of times.
This is called getting feedback. Step by step, the AI's guesses get better. We call this machine learning, because the machine is learning from data.
Good data in, good AI out
Here is something important: AI only learns what we show it.
If we show it fair, correct examples, it learns well. If we show it wrong or unfair examples, it learns the wrong things. This problem is called bias.
For example, if an AI only ever saw photos of small dogs, it might not recognise a big dog. The data was missing something.
So people who build AI must choose their data carefully and fairly.
AI still does not "understand"
Even after all this learning, the AI does not understand a cat the way you do. It does not know a cat purrs or likes naps.
It only knows patterns in the data. That is why AI can still make silly mistakes, and why people should check its work.
Curious how the maths behind this works? When you are older, read What Is Machine Learning?.
Quick quiz
Test yourself and earn XP
What do we call the examples we show an AI so it can learn?
The collection of examples an AI learns from is called training data.
How does an AI get better over time?
AI practises on examples and adjusts each time it gets feedback about a mistake.
What happens if the training data is unfair or wrong?
AI learns from whatever data it gets, so bad or unfair data leads to bad or unfair results. This is called bias.
Does AI understand the examples the way you do?
AI finds patterns in the numbers. It does not really understand meaning like a person.
FAQ
It depends. Simple tasks may need a few thousand examples; big AI like chatbots learns from huge amounts of text and images.
Keep exploring
More in AI