Learn
-
Aug 22, 2026

Large language models explained briefly

A short, highly visual explainer on what happens inside a large language model.

Beginner
-
8
mins

3Blue1Brown is known for explaining complex mathematics through clear animations. This short video, originally made for an exhibit at the Computer History Museum, gives a light and visual introduction to large language models (LLMs), chatbots, pretraining and transformers. It is one of the best starting points for understanding what is actually happening inside tools like ChatGPT and Claude.

Here are the core ideas in written form.

AN LLM PREDICTS THE NEXT WORD

At its core, a large language model is a function that takes a piece of text and predicts what comes next. More precisely, it assigns a probability to every possible next word, or token. A chatbot works by repeating this prediction many times: it picks a likely next token, adds it to the text and predicts again. Long, coherent answers emerge from this simple loop.

PARAMETERS: WHAT THE MODEL LEARNS

The behaviour of the model is set by its parameters, often called weights: billions of numbers that determine how input text is turned into predictions. Nobody writes these numbers by hand. They are learned during training.

PRETRAINING

In pretraining, the model processes an enormous amount of text and repeatedly tries to predict missing or next words. Each time it is wrong, its parameters are adjusted slightly to make the correct answer more likely. Repeated across trillions of examples, this produces a model with broad knowledge of language and the world. Pretraining requires very large amounts of computing power.

FROM AUTOCOMPLETE TO ASSISTANT

A pretrained model is good at continuing text, but not necessarily at being helpful. Further training, including reinforcement learning from human feedback (RLHF), uses human ratings of answers to shape it into an assistant that follows instructions and responds usefully.

TRANSFORMERS AND ATTENTION

Modern LLMs are built on the transformer architecture. Its key mechanism, attention, lets each word in the text take context from the other words around it. This is how the model understands that "bank" means something different in "river bank" and "bank account". Transformers also process text in parallel, which made training on huge datasets practical.

KEY TAKEAWAYS

  • LLMs generate text by repeatedly predicting the next token.
  • Their behaviour comes from billions of learned parameters, not written rules.
  • Pretraining builds general knowledge; human feedback turns the model into a helpful assistant.
  • Transformers and attention let models use context across long passages of text.

‍

FAQ

WHAT IS A LARGE LANGUAGE MODEL?

An AI model trained on large amounts of text to predict and generate language. It powers chatbots such as ChatGPT and Claude.

WHAT IS A TOKEN?

A small unit of text, often a word or part of a word, that a language model reads and generates.

WHAT IS A TRANSFORMER IN AI?

The neural network architecture behind modern LLMs, built around an attention mechanism that relates each word to its context.

WHY DO LLMS SOMETIMES GIVE WRONG ANSWERS?

They generate likely-sounding text based on patterns, not verified facts, so they can produce confident but incorrect statements.

 

REFERENCES