What is AI?
AI, machine learning and deep learning explained: how they nest, what a model is, how training differs from inference, and the 75-year history that got us to ChatGPT.
You already use AI dozens of times a day: the spam filter in your inbox, the route your maps app picks, the face unlock on your phone, product recommendations, machine translation, and chat assistants such as ChatGPT or Claude. This lesson gives you a precise vocabulary for all of it — what artificial intelligence actually means, how machine learning and deep learning fit inside it, and what people mean when they say they ‘trained a Model’.
Three nested ideas
Artificial intelligence (AI) is the broad field of building computer systems that perform tasks we would call intelligent if a human did them: perceiving, reasoning, planning, understanding language, learning and acting. The standard textbook by Russell & Norvig frames AI as the study of agents that perceive their environment and act to achieve the best expected outcome[1]. AI includes approaches that do not learn at all, such as hand-written rule systems and search algorithms (a chess engine exploring moves).
Machine learning (ML) is the subset of AI where the system improves at a task by learning patterns from data instead of following rules a programmer wrote. Deep learning (DL) is the subset of ML that uses neural networks with many layers; it powers today's image recognition, speech recognition, large language models (LLMs) and image generators[3].
| Approach | Who writes the rules? | Data needed | Example |
|---|---|---|---|
| Rule-based AI (symbolic) | Human experts, as if-then rules | Little or none | Tax calculator, 1980s medical expert systems |
| Classical machine learning | Learned from data, using features designed by humans | Hundreds to millions of rows | Credit scoring with gradient-boosted trees |
| Deep learning | Learned from data, including the features themselves | Usually large (thousands to billions of examples) | Face recognition, speech-to-text, ChatGPT |
Machine learning: programs that learn from data
A classic definition (Tom Mitchell, 1997, quoted in the Deep Learning book) says: a program learns from experience E with respect to a task T and performance measure P if its performance on T, as measured by P, improves with E[6]. For a spam filter, T = labelling emails as spam or not, P = the percentage labelled correctly, and E = a collection of emails that people already marked as spam or not spam.
- rules
- the logic that turns an input into an output, e.g. “if the subject contains FREE, it is spam”. Hand-written in line 1, learned in line 2
- data
- the inputs: emails, photos, rows of a table (features)
- answers
- the outputs. In ML training they are the known correct answers, called labels
- +
- “together with”: both things are fed in
- →
- “produces”: what comes out of the process
- (the model)
- the learned rules are stored as numbers (parameters) inside a Model
▸Worked example
What exactly is a model?
A model is a mathematical function that maps an input x (an email, a photo, a row of house data) to an output ŷ (spam/not spam, ‘cat’, a price). Its behaviour is controlled by numbers called [[parameter|parameters]] (often written θ, or weights w and bias b). Training means automatically adjusting the parameters so the outputs match known answers as closely as possible. A straight line ŷ = w·x + b has 2 parameters; GPT-3 has 175 billion — but the principle is the same.
- ŷ
- y-hat — the model's prediction. The hat means “estimated”; plain y is the true answer (Label (target))
- f
- the Model: a function, e.g. a straight line, a tree or a neural network
- x
- the input: one example, usually a vector of features
- ;
- separates inputs (left) from parameters (right): “f of x, given θ”
- θ
- theta — all learned parameters (weights and biases): 2 numbers for a line, billions for an LLM
▸Worked example
Do not confuse parameters with [[hyperparameter|hyperparameters]]: parameters are learned by the algorithm, while hyperparameters are settings *you* choose before training (how many layers, the learning rate, how many trees). Much of practical ML is choosing good hyperparameters — later lessons give each one its own ‘what happens if I change it’ card. Once trained, using the model to make predictions on new data is called [[inference]].
- Collect data — examples of inputs, usually with the correct answers.
- Choose a model family — a line, a decision tree, a neural network…
- Train — an optimisation algorithm adjusts the parameters to minimise a loss function (a number measuring how wrong the predictions are).
- Evaluate — measure performance on data the model never saw, to check it generalises instead of memorising.
- Deploy & run inference — use the frozen model on new inputs, and monitor it.
from sklearn.linear_model import LinearRegression
# Experience E: house sizes (m²) and their known prices (million Rp)
X = [[36], [45], [60], [72], [90]]
y = [450, 560, 740, 880, 1100]
model = LinearRegression() # model family: a straight line
model.fit(X, y) # TRAINING: learns parameters w and b
print(model.coef_, model.intercept_) # the learned parameters
print(model.predict([[80]])) # INFERENCE on a new houseDeep learning and why it took off
Classical ML relies on humans to design good input features (e.g. ‘number of exclamation marks’ for spam). Deep learning instead stacks many layers of simple units (neurons) so the network learns its own features directly from raw pixels, audio samples or text — edges, then shapes, then objects[3]. The ideas are old (the Perceptron dates from 1958, Backpropagation was popularised in 1986), but they only became dominant around 2012, when three things came together: big labelled datasets such as ImageNet, fast GPUs, and better training tricks. That year, AlexNet cut the ImageNet top-5 error from about 26% to about 15%, convincing the field almost overnight[5].
A short history of AI
| Year | Milestone |
|---|---|
| 1950 | Alan Turing asks whether machines can think and proposes the ‘imitation game’ (Turing test)[2]. |
| 1955–56 | McCarthy, Minsky, Rochester & Shannon's Dartmouth proposal coins the term ‘artificial intelligence’; the workshop runs in summer 1956[4]. |
| 1958 | Rosenblatt's perceptron: the first trainable artificial neuron. |
| 1970s–80s | Expert systems boom; funding cuts lead to ‘AI winters’. |
| 1986 | Backpropagation popularised for training multi-layer networks. |
| 1997 | IBM Deep Blue beats world chess champion Kasparov (search, not learning). |
| 2012 | AlexNet wins ImageNet with a GPU-trained CNN — the deep learning era begins[5]. |
| 2016 | AlphaGo defeats Go champion Lee Sedol (deep learning + reinforcement learning + search). |
| 2017 | The Transformer architecture (‘Attention Is All You Need’). |
| 2020s | Large language models, diffusion image generators, multimodal assistants. |
▸Go deeper: Turing's 1950 paper
Turing considered the question ‘Can machines think?’ too vague and replaced it with a game: an interrogator chats by text with a human and a machine and must tell which is which. If the machine is mistaken for the human about as often as a person would be, it ‘passes’[2]. The paper also answers nine objections (theological, mathematical, ‘Lady Lovelace's objection’ that machines only do what we tell them…) and, remarkably, its final section, ‘Learning Machines’, proposes building a ‘child machine’ and educating it rather than programming adult intelligence directly — essentially the machine learning programme.
The 1955 Dartmouth proposal opened with the conjecture that ‘every aspect of learning or any other feature of intelligence can in principle be so precisely described that a machine can be made to simulate it’ — and optimistically asked for a two-month, ten-person study[4]. The gap between that optimism and reality is a recurring theme of AI history.
Next, we look at the different *kinds* of learning — supervised, unsupervised, self-supervised and reinforcement — which differ in what feedback signal the model gets.
Quiz
References
- [1]Artificial Intelligence: A Modern Approach (4th ed.)BookRussell & Norvig2020aima.cs.berkeley.eduDefinition of AI as rational agents.
- [2]Computing Machinery and IntelligencePaperTuring1950doi.orgThe imitation game and ‘Learning Machines’.
- [3]Deep learningPaperLeCun, Bengio & Hinton2015doi.orgNature review of deep learning and representation learning.
- [4]A Proposal for the Dartmouth Summer Research Project on Artificial IntelligencePaperMcCarthy, Minsky, Rochester & Shannon1955jmc.stanford.edu
- [5]ImageNet Classification with Deep Convolutional Neural NetworksPaperKrizhevsky, Sutskever & Hinton2012proceedings.neurips.cc
- [6]Deep Learning — Chapter 5: Machine Learning BasicsBookGoodfellow, Bengio & Courville2016deeplearningbook.orgMitchell's T/P/E definition of learning.