The basics

Machine learning (ML)

Machine learning is a way of building software where the computer learns patterns from examples, instead of a programmer writing every rule by hand.

Imagine teaching a friend to spot spam email. You could write a list of rules, but spammers keep changing their tricks. Instead you show your friend thousands of messages marked spam or not spam, and they learn what spam tends to look like. Machine learning does exactly this, but with a computer program that learns from data.

The program starts out guessing badly. Each time it is wrong, it adjusts its internal settings a tiny bit so the next guess is better. Do this millions of times and the guesses become very good. The finished result is called a model. The examples it learned from are called training data.

Machine learning is not the same as a database. A database stores facts and returns them exactly. A learned model finds general patterns and applies them to things it has never seen, which is why it can be wrong in surprising ways.

Example

Your email app's spam filter keeps improving because it learns from every message that you and millions of other people mark as junk.

Read: How machines learn →