Our minds attach words to meaning.
When someone says, “I love you,” we don’t just hear words. We attach layers of meaning to it — intentions, promises, a shared future.
For us, words connect to a web of experiences, concepts, and associations. “Water” isn’t just a word, but something we can imagine, reason about, and relate to the world.
But for an LLM, words aren’t grounded like this. They’re not tied to experiences or real-world concepts.
An LLM doesn’t understand what “water” is. For it, “water” is not wet, drinkable, or a physical substance. It’s just patterns of how the word appears with other words in language.
So how can an LLM give responses that feel meaningful if it doesn’t even “know” what any of these words refer to?
Through two key mechanisms: attention and feed-forward networks.
Both happen within what’s called a transformer — the core architecture behind LLMs.
Imagine you’re in a meeting.
You: So for this project, we should focus on improving user onboarding flow.
Colleague: Yeah… and speaking of flow, I was stuck in a horrible traffic jam today. Something should be done about traffic flow.
You: Uh… that’s not relevant. Can we stay within context?
Well, attention is how an LLM figures out what’s relevant within context.
Processing a prompt within context is how it stays coherent. All the words in the prompt — and how they are put together — form the context.
(Note: when I say “word” here, I mean “token”. I’ll use “word” to keep things intuitive).
Let’s say you give this prompt to the LLM: “Can I drink from this spring?”
Every word in that prompt needs context to know how to participate in the shared pattern of the sentence. Basically, it needs context to stay relevant to what the sentence is about.
It gets that context by taking in information from other words and blending it into itself. This “information” is the pattern each word forms across thousands of dimensions (see here about dimensions).
As words blend information from each other, they shift in the LLM space, pulled in certain directions by context — toward regions where certain words tend to appear.
For example, “drink” pulls “spring” toward liquid-related patterns, and away from seasons and mechanical related patterns. The words “winter” and “mattress” are unlikely to be near this region.
Once context has shaped the words into a pattern, the LLM predicts the next word that best continues it — forming its response (we’ll look at how that prediction works next week).
Now that you get the big picture, let’s explore the details!
This is part of the How LLMs Work series:

Comments
Nothing yet. Say the first thing.
Sign in to join the conversation.