Understanding Artificial Intelligence and Machine Learning

Thank you for reading this post, don't forget to subscribe!

Artificial IntelligenceMachine LearningDeep LearningData Science

Artificial intelligence is no longer a concept confined to science fiction — it is embedded in search engines, medical diagnostics, financial systems, and the tools you use every day. But what does it actually mean for a machine to “learn”? This technical deep-dive cuts through the hype to explain how AI and machine learning really work, from first principles to cutting-edge architectures.

Table of Contents

01What is Artificial Intelligence?

05Neural Networks explained

02AI vs Machine Learning vs Deep Learning

06Deep Learning & modern architectures

03A brief history of AI

07Natural Language Processing

04Core ML concepts & algorithms

08Ethics, limitations & the future

01 — What is Artificial Intelligence?

Artificial Intelligence (AI) is a branch of computer science focused on building systems that can perform tasks which, when done by humans, would require intelligence. This includes reasoning, learning from experience, understanding language, recognising patterns, and making decisions.

The term was coined by John McCarthy in 1956, who defined it as “the science and engineering of making intelligent machines.” Today, the field spans everything from narrow, task-specific systems (like a spam filter) to the emerging frontier of general-purpose AI models that can reason across domains.

🧠

Narrow AI (ANI)

Designed for one specific task. Examples: facial recognition, chess engines, recommendation algorithms.

General AI (AGI)

Hypothetical AI capable of reasoning across any domain at human level. Not yet achieved.

🚀

Superintelligence (ASI)

A theoretical AI surpassing all human cognitive abilities. Subject of intense research and debate.

02 — AI vs Machine Learning vs Deep Learning

These three terms are often used interchangeably, but they describe distinct — and nested — concepts. Understanding the hierarchy is essential before going deeper.

Artificial Intelligence

  • Broadest umbrella term
  • Any technique enabling machines to mimic human intelligence
  • Includes rule-based systems, expert systems, ML, and more

Machine Learning

  • A subset of AI
  • Systems that learn from data without being explicitly programmed
  • Improves performance through experience

Key distinction: Traditional programming = humans write rules → computer follows them. Machine learning = humans provide data + desired outcomes → computer discovers the rules itself.

Deep Learning is a further subset of Machine Learning that uses multi-layered neural networks. It is responsible for most of the breakthroughs seen in image recognition, speech synthesis, and large language models (LLMs) over the past decade.

03 — A brief history of AI

1943–1956

Foundations

McCulloch & Pitts propose the first mathematical model of a neuron. Alan Turing publishes “Computing Machinery and Intelligence”, introducing the Turing Test. The Dartmouth Conference coins the term “Artificial Intelligence”.

1957–1974

The golden years

Frank Rosenblatt invents the Perceptron. ELIZA — an early natural language program — is developed at MIT. Optimism is high; funding flows freely.

1974–1993

AI winters

Progress stalls due to hardware limits and overpromising. Government funding is cut. Expert systems rise then fall. Two prolonged periods of reduced interest and investment follow.

1997–2011

Resurgence

IBM’s Deep Blue defeats Garry Kasparov at chess. Statistical ML methods gain popularity. Watson wins Jeopardy! The internet creates vast datasets that fuel learning.

2012–present

The deep learning revolution

AlexNet wins ImageNet. GPUs make training deep networks practical. AlphaGo, GPT, DALL·E, and large language models transform the field. AI enters mainstream products globally.

04 — Core ML concepts and algorithms

Machine learning algorithms fall into three major categories, defined by the nature of the signal they learn from.

3Core learning paradigms in ML

100+Distinct ML algorithms in active use

175BParameters in GPT-3 (2020)

AlgorithmTypeUse caseExample
Linear RegressionSupervisedPredicting continuous valuesHouse price forecasting
Logistic RegressionSupervisedBinary classificationSpam detection
Decision Trees / Random ForestSupervisedClassification & regressionCredit scoring
Support Vector Machine (SVM)SupervisedClassification with clear marginImage classification
K-Means ClusteringUnsupervisedGrouping unlabelled dataCustomer segmentation
Principal Component AnalysisUnsupervisedDimensionality reductionFeature compression
Q-Learning / PPOReinforcementLearning via reward signalsGame playing, robotics

Model evaluation: Every ML model must be evaluated on data it was not trained on. Common metrics include accuracy, precision, recall, F1-score (classification), and RMSE (regression). Overfitting — when a model memorises training data but fails to generalise — is one of the most common pitfalls.

05 — Neural Networks explained

Neural networks are loosely inspired by the structure of biological brains. They consist of layers of interconnected nodes (neurons), each performing a simple mathematical operation. The power emerges from composing these simple operations at scale.

