Module 1 of 12

LLM Fundamentals

Lessons

About This Module

Every RAG system is built around a large language model, so it helps to know what that model actually does. At its core, an LLM reads text, breaks it into small pieces called tokens, and predicts what should come next, one piece at a time. That simple idea, repeated billions of times during training, is what makes chatbots and assistants possible.

The lessons start with a short animated overview of LLMs, then look inside the transformer architecture that powers them. A longer talk covers how models are trained and used, a lesson on hallucinations explains why they confidently produce wrong answers (the problem RAG helps to solve), and a final deep dive shows how tokenization turns text into numbers.

Watch the lessons in order. The last video is long and technical, so feel free to watch just the opening section for now and come back to it later as a reference.

Lessons

5 videos
01

Large Language Models explained briefly

A short animated explainer on what a large language model is: how it predicts the next word, how training adjusts its parameters, and where transformers fit in.

Video 8min
02

Transformers, the tech behind LLMs

A visual walk through the transformer architecture behind GPT models: predicting the next token, word embeddings, and how softmax with temperature shapes the output.

Video 27min
03

[1hr Talk] Intro to Large Language Models

Andrej Karpathy's general-audience introduction to how LLMs are run, trained, and fine-tuned, plus the idea of an LLM as an operating system and the security issues that come with it.

Video 1hr
04

Why Large Language Models Hallucinate

Why LLMs produce fluent but false answers, what causes hallucinations, and how clearer prompts can help reduce them.

Video 9min
05

Let's build the GPT Tokenizer

A long, hands-on lecture on how text becomes tokens, building a Byte Pair Encoding tokenizer from scratch. The first part gives useful background on tokens, and the rest is an optional deep dive.

Video 2h 13min