AI Learning Courses
AI Learning Courses › Tutorials › Tutorial 11
AI TUTORIAL 11 · 9 MIN READ

What is an LLM (large language model)? Explained simply, with examples

ChatGPT, Gemini and Claude are all LLMs. Learn what a large language model is, how it writes an answer word by word, how it is trained, what it is great at, where it fails, and how to use one wisely.

Turn on JavaScript to watch the animated lesson. The full tutorial text is below.

What is an LLM? Watch

An LLM, or large language model, is an AI trained on a huge amount of text so it can understand and write language. You talk to one every time you use ChatGPT (OpenAI), Gemini (Google), Claude (Anthropic) or Llama (Meta).

Its core skill sounds simple: given some text, it predicts the most likely next word. Do that again and again, very well, and you get essays, emails, code and answers.

How an LLM answers you, step by step Watch

Your prompt is cut into tokens, the transformer works out which words matter, and the model picks the next token - again and again.
Your prompt is cut into tokens, the transformer works out which words matter, and the model picks the next token - again and again.
  1. Prompt: you type a question, like "What is the capital of India?"
  2. Tokens: the text is cut into small pieces called tokens. In English, one token is about three quarters of a word.
  3. Transformer: a neural network uses "attention" to see which words matter most to each other.
  4. Next token: it gives every possible next token a score and picks a likely one, such as "New".
  5. Repeat: "New" is added, and it predicts again: "Delhi". That is why answers appear word by word.

Why is it called large? Watch

Because of its size. An LLM has billions of parameters: numbers that get adjusted during training, a bit like the strength of connections in a brain. GPT-3, released in 2020, had 175 billion parameters. It is trained on books, websites and code, using thousands of powerful chips for weeks.

How an LLM is trained Watch

First it learns language from huge text, then it is fine-tuned with human feedback to be helpful and safe.
First it learns language from huge text, then it is fine-tuned with human feedback to be helpful and safe.

What LLMs are great at Watch

Where LLMs go wrong Watch

ProblemWhat it meansWhat you do
HallucinationIt can invent facts or sources and sound sureCheck names, numbers and links
Old knowledgeIt knows only what was in its training data, unless it can search the webAsk for sources, or use web search
Maths slipsIt predicts words, so long calculations can go wrongAsk it to show steps, or use a calculator
BiasIt can repeat unfair patterns from its dataQuestion one-sided answers

Try it yourself Watch

Explain what a large language model is to a 12-year-old in India,
with one cricket example. Use 5 short bullet points.

Lesson learned Watch

An LLM is a super-fast next-word predictor trained on huge text. Brilliant for drafts and explanations, but always check important facts.

Frequently asked questions

What is the full form of LLM?

LLM stands for large language model: an AI trained on huge amounts of text to understand and write language.

Is ChatGPT an LLM?

Yes. ChatGPT is an app built on OpenAI's GPT large language models. Gemini, Claude and Llama are other LLMs.

Does an LLM understand like a human?

Not in the human sense. It learns patterns in language very well and predicts likely words, which can look like understanding, but it can still be confidently wrong.