Anatomy of a neural network

  • Input layer: receives raw data (pixel values, word embeddings, sensor readings)
  • Hidden layers: transform and extract features from the input through weighted connections and activation functions
  • Output layer: produces the final prediction (a class label, a probability, a generated token)
  • Weights & biases: the learnable parameters of the network, updated during training
  • Activation functions: introduce non-linearity; common choices include ReLUsigmoid, and softmax

How training works: backpropagation

Training a neural network is an optimisation problem. The network makes a prediction, a loss function measures how wrong it is, and the gradient of that loss with respect to each weight is computed via backpropagation. An optimiser — typically Adam or SGD — then adjusts the weights to reduce the loss. This cycle repeats over thousands or millions of iterations.

Intuition: Think of it like adjusting a radio dial. Each training step moves the dial slightly closer to the frequency that gives the clearest signal. Backpropagation tells you which direction to turn, and by how much.

06 — Deep Learning & modern architectures

Deep Learning refers to neural networks with many hidden layers (“deep” architectures). The depth allows the model to learn increasingly abstract representations of data — from edges and textures in an image, to objects, to semantic meaning.

📷

Convolutional Neural Networks (CNNs)

Specialised for grid-like data such as images. Use convolutional filters to detect spatial features. Power most computer vision systems.

🔁

Recurrent Neural Networks (RNNs)

Designed for sequential data. Maintain a hidden state that captures context over time. Used in early NLP and time-series forecasting.

⚙️

Transformers

The dominant architecture since 2017. Uses self-attention to model relationships across entire sequences in parallel. Foundation of GPT, BERT, and modern LLMs.

🎨

Generative Models (GANs / Diffusion)

Learn the distribution of training data to generate new examples. Power image synthesis, video generation, and audio models.

The Transformer architecture: why it matters

Introduced in the landmark 2017 paper “Attention is All You Need” by Vaswani et al., the Transformer replaced sequential processing with parallel self-attention. Each token in a sequence can directly attend to every other token, enabling the model to capture long-range dependencies that RNNs struggled with. This architecture scales exceptionally well with data and compute — a property that has driven the rapid improvement of large language models.

07 — Natural Language Processing

Natural Language Processing (NLP) is the subfield of AI concerned with enabling machines to understand, generate, and manipulate human language. It is one of the most commercially impactful areas of AI today.

Core NLP tasks

  • Tokenisation: splitting text into units (words, subwords, characters) the model can process
  • Named Entity Recognition (NER): identifying people, places, dates, and organisations in text
  • Sentiment analysis: classifying the emotional tone of a piece of text
  • Machine translation: converting text from one language to another
  • Text generation: producing coherent, contextually appropriate text sequences
  • Question answering: extracting or generating answers from a provided context

Large Language Models (LLMs)

LLMs are Transformer-based models trained on massive corpora of text using a self-supervised objective — typically predicting the next token. Through this process, they develop emergent capabilities: reasoning, code generation, summarisation, and instruction following, none of which were explicitly programmed. Scale — in both model size (parameters) and data — has proven to be the primary driver of capability.

Important caveat: LLMs do not “understand” language in the way humans do. They are sophisticated pattern-matching systems trained to predict plausible continuations of text. This distinction matters when reasoning about their reliability, biases, and failure modes.

08 — Ethics, limitations & the future

Current limitations of AI systems

  • Hallucination: LLMs can generate plausible-sounding but factually incorrect content with false confidence
  • Data hunger: most state-of-the-art models require enormous datasets that are expensive and energy-intensive to process
  • Brittleness: models can fail catastrophically on inputs that differ slightly from their training distribution
  • Lack of causal reasoning: ML models learn correlations, not causation — a critical gap for scientific and medical applications
  • Interpretability: the internal decision-making of deep networks remains largely opaque

Ethical considerations

  • Bias & fairness: models trained on biased data perpetuate and can amplify those biases in consequential decisions
  • Privacy: training on personal data raises questions around consent and data rights
  • Accountability: when an AI system causes harm, who is responsible — the developer, deployer, or user?
  • Environmental cost: training frontier models can consume as much energy as hundreds of transatlantic flights
  • Labour displacement: automation driven by AI is reshaping labour markets at an accelerating pace

Active research frontiers: Mechanistic interpretability · Constitutional AI & alignment · Multimodal reasoning · AI agents & tool use · Efficient training (MoE, distillation) · Continual learning without catastrophic forgetting

Key takeaways

  • AI is a broad field; Machine Learning and Deep Learning are increasingly powerful subsets of it
  • ML systems learn statistical patterns from data — they do not follow hand-coded rules
  • The Transformer architecture and scale have been the two biggest drivers of recent AI progress
  • Modern AI systems are impressive but narrowly capable, brittle outside their training distribution, and prone to confident errors
  • The most important questions in AI today are not purely technical — they are about safety, alignment, and societal impact