T2 · Beginner · 8 minMoving · Last reviewed: 2026-08-17Early draft

What Is an LLM?

In one line · An LLM is a model trained on huge text to predict the next word — and from that prediction, coherent language emerges.

Glossary:Context WindowLLMTemperatureTokenTransformer
TL;DR

The LLM (Large Language Model) is the heart of every AI product you'll build. Its core job is simple — predict the next token — yet at scale it's astonishing.

Why it matters

Everything ahead — prompting, RAG, agents — is a way to steer the LLM. Understand it and the rest gets easy.

An LLM is like a colleague who read half the internet and completes any sentence you start with the most plausible continuation. It completes patterns, it doesn't think like you.

An analogy

Like your phone keyboard's next-word suggestion — but millions of times smarter, tracking whole paragraphs of context.

Type 'The capital of Egypt is' and the LLM predicts 'Cairo' — the most likely continuation from its training.

How it works

It splits text into tokens, scores each possible next token, picks one, and repeats. The context window is the most tokens it can see at once.

For developers

Architecturally LLMs are built on the Transformer. You don't need the math — just: text in, text out, controlled via the prompt and parameters like temperature.

Practice

🧪 Try it: give any LLM a half sentence and watch it complete it. Change the last word and see the prediction shift.

Common mistakes

Common mistake: treating the LLM as a reliable fact source. It's a source of plausible language; truth isn't guaranteed — hence RAG later.

When to use it

Use an LLM for any language task: summarizing, classifying, answering, generating, reformatting.

When NOT to use it

Don't rely on it alone for exact calculations or sensitive facts without a trusted source alongside.

LET'S BUILD ITDone reading — now build it yourself.Build a Chat App on an LLM