01 · What Is AI? The Big Picture
Before using AI tools well, you need a clear mental map: what "AI" means, how machine learning, deep learning, generative AI and LLMs fit together, and what these systems are and are not good at.
By the end of this page you can
- Explain the difference between AI, ML, deep learning, generative AI and LLMs to a non-technical friend.
- Name the main ways machines learn (supervised, unsupervised, self-supervised, reinforcement).
- Describe the key milestones that led to today's AI.
- Separate a model, a product and an agent.
- Predict roughly where AI will help you and where it will fail.
Artificial Intelligence in one sentence
Artificial Intelligence (AI) is the field of building computer systems that perform tasks we normally associate with human intelligence: understanding language, recognising images, making decisions, solving problems, and creating content.
This is an umbrella term. It covers chess engines from the 1990s, the spam filter in your email, the face unlock on your phone, and the chat assistant that writes Scala code with you. These systems work in very different ways.
Two ways to make a computer "smart"
1. Rules written by humans
"If the email contains 'lottery' AND an unknown sender, mark it spam." This is symbolic AI or "expert systems". It is predictable and explainable, but brittle: real life has too many cases to write rules for all of them.
2. Patterns learned from data
Show the system 1 million emails labelled spam / not spam and let it learn the patterns. This is machine learning. It handles messy reality well, but it is harder to explain and can learn the wrong lessons.
Almost all modern AI, including every AI coding assistant, is the second kind: learned from data.
The nesting dolls: AI, ML, DL, GenAI, LLM
| Term | Plain meaning | Everyday example |
|---|---|---|
| AI | Machines doing tasks that seem to need intelligence. | A route planner, a chess engine, a chatbot. |
| Machine Learning (ML) | The machine learns rules from examples instead of being programmed with them. | Spam filters, credit scoring, recommendations. |
| Deep Learning (DL) | ML with large neural networks (many layers of simple maths units). | Face recognition, speech-to-text, translation. |
| Generative AI (GenAI) | Models that create new content: text, images, audio, code, video. | Image generators, music generators, chat assistants. |
| LLM (Large Language Model) | A generative model trained on huge amounts of text (and code) to predict the next piece of text. | The models behind chat assistants and AI coding tools. |
| Foundation model | A big general-purpose model that can be adapted to many tasks. | One LLM used for chat, code, summarising and translation. |
| Multimodal model | Understands and/or produces more than one type of data (text + images + audio…). | Paste a screenshot of an error and ask "what's wrong?". |
How machines learn: the four styles
Supervised learning
Learn from labelled examples: input → correct answer. "Here are 10,000 house descriptions with their prices. Learn to predict the price." Used for classification (spam or not) and regression (predict a number).
Unsupervised learning
Find structure in unlabelled data. "Here are 1 million customers; group them into similar segments." Used for clustering, anomaly detection and compression.
Self-supervised learning
The data creates its own labels. Hide a word in a sentence and predict it, or predict the next word. No human labelling is needed, so you can train on enormous datasets. This is how LLMs are pre-trained, and it is the main reason they could become so large.
Reinforcement learning (RL)
Learn by trial, error and reward. An agent takes actions, gets a reward signal and improves. It is used for game-playing AIs and robotics, and in LLM post-training (for example RLHF, reinforcement learning from human feedback) to make models more helpful and safer.
A short history (why now?)
Three ingredients came together in the 2010s:
- Data: the internet, open-source code and digitised books gave billions of examples.
- Compute: GPUs (first built for video games) turned out to be ideal for the maths neural networks need.
- Algorithms: the Transformer (2017, the paper "Attention Is All You Need") could be trained in parallel and scaled smoothly. Researchers found that bigger models trained on more data kept getting better ("scaling laws").
Model vs product vs agent
People mix these up all the time. Keeping them separate will make every later page clearer.
- Model: a file of billions of numbers ("weights") and the code to run them. On its own it only turns input text into output text.
- Product / application: wraps the model with a user interface, hidden instructions (the system prompt), conversation history, file uploads, safety filters and more.
- Agent: a model that can use tools (read files, run tests, search the web, call APIs) in a loop to reach a goal. Covered in page 08.
What AI is great at, and where it fails
Usually strong
- Drafting text, code, tests, docs, emails
- Explaining code and concepts at any level
- Translating between languages, including Python ↔ Scala
- Summarising long material
- Boilerplate, scaffolding, refactoring patterns
- Brainstorming options and trade-offs
- Working through common errors and stack traces
Often weak (verify!)
- Exact facts, dates, version numbers, API names (it may hallucinate)
- Things newer than its training data, unless given docs or search
- Your private context: business rules, codebase conventions, unless you provide them
- Precise arithmetic and counting without tools
- Long chains of reasoning without checks
- Knowing when it does not know
Narrow AI, general AI and the hype
- Narrow AI: excellent at specific tasks (playing chess, recognising faces). Everything deployed today is narrow in some sense, even if LLMs are surprisingly broad.
- AGI (Artificial General Intelligence): a hypothetical system that matches humans across essentially all cognitive tasks. Experts disagree strongly on whether and when it will arrive, and even on how to define it.
- Practical stance: ignore the hype and the doom. Learn what today's tools do reliably, measure them on your own tasks, and keep up to date.
Common myths
| Myth | Reality |
|---|---|
| "The AI looks things up in a database of facts." | An LLM generates text from patterns in its weights. It only "looks things up" if the product gives it a search or retrieval tool. |
| "It remembers our past chats and learns from me." | The model's weights do not change while you chat. Some products store "memories" and add them to the prompt. That is a product feature, not learning. |
| "If it sounds confident, it's right." | Confidence of tone is unrelated to correctness. |
| "AI will replace developers." | AI changes what developers spend time on: less typing, more specifying, reviewing, designing and verifying. People who use AI well are replacing workflows that don't. |
| "You need maths to use AI well." | Not to use it well (Levels 1–3). Maths becomes important when you go into internals (Level 4). |
Key takeaways
- AI ⊃ ML ⊃ Deep Learning ⊃ Generative AI ⊃ LLMs.
- Modern AI learns patterns from data. LLMs are pre-trained by predicting the next token on huge datasets (self-supervised).
- The recent boom comes from Transformers + data + GPUs + scaling.
- Model ≠ product ≠ agent. Tools and context make a model useful.
- AI drafts and you verify.