All exams← All AWS Certified AI Practitioner (AIF-C01) notes

Fundamentals of AI, ML & deep learning: AWS Certified AI Practitioner (AIF-C01) revision notes

Revision notes

What AI, ML and deep learning actually are

Artificial Intelligence (AI) is the broad field of building systems that can perform tasks normally needing human intelligence - reasoning, perception, language, decision-making.

Machine Learning (ML) sits inside AI: it is the practice of training algorithms on data so they learn patterns and improve at a task without being explicitly programmed with rules for every case.

Deep learning sits inside ML: it uses artificial neural networks with many layers (hence 'deep') to learn complex patterns, especially from unstructured data like images, audio and text.

Generative AI sits inside deep learning: models (often built on transformer architecture) that generate new content - text, images, code, audio - rather than just classifying or predicting a number.

The three main ML learning types

  • Supervised learning: trains on labelled data (input plus known correct output), e.g. predicting house price from features. Used for classification and regression.
  • Unsupervised learning: trains on unlabelled data to find structure, e.g. clustering customers into segments. No 'correct answer' given.
  • Reinforcement learning: an agent learns by taking actions in an environment and receiving rewards or penalties, aiming to maximise cumulative reward over time, e.g. game-playing agents or robotics.

Key building blocks of neural networks

  • Neurons (nodes) organised in layers: input layer, one or more hidden layers, output layer.
  • Weights and biases: learned numeric values that determine how strongly inputs influence outputs.
  • Activation functions (e.g. ReLU, sigmoid): introduce non-linearity so networks can learn complex patterns, not just straight lines.
  • Training uses forward propagation (making a prediction) and backpropagation (adjusting weights based on the error, using gradient descent) across many epochs.

Common exam trip-ups

  • Do not confuse AI (broadest), ML (subset), deep learning (subset of ML) and generative AI (subset of deep learning) - the exam loves testing this nesting.
  • Labelled data is the defining feature of supervised learning, not unsupervised.
  • Reinforcement learning is defined by reward signals and sequential decisions, not by having labelled training examples.
  • A model 'training' on data is different from a model 'performing inference' (making predictions on new, unseen data) - know the split between the training phase and the inference phase.
  • Overfitting means a model performs well on training data but poorly on new data - it has memorised rather than generalised.

Key facts

Flashcards

How does AI relate to ML, deep learning and generative AI?
Nested subsets: AI is broadest, ML is a subset of AI, deep learning is a subset of ML, generative AI is a subset of deep learning.
tap to reveal
What defines supervised learning?
Training on labelled data (inputs with known correct outputs) for tasks like classification and regression.
tap to reveal
What defines unsupervised learning?
Training on unlabelled data to discover hidden patterns or structure, e.g. clustering.
tap to reveal
What defines reinforcement learning?
An agent learns by taking actions in an environment and receiving rewards or penalties, aiming to maximise cumulative reward.
tap to reveal
What makes deep learning 'deep'?
Neural networks with multiple hidden layers between the input and output layers.
tap to reveal
What is backpropagation?
The process of adjusting a neural network's weights based on prediction error, using gradient descent, to reduce error over training.
tap to reveal
What role do activation functions play?
They introduce non-linearity so the network can learn complex, non-straight-line patterns.
tap to reveal
What is the difference between training and inference?
Training is when the model learns from data; inference is when the trained model makes predictions on new, unseen data.
tap to reveal
What is overfitting?
When a model performs well on training data but poorly on new data because it has memorised rather than generalised.
tap to reveal
What is generative AI typically built on?
Transformer architecture, used to generate new content such as text, images, audio or code.
tap to reveal
What is the difference between classification and regression?
Classification predicts a discrete category/label; regression predicts a continuous numeric value.
tap to reveal
Give an example task suited to unsupervised learning.
Customer segmentation - clustering customers into groups without predefined labels.
tap to reveal
Give an example task suited to reinforcement learning.
A game-playing agent or robot learning optimal actions through trial and reward feedback.
tap to reveal
Practice questions

Fundamentals of AI, ML & deep learning: 5 practice questions

Q1. What is the main difference between generative AI and traditional discriminative/predictive AI models?
  • A.  Generative AI can only process numerical data, while discriminative AI only processes text
  • B.  Generative AI creates new content (text, images, audio) resembling its training data, while discriminative models classify or predict labels for given inputs
  • C.  Generative AI does not require any training data at all
  • D.  Discriminative AI always requires more training data than generative AI
Show answer & explanation
✓ Answer: B. Generative AI creates new content (text, images, audio) resembling its training data, while discriminative models classify or predict labels for given inputs
Generative models learn the underlying distribution of training data well enough to produce new, plausible examples, such as generating an image or paragraph. Discriminative models instead learn a boundary or mapping to predict a label or value for a given input, such as classifying an image as 'cat' or 'dog'.
Q2. In the context of large language models (LLMs), what does 'tokenization' refer to?
  • A.  Breaking text into smaller units, such as words or subwords, that the model can process numerically
  • B.  Compressing model weights to reduce file size on disk
  • C.  Encrypting user prompts before they reach the model
  • D.  Assigning a unique cloud billing token to each API call
Show answer & explanation
✓ Answer: A. Breaking text into smaller units, such as words or subwords, that the model can process numerically
Tokenization splits input text into tokens (words, subwords, or characters) which are then mapped to numeric IDs the model can process as vectors. It is a text preprocessing step central to how LLMs read and generate language, unrelated to billing or encryption.
Q3. A retail company notices that a deployed model's prediction accuracy is steadily declining over several months as customer purchasing patterns change. What is this phenomenon commonly called?
  • A.  Vanishing gradient
  • B.  Gradient explosion
  • C.  Overfitting
  • D.  Model (or data) drift
Show answer & explanation
✓ Answer: D. Model (or data) drift
Model drift (or data drift/concept drift) occurs when the statistical properties of real-world input data or the relationship between inputs and outputs change over time, causing a previously accurate model's performance to degrade. This is addressed by monitoring performance and periodically retraining, unlike overfitting which is a training-time issue.
Q4. What does 'underfitting' typically indicate about a machine learning model?
  • A.  The model is too complex and has memorised the training data
  • B.  The training dataset contains too many labelled examples
  • C.  The model has achieved perfect generalisation
  • D.  The model is too simple or undertrained to capture the underlying patterns in the data
Show answer & explanation
✓ Answer: D. The model is too simple or undertrained to capture the underlying patterns in the data
Underfitting happens when a model lacks the capacity, features, or training time to learn the true relationship in the data, resulting in poor performance on both training and test sets. This is the opposite of overfitting, where performance is good on training data but poor on new data.
Q5. What is 'prompt engineering' in the context of using large language models?
  • A.  Physically engineering the server racks that host the model
  • B.  A method for automatically labelling training data at scale
  • C.  Crafting and refining input instructions to guide a foundation model toward a desired output, without changing its weights
  • D.  Writing low-level CUDA code to speed up GPU training
Show answer & explanation
✓ Answer: C. Crafting and refining input instructions to guide a foundation model toward a desired output, without changing its weights
Prompt engineering involves designing the wording, structure, and examples in a prompt to elicit better, more accurate, or more relevant responses from a pre-trained model, without retraining or fine-tuning it. It requires no changes to model weights or infrastructure.
Test yourself
See the AWS Certified AI Practitioner (AIF-C01) page

More AWS Certified AI Practitioner (AIF-C01) topics