What's new? Trends Large Language Models, Briefly Explained

Large Language Models, Briefly Explained

Large Language Models, Briefly Explained (3Blue1Brown)

A quick picture of what LLMs do

Picture a short screenplay. You see the person’s line—“Can you summarize this article?”—but the AI’s reply has been torn off. Now imagine a machine that, given any text, can say which word is most likely to come next. Feed it the screenplay, let it pick the next word, then the next, and so on. You get a full answer where there used to be nothing.

That’s the core of a large language model (LLM). It’s not magic. It’s a mathematical function that, for any string of words, assigns a probability to every possible word that could follow. Chatbots wrap this prediction game inside a friendly interface so it feels like a conversation—because in a sense, it really is just one long, carefully guided autocomplete.

Illustration of a script with a missing AI response and a next-word prediction

From a torn‑off script to a chatbot reply

How do you turn that prediction machine into a helpful assistant? You start by giving it a little stage direction. The system prepends text that frames the interaction—something like “You are a helpful AI assistant.” Then it appends what you type. The model then predicts what a helpful assistant would say next, one token at a time, and keeps going until it’s done.

Because the model produces a full probability distribution over possible next words, the software running it can choose words in a couple of ways. It can always pick the most likely one, or it can randomly sample from the top options so the response feels more natural and less robotic. That sampling step is why the same prompt can yield different answers across runs.

Chat-style prompt and assistant setup showing user input and model continuation

Why answers vary: probabilities and sampling

Under the hood, the model is deterministic: same inputs, same internal numbers. But many chat apps intentionally add randomness during generation. They might sample from the top few likely words rather than always grabbing #1. This tiny bit of randomness makes replies feel human—varied, sometimes surprisingly creative—rather than stitched from a fixed template.

You’ll sometimes see a “temperature” knob in developer settings. Higher temperature puts more weight on lower-probability words, increasing variety at the cost of reliability. Lower temperature hugs the safest guesses. The video’s point is simpler, though: selecting less likely words at random, here and there, tends to make language flow.

Probability bars over candidate next words, highlighting random sampling

What it takes to train one

So where do these probabilities come from? Training data—an enormous amount of it. 3Blue1Brown gives a striking comparison: for a typical person to read the volume of text used to train GPT‑3, nonstop, 24/7, it would take more than 2,600 years. And that was then; newer models use much more.

The model learns by seeing text and practicing the next‑word prediction task over and over. With every example, it compares the word it predicted to the true last word from that snippet. If it was wrong, the model tweaks its internal dials slightly to nudge the probabilities in a better direction next time.

Scale comparison visual for training data volume comparable to thousands of years of reading

Parameters: the dials you tune

Those internal dials are called parameters or weights. A modern LLM has a breathtaking number of them—often in the hundreds of billions. No human sets these by hand. They start out random, which means the early model spits out gibberish. Then the training loop begins. With every example, an algorithm called backpropagation computes how to nudge each dial to slightly increase the chance of the true next word and slightly decrease the chance of the others.

Do this trillions of times across the dataset, and the model slowly shifts from nonsense to recognizable language, then to surprisingly good language, and finally to language that carries structure, style, and context. It doesn’t memorize every sentence it’s seen; it learns statistical patterns that generalize to new text. That generalization is the special sauce.

How learning actually happens (backprop in one paragraph)

Here’s the training step in concrete terms. Take a span of text—maybe a handful of words, maybe thousands. Feed the model all but the last word. It outputs a probability distribution over the vocabulary for what it thinks that last word should be. Compare that prediction to the real last word. Then use backpropagation to adjust the weights so next time, the real last word becomes a little more likely. Rinse, repeat, trillions of times.

As 3Blue1Brown points out, this process not only makes the model better on the training data, it also improves predictions on text it has never seen before. That’s the hallmark of learning rather than rote memorization.

Diagram showing input text, predicted last word, and backpropagation adjustments

The sheer compute involved

How hard is all this computation? Try this thought experiment from the video. Suppose you could do one billion additions/multiplications every second. How long would it take to run all the operations needed to train the largest language models? A year? Ten thousand years?

The punchline is sobering: well over 100 million years at that speed. The only reason training is feasible is parallelism—running enormous numbers of operations at once on specialized chips designed for throughput.

Back-of-the-envelope compute estimate illustrating 100+ million years of work

Beyond autocomplete: making models helpful with RLHF

Predicting the next word from internet text is pre‑training. It teaches language, style, and facts-in-the-aggregate. But that objective isn’t the same as being a safe, helpful assistant. To close the gap, many chatbots go through reinforcement learning with human feedback (RLHF). People review outputs, flag unhelpful or problematic ones, and their preferences guide another round of training that shifts the model toward responses users prefer.

