Emerging Technologies (8hrs) · Computer Fundamentals & Emerging Technologies

Machine Learning (ML): Types of learning paradigms

Watch lectures

Machine Learning (ML): Types of learning paradigms

1. Definition

Machine Learning (ML) is the branch of AI in which a system learns patterns from data and improves its performance with experience, instead of being given explicit rules for every case. Tom Mitchell's definition: "A computer program is said to learn from experience E with respect to some class of tasks T and performance measure P, if its performance at tasks in T, as measured by P, improves with experience E."

   TRADITIONAL PROGRAMMING           MACHINE LEARNING
   data + RULES  →  answers          data + ANSWERS  →  rules (the model)
   (a human writes the logic)        (the algorithm finds the logic)

ML is the right tool when the rule is too complex to write by hand (recognise a face, predict demand) but plenty of labelled or observable examples exist. It is the wrong tool when the rule is simple, exact and auditable.

2. The Learning Paradigms (the core of this topic)

Paradigm Training data Goal Typical tasks Algorithms
Supervised learning Labelled (input → known output) Learn a mapping from input to output Classification, regression Linear/logistic regression, KNN, SVM, naive Bayes, decision trees, random forest, gradient boosting, neural networks
Unsupervised learning Unlabelled (inputs only) Discover inherent structure Clustering, dimensionality reduction, anomaly detection, association rules K-means, hierarchical clustering, DBSCAN, PCA, t-SNE, Apriori, autoencoders
Semi-supervised learning A few labelled + many unlabelled Use cheap unlabelled data to boost a small labelled set Classification with expensive labels Self-training, co-training, label propagation
Reinforcement learning (RL) No dataset — feedback from an environment Learn a policy that maximises long-term reward Game playing, robotics, control, scheduling Q-learning, SARSA, DQN, policy gradients, PPO
Self-supervised learning Unlabelled data with labels generated from the data itself Learn general representations Language modelling, image pretraining Masked-language/next-token prediction, contrastive learning (modern LLMs)

3. Supervised Learning in Detail

  • Classification — output is a class: spam/not-spam, disease/no-disease, digit 0-9, sentiment positive/negative/neutral, loan default yes/no.
  • Regression — output is a continuous number: house price, temperature, demand, delivery time.
  • Workflow: collect and clean labelled data → feature engineering → split into training / validation / test sets (e.g. 70/15/15) → train the model by minimising a loss function → tune hyperparameters on validation → evaluate once on the untouched test set → deploy → monitor.
  • Evaluation metrics: accuracy, precision, recall, F1 (important with imbalanced classes), confusion matrix, ROC-AUC for classifiers; RMSE/MAE/R² for regression.
  • Pitfalls: overfitting (memorising the training set — great on train, poor on test), underfitting (too simple), class imbalance, data leakage, and non-representative samples. Cures: more/cleaner data, regularisation, cross-validation, simpler models, augmentation.

4. Unsupervised Learning in Detail

  • Clustering — group similar items: customer segmentation, document grouping, image compression, market basket grouping.
  • Dimensionality reduction — compress many features into few while preserving structure (PCA, t-SNE) for visualisation and speed.
  • Anomaly detection — flag the unusual: network intrusion, machine fault, fraudulent claim.
  • Association rule mining — "customers who bought X also bought Y" (Apriori), used in cross-selling and recommendation.
    There is no "correct answer" to compare against, so evaluation is harder — silhouette scores, business usefulness and stability of clusters are used instead.

5. Reinforcement Learning in Detail

An agent interacts with an environment: it observes a state, takes an action, receives a reward and moves to the next state, learning a policy that maximises cumulative reward. Key terms: state, action, reward, policy, value function, discount factor, episode; the trade-off between exploration (try new actions) and exploitation (use what works); the problem is modelled as a Markov Decision Process (MDP). Rewards may be sparse and delayed — the credit-assignment problem.
Applications: game playing (AlphaGo, Atari), robot walking and grasping, traffic-signal control, energy/cooling optimisation, ad bidding, recommendation, and LLM alignment through RLHF (reinforcement learning from human feedback).

6. Other Useful Concepts

Batch vs online learning (train on all data at once vs continuously update) · instance-based vs model-based (memorise examples, e.g. KNN, vs learn parameters) · transfer learning (reuse a model trained on a big dataset for a new task — the norm in vision and NLP) · few-shot / zero-shot learning · federated learning (train across devices without moving raw data — privacy-friendly) · ensemble methods (bagging/boosting, random forests) · MLOps (versioning data and models, deployment, monitoring for drift, retraining).

7. Supervised vs Unsupervised vs Reinforcement — quick contrast

Basis Supervised Unsupervised Reinforcement
Labels Required Not required None — reward signal instead
Feedback Immediate per example None Delayed, after actions
Main tasks Classification, regression Clustering, reduction, anomalies Sequential decision-making, control
Data need Large labelled dataset Any dataset Environment/simulator to interact with
Example Spam filter Customer segmentation Self-driving control, game AI

8. Exam Points

  • Define machine learning; differentiate it from traditional programming — 5 marks, frequent.
  • Explain supervised, unsupervised and reinforcement learning with examples — 7 marks, almost certain.
  • Differentiate classification and regression — 3-5 marks.
  • Explain RL with agent, state, action, reward and policy; give two applications — 5 marks, frequent.
  • What is overfitting? How is it detected and prevented? — 5 marks.
  • Explain the ML pipeline / workflow steps — 5 marks.
  • Define semi-supervised and self-supervised learning — 3-5 marks.
  • Which paradigm suits a given problem (segmentation, spam filter, robot walking)? — 3-5 marks.
Budget AppAndroid App

Pocketly on Android

Log daily food, travel, and hostel expenses instantly. Set monthly spending limits and see where your money goes without complex spreadsheets.

← All Computer Fundamentals & Emerging Technologies modules