Skip to content
5 min read·Lesson 1 of 10

AI vs ML vs Deep Learning vs Generative AI

Understand the relationship between artificial intelligence, machine learning, deep learning, and generative AI — four nested concepts that are often confused.

The terms "AI", "machine learning", "deep learning", and "generative AI" are often used interchangeably in marketing — but they describe distinct, nested concepts. Understanding the relationship is the first step to having a grounded conversation about modern AI.

The Russian Doll Model

Think of these terms as nested Russian dolls — each is a subset of the one outside it:

┌─────────────────────────────────────────────┐
│  Artificial Intelligence                    │
│  ┌───────────────────────────────────────┐  │
│  │  Machine Learning                     │  │
│  │  ┌─────────────────────────────────┐  │  │
│  │  │  Deep Learning                  │  │  │
│  │  │  ┌──────────────────────────┐   │  │  │
│  │  │  │  Generative AI (LLMs)    │   │  │  │
│  │  │  └──────────────────────────┘   │  │  │
│  │  └─────────────────────────────────┘  │  │
│  └───────────────────────────────────────┘  │
└─────────────────────────────────────────────┘

Artificial Intelligence (AI)

The broadest term. AI is the field of computer science focused on building systems that exhibit behaviour we would call "intelligent" if a human did it — perceiving the environment, reasoning, learning, planning, problem-solving, understanding language.

The field was named at the Dartmouth Conference in 1956. AI includes both:

  • Symbolic AI (rule-based, expert systems): "If temperature > 100°F and pulse > 120, recommend hospitalisation." Dominant in the 1970s–80s.
  • Statistical / ML-based AI: Learn rules from data. Dominant since the 2010s.

A spam filter that uses hand-coded rules ("If the email contains 'free Viagra', flag as spam") is AI but not machine learning.

Machine Learning (ML)

Coined by Arthur Samuel in 1959: "the field of study that gives computers the ability to learn without being explicitly programmed."

Instead of writing rules, you provide examples (the training data) and let the system discover patterns. The output is a model — a mathematical function that maps inputs to outputs.

Examples:

  • Show a model 10,000 emails labelled "spam" or "not spam" — it learns to classify new emails.
  • Show a model historic house prices and features (size, bedrooms, location) — it learns to predict prices.
  • Show a model customer purchase histories — it learns to recommend products.

Deep Learning

Deep learning is a subset of machine learning that uses artificial neural networks with many layers ("deep" networks). Each layer learns increasingly abstract features from the input:

  • Image recognition: Layer 1 detects edges → Layer 2 detects shapes → Layer 3 detects parts (eyes, wheels) → Layer 4 detects whole objects (faces, cars).

Deep learning's breakthrough came around 2012 when AlexNet won the ImageNet competition by a wide margin, made possible by:

  • Large labelled datasets (ImageNet had 14 million images)
  • Powerful GPUs that made training feasible
  • Better training algorithms (ReLU activation, dropout)

Generative AI

A subset of deep learning focused on creating new content rather than classifying existing content. Generative AI models include:

TypeOutputExamples
Large Language Models (LLMs)Text, codeGPT-4, Claude, Gemini, Llama
Text-to-imageImagesDALL-E, Midjourney, Stable Diffusion
Text-to-videoVideo clipsSora, Veo, Runway
Text-to-speechAudioElevenLabs, OpenAI TTS
Music generationAudioSuno, Udio

Discriminative vs Generative

The fundamental split in ML:

  • Discriminative models predict labels for inputs: "Is this email spam?" or "What digit is in this image?"
  • Generative models create new samples that resemble the training data: "Write me a poem about autumn" or "Generate an image of a cat in a spacesuit."

The current AI boom is largely driven by generative models, particularly LLMs based on the transformer architecture introduced by Google in 2017 — which we will cover in lesson 7.

Key Takeaways

  • Artificial Intelligence (AI) is the broad field of building machines that exhibit intelligent behaviour.
  • Machine Learning (ML) is a subset of AI where systems learn patterns from data instead of being explicitly programmed.
  • Deep Learning is a subset of ML that uses neural networks with many layers.
  • Generative AI is a subset of deep learning focused on creating new content (text, images, code, audio).
  • Large Language Models (LLMs) like GPT, Claude, and Gemini are the most prominent generative AI systems today.

Test your knowledge

Try exam-style practice questions to reinforce what you've learned.

Practice Questions →