B1 · Introduction to Artificial Intelligence

AI, Machine Learning and Deep Learning

AI is the broad goal of making machines do intelligent tasks. Machine Learning is one way to reach it, by learning from data. Deep Learning is one kind of ML that uses neural networks with many layers. Generative AI is an application, mostly built with deep learning, that creates new content.

8 min Beginner Jump to the activity

What you need: Nothing. This page starts from the beginning, with no programming and no formulas.

Definition

AI is the broad goal of making machines do intelligent tasks. Machine Learning is one way to reach it, by learning from data. Deep Learning is one kind of ML that uses neural networks with many layers. Generative AI is an application, mostly built with deep learning, that creates new content.

In simple words

Picture circles inside circles. The biggest circle is AI. Inside it is ML. Inside that is deep learning. So all deep learning is ML, and all ML is AI, but not all AI is ML. It's like: all mangoes are fruit, and all fruit is food, but not all food is fruit.

Why it matters

These words get mixed up all the time, in news, in job adverts and in pitches. Knowing the difference lets you judge what a product really does, pick the right tool, and read the rest of this course without confusion.

Key terms

Artificial intelligence
The broad field of making machines do tasks that need intelligence.
Machine learning (ML)
A way of building AI in which the system learns patterns from data.
Deep learning (DL)
Machine learning that uses neural networks with many layers.
Neural network
A model made of layers of simple connected units, loosely inspired by the brain.
Layer
One stage of a neural network. Each layer passes its result to the next.
Generative AI
AI that creates new content such as text, images or audio. Most of it is built with deep learning.

Explained in detail

Three words that are often mixed up

News reports use AI, machine learning and deep learning as if they meant the same thing. They do not. They are nested: deep learning is one kind of machine learning, and machine learning is one way of doing AI. A good comparison is transport, vehicles with engines, and cars. Every car is a vehicle with an engine, and every such vehicle is a form of transport, but transport also includes bicycles and boats.

AI that is not machine learning

For its first few decades, most AI did not learn at all. Programmers wrote the knowledge in by hand. A chess program searched through possible moves using rules written by experts. An expert system for medicine held hundreds of "if this, then that" rules given by doctors. Route finding on a map uses a search method worked out by people. All of these are AI, because they do tasks that need intelligence, but none of them is machine learning, because nothing was learned from data.

Machine learning: let the data write the rules

Machine learning turned the process around. People no longer write the rules; they supply examples, and the system finds the rules itself. To build a spam filter, you do not list every spam trick. You give the system thousands of emails marked "spam" or "not spam", and it works out which patterns separate them. Some machine learning methods are quite simple and work well with small tables of data, such as predicting a house price from its size and location. They need a person to choose which features of the data to use.

Deep learning: many layers

Deep learning uses neural networks with many layers, sometimes hundreds. The word "deep" refers to this number of layers, not to deep thinking. Each layer learns something a little more complex than the one before. In a network that recognises faces, the first layers respond to simple edges and patches of colour, the middle layers to shapes such as eyes and noses, and the last layers to whole faces. Nobody tells the network to look for eyes; it discovers useful features by itself from millions of examples. This is why deep learning works so well for pictures, sound and language, where it is very hard for a person to describe the right features.

The price is that deep learning needs very large amounts of data and powerful computers, and its decisions are hard to explain. For a small table of numbers, a simpler machine learning method is often just as accurate, much cheaper and easier to understand.

Where generative AI fits

Generative AI, the technology behind chatbots and image makers, is not a fourth circle around the others. It is an application built with deep learning: very large neural networks trained to produce new text, images, audio or video. So a chatbot is generative AI, which is deep learning, which is machine learning, which is AI.

SystemAI?Machine learning?Deep learning?
A chess program using expert rulesYesNoNo
A house-price predictor using a small tableYesYesNo
Face unlock on a phoneYesYesYes
A chatbot that writes essaysYesYesYes (generative)

How it works

TermWhat it isNeedsExample
AIAny technique that makes machines act intelligentlyRules, search or learningA chess program with hand-written rules
Machine LearningLearning patterns from dataData, often in tablesFraud detection with decision trees
Deep LearningML with many-layered neural networksLots of data and GPUsRecognising faces in photos
Generative AIModels that create new text, images or audioVery large modelsChatGPT, image generators

Is data science part of this?

Data science overlaps but is a separate field. It means using statistics, programming and domain knowledge to get insights from data. A data scientist may use ML, or may only need a good chart.

Which one should you use?

  • If clear rules exist, write the rules. Plain software is cheaper and easier to check.
  • If you have tables of data, start with classic ML. It often wins on tables, with less data and cost.
  • If you have images, audio or lots of text, deep learning is usually the right choice.
  • If you need new content or natural conversation, use generative AI, and check what it produces.

Try it yourself

Which circle does it land in?

Tap each system and watch it jump to where it belongs.

Drag systems into the right circle

Choose the smallest circle each system belongs to.

  • Face unlock using a large neural network

  • A house-price predictor trained on past sales

  • A chatbot that writes a new poem

  • A spam filter that learns from emails marked as spam

  • A route planner that searches every road by fixed steps

  • An image generator that draws from a sentence

Common mistakes

  • Saying "AI" and "ChatGPT" as if they're the same. ChatGPT is one product in one small part of AI.
  • Assuming deep learning is always best. On small tables of data, simpler ML often beats it.
  • Calling every if-else rule "AI" because it sounds impressive.

Check yourself

Question 1

1. Which statement is true?

Question 2

2. You have a small table of 2,000 customer records. What should you try first?

Summary

  • AI ⊃ Machine Learning ⊃ Deep Learning.
  • Generative AI creates new content and is mostly built with deep learning.
  • Pick the simplest thing that works: rules, then classic ML, then deep learning.

Finished reading?

Sources: Russell & Norvig, Artificial Intelligence: A Modern Approach