This second stage doesn’t rewrite the whole model; it nudges it. Still, those nudges matter a lot. They bias the model toward clear, helpful answers, refusals when needed, and generally better alignment with how we want assistants to behave.

Human feedback loop diagram showing reviewers influencing model outputs

Hardware matters: GPUs and parallelism

All of this training only works at modern scales because of GPUs—chips built to do huge numbers of simple math operations in parallel. Before 2017, many language models processed text mostly one token at a time, limiting how much could be parallelized. Then came a shift.

In 2017, researchers at Google introduced the transformer architecture. Unlike earlier designs, transformers “soak in” a block of text in parallel. That design choice made much more efficient use of GPU hardware—and kicked off today’s LLM boom.

Parallel processing illustration contrasting sequential models and transformers

Inside a transformer: embeddings, attention, and feed‑forward layers

Step 1: Turn words into numbers

Transformers start by mapping each token (word or subword) to a long list of numbers, called an embedding. Why? Because learning happens with continuous values. These vectors act as a compact numerical stand‑in for meaning and usage.

Step 2: Let tokens “talk” via attention

The signature move is attention. Each token’s vector looks at the others and decides which ones matter for its current meaning, adjusting itself based on context—all in parallel. If the sentence mentions “bank” near “river,” the representation of “bank” shifts toward riverbank, not a financial bank. That context sensitivity is where a lot of the magic lives.

Step 3: Add capacity with feed‑forward networks

After attention refines context, a feed‑forward neural network processes each token’s vector, letting the model store and transform richer patterns learned during training. Stacking many layers of attention + feed‑forward lets the model capture deeper and deeper structure.

At a high level, the transformer keeps enriching these vectors so that, by the end, the information needed to predict the next word is packed into the final position’s vector.

Transformer block diagram with embeddings, attention, and feed-forward layers

From vectors to an actual next word

Once the stack of layers has done its work, the model applies one last function to the vector at the end of the sequence. That produces a probability for every possible next token. Software then samples from that distribution—often leaning toward more likely words, but with a touch of randomness—to produce the next token. Append it to the text, repeat, and you get a full response.

Crucially, the model’s designers choose the framework—the architecture, the flow of operations—but not the specific behavior. The behavior emerges from how those hundreds of billions of parameters get tuned during training. That’s why these systems can be hard to interpret, even for their creators.

Final layer turning a vector into a probability distribution over the vocabulary

What we still don’t fully understand

Even with clean diagrams, it’s tough to point to any single weight or neuron and say, “This is why the model answered that way.” The overall behavior is an emergent result of many parts interacting. Researchers can study patterns, visualize attention, and probe how information flows, but pinning down exact causes for specific sentences remains an open challenge.

What we can say is that when you use an LLM to autocomplete a prompt thoughtfully, the results can be startlingly fluent—and often useful. The combination of scale, attention, and human feedback gets you most of the way to the assistant experience we’ve come to expect.

How to use this knowledge day to day

If you think “this is just autocomplete,” you’ll actually get better at prompting. Give the model the start of the answer you want: specify role, style, and constraints. You’re shaping the probability space it samples from.

  • Be explicit about the role (“You are a careful proofreader…”). The prefix matters.
  • Prefer examples over vague instructions. Show the pattern you want.
  • If results feel too random, reduce creativity by asking for bullet points or setting a low‑variety tone (“be concise and factual”).
  • If it’s too stiff, encourage alternatives (“give two varied takes”). Variety often comes from sampling.

Remember, the model is best at next‑token prediction with rich context. Your job is to give it that context.

Common questions

Is a large language model just autocomplete?

At its core, yes: it predicts the next token given prior tokens. But scale, the transformer architecture, and human feedback layers make its autocomplete strikingly capable and adaptable.

Why do I get different answers to the same prompt?

Most chat systems sample from the model’s probability distribution rather than always taking the single most likely word. That randomness produces varied (and often more natural) outputs.

What is “attention,” in plain terms?

Attention lets each token look at the rest of the sentence and decide which parts are most relevant to refine its meaning. It’s how the model uses context, and it runs in parallel across tokens.

Wrapping up

3Blue1Brown’s short tour gives a clean mental model: an LLM is a next‑word predictor trained on vast text, tuned via backprop, scaled with GPUs, guided by transformers and attention, and finally steered with human feedback to be more useful. Keep that picture in mind as you write prompts. You’re not commanding a database—you’re setting up the first few steps of a path the model will likely follow. Nudge it well, and it will usually take you somewhere good.

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

Порядок навколо — спокій всередині: практичний погляд на оренду мийки високого тискуПорядок навколо — спокій всередині: практичний погляд на оренду мийки високого тиску

У часи невизначеності прості побутові речі набувають нового значення. Наведення ладу вдома, у дворі чи в гаражі перестає бути просто прибиранням. Це стає способом повернути собі відчуття контролю, відволіктися від