Lesson 2.1 · 22 min · video lesson
Machine Learning from First Principles
How can a program get good at a task that nobody ever wrote the rules for, like spotting spam or pricing a house?
In short: Machine learning is a way of building software where, instead of writing rules by hand, we show the computer many examples and let an algorithm adjust a model's numbers until its predictions match the examples. Training is a loop: predict, measure the error with a loss, nudge the parameters to reduce it, repeat. The real test is how well the model does on new data it has never seen.
In this lesson
- Why we need machine learning
- The core idea: data in, rules out
- The main kinds of machine learning
- How a model learns, step by step
- Code: learning house prices from examples
- The real goal: generalising to new data
- A short history
- Where ML is used, and when not to use it
- Worked example, step by step
- Practice: try it yourself
Key terms in this lesson
- Machine learning
- Building programs that improve at a task by learning patterns from data rather than following hand-written rules.
- Feature
- An input variable that describes an example, such as a house's size.
- Label
- The correct answer for an example that a supervised model learns to predict.
- Parameters
- The adjustable numbers inside a model that training sets, such as weights and biases.
- Loss function
- A formula that turns the model's errors into a single number to minimise.
- Generalisation
- How well a trained model performs on new data it has not seen.
- Overfitting
- When a model learns the training data, including its noise, too closely and does worse on new data.
This lesson is free. Sign in or create a free account to open it with its video and quiz.
← 1.1 Six Concepts Every AI Engineer Must Know · 2.2 Labeled vs Unlabeled: Two Ways Machines Learn →