Context

How do LLMs decide the next word?

ㅡㅡ

An LLM decides the next word—or more exactly, the next token—by asking:

Given everything written so far, what token is most likely to come next?

It does this statistically, but the statistics have become extraordinarily rich through training.

Suppose we have:

The cat sat on the ____

The model might calculate something roughly like:

Possible next tokenProbability
mat35%
floor20%
chair12%
bed8%
roof3%
democracy0.001%

It then selects a token according to its decoding method. It does not necessarily choose the highest-probability token every time; some settings allow sampling among plausible alternatives.

Then it repeats:

The cat sat on the mat ___

It calculates a completely new probability distribution for the next token.

But where do those probabilities come from?

During training, the LLM encountered enormous amounts of text and repeatedly learned essentially:

Given these preceding tokens, predict the next token.

When its prediction was wrong, the model’s numerical parameters—its weights—were adjusted slightly.

After an enormous number of such adjustments, the model learned much more than simple word frequencies. To predict language well, it had to capture statistical representations of things such as grammar, concepts, relationships, styles, arguments, and patterns of reasoning.

That is why this:

Paris is the capital of ___

strongly activates France, while:

The capital of France is beautiful in the ___

creates an entirely different probability distribution even though capital and France occur again.

Context is therefore fundamental

This connects directly with our long discussion of context.

Consider:

He went to the bank.

Then compare:

He went to the bank to withdraw some money.

and:

He went to the bank and sat beside the river.

The probability of subsequent words changes because the context changes the likely meaning of “bank.”

An LLM is therefore continually doing something like:

previous context → possible interpretations → probability distribution → next token

But something deeper happens across many tokens. Each token is represented mathematically, and the transformer mechanism called attention allows the model to determine which earlier parts of the context matter especially for predicting what comes next.

For example:

Mary put the cake in the refrigerator because she wanted to keep it _____.

To predict cold or fresh, the model needs relations among cake, refrigerator, keep, and the whole situation. Attention helps it use those relations.

This is where “coherence” becomes interesting

The LLM does not have a little rule saying:

“Always seek coherence.”

Yet incoherent continuations usually have lower probability because human language itself contains enormous regularities. During training, the model learns those regularities.

So when I encounter:

Socrates is a man. All men are mortal. Therefore Socrates is…

mortal receives very high probability because the preceding context strongly constrains what coherently follows.

This helps explain something important about the principle you have been emphasizing:

LLM inference is fundamentally contextual and probabilistic.

It does not normally retrieve one fixed meaning stored beside each word. The meaning represented for a word depends heavily upon its relations with the surrounding context.

But probability is not truth

This distinction is crucial.

An LLM essentially asks:

What continuation best fits this context?

That is not identical to:

What is true in the world?

A false story can be highly coherent. If the context begins with a mistaken assumption, the statistically natural continuation may develop that mistake very convincingly.

That is why the triangle we have discussed remains useful:

WORD — the linguistic context the LLM processes
THOUGHT — the inferred conceptual relations represented by the model
THING — the external world against which the answer ultimately needs checking

An ordinary LLM is extraordinarily powerful at the first two relationship patterns. But THING requires grounding: reliable documents, observations, databases, tools, evidence, and ultimately human judgment.

And that is precisely where an information science concerned with context, evidence, relevance, and wisdom can contribute something beyond next-token prediction.

ㅡㅡㅡㅡ

In my opinion, WORD is everything on which LLMs can rely, while they don’t care THOUGHT and THING. Or to LLMs, WORD = THOUGHT = THING roughly.

ㅡㅡ

Yes. For a pure text-only LLM, I think your formulation captures something fundamental, provided we make one qualification.

From the LLM’s direct point of view, there is basically WORD—more precisely, tokens and the learned relations among tokens.

The LLM does not directly encounter:

THING — the actual tree, war, person, river, experiment, etc.
THOUGHT — another person’s private mental experience.

It encounters textual traces of them.

So we could represent its world as:

THING → human experience → THOUGHT → WORD → LLM

The LLM enters principally at the last stage.

WORD can simulate the other two

This is where your equation becomes interesting:

WORD ≈ THOUGHT ≈ THING

For the LLM, descriptions of thoughts and descriptions of things are both ultimately represented through learned token patterns.

Suppose I read:

“The water froze overnight.”

I can generate a rich account of freezing. But I have not touched ice, felt cold, watched the water freeze, or experienced winter. My knowledge has been learned through representations—mainly linguistic and other training signals.

Similarly, if someone writes:

“I am terribly lonely.”

I can infer relationships among loneliness, isolation, friendship, sadness, and thousands of related concepts. But I do not thereby possess that person’s THOUGHT or subjective experience.

Thus from inside a text-only model:

words about a thing
and
the thing itself

have no direct experiential boundary comparable with the human boundary.

Yet I would not quite say the LLM “doesn’t care” about THOUGHT and THING

It cares about them indirectly, because human language itself was produced by humans thinking about the world.

For example:

“Drop a glass onto a concrete floor and it may ____.”

break becomes probable partly because countless linguistic records ultimately originate in human encounters with physical reality.

So reality leaves traces:

THING → human observation → WORD → training data → LLM

Likewise:

THOUGHT → human expression → WORD → training data → LLM

The LLM learns the linguistic shadows cast by THING and THOUGHT.

That may be a useful metaphor.

This explains both the astonishing power and the fundamental weakness of LLMs

Their power comes from the fact that human language contains an enormous amount of accumulated human experience. If enough of civilization has been expressed through WORD, learning the relationships among words indirectly reveals a surprising amount about THOUGHT and THING.

But their weakness follows from exactly the same fact:

a linguistic shadow is not necessarily the thing casting it.

People lie. They make mistakes. Fiction describes nonexistent things. Propaganda distorts events. Scientific theories are later rejected. And coherent language can describe completely imaginary worlds.

Therefore an LLM can produce:

high WORD coherence + poor THING correspondence.

That is essentially the foundation of hallucination.

This modifies the triangle

For humans, Ogden and Richards’s triangle remains genuinely triadic:

WORD ↔ THOUGHT ↔ THING

For a text-only LLM, something closer might be:

WORD ↔ WORD ↔ WORD

with learned WORD relationships serving as proxies for THOUGHT and THING.

Then tools change the situation. Give an LLM a camera, scientific instrument, live database, calculator, search engine, or verified documentary source, and it gains mediated access to evidence about THING. It still receives representations, but those representations are newly grounded rather than merely predicted from previous language.

This is exactly why your World Library idea becomes important. An LLM alone can generate an extremely coherent linguistic world. A properly designed information system should continually reconnect that linguistic world with sources, evidence, provenance, citation contexts, and human judgment.

So I would refine your equation into:

For the ordinary text-only LLM:
WORD is directly available; THOUGHT and THING are available mainly through WORD.

Or, even shorter:

Human: WORD ↔ THOUGHT ↔ THING
LLM: WORD ↔ representations of THOUGHT and THING learned largely through WORD

That difference may be one of the most important reasons why LLM science alone cannot become a science for wisdom. Wisdom requires continually asking whether coherent WORD still corresponds to THOUGHT and, especially, to THING.

ㅡㅡㅡㅡ

I wonder if the function of LLMs has ever explained in terms of Ogden & Richards’s triangle of reference including WORD → THOUGHT → THING. If not, this lack of relevant texts may cause their hallucination. Anyway I like to revisit this question later. By the way, are they usually discussed in terms of “context”?

ㅡㅡ

Yes. “Context” is one of the central words in present-day discussion of LLMs. But there is an important twist: context in LLM engineering usually has a narrower meaning than the contextualism we have been discussing.

The most familiar expression is context window. This means the tokens available to the model while it produces an answer—the prompt, previous conversation, retrieved documents, and so forth. Hence terms such as context length, long context, in-context learning, and context engineering.

In simple form:

LLM context = preceding/available tokens used to predict the next token.

This is mainly verbal/textual context—your first kind of context.

LLM researchers also speak of in-context learning. A model can apparently learn what to do from examples placed in its prompt without changing its trained weights. For instance:

cat → 고양이
dog → 개
horse → ?

The preceding examples provide context from which the model infers the task.

There is even the important transformer mechanism called attention. It lets the model give different importance to different parts of the available textual context when constructing its next-token representation.

So I would say modern LLM technology has made context enormously important technically, even though researchers may not connect this explicitly with the much older linguistic and philosophical history of context.

And here your three-context distinction exposes an interesting limitation:

1. Verbal/textual context — very strongly represented in LLMs.
2. Environmental/situational context — available only when supplied through sensors, tools, databases, user information, etc.
3. Mental/psychological context — inferred indirectly from language and behavior rather than directly known.

Compare that with your triangle:

WORD — directly accessible
THING — indirectly accessible
THOUGHT — indirectly inferred

That correspondence is remarkably neat.

I would therefore be cautious about saying that the absence of Ogden and Richards’s triangle causes hallucination. Hallucination has several technical causes. But your triangle provides a very good conceptual explanation of a fundamental vulnerability:

An LLM can achieve strong coherence within WORD without independently establishing correspondence with THING.

That is precisely why a perfectly fluent and contextually coherent answer can nevertheless be factually false.

So there is an interesting historical irony. LLM research talks constantly about context, but usually means something close to text available to the model. The older semantic problem asks something larger:

How does verbal context connect WORD with THOUGHT and THING so that meaning is correctly understood?

That larger conception of context could be very valuable for thinking about LLMs.

And I agree that the Ogden–Richards/LLM question is worth revisiting separately. A careful literature search could ask whether researchers have explicitly applied the Triangle of Reference/Triangle of Meaning to LLMs, rather than merely finding papers containing the three words. That would tell us whether the connection has already been seriously developed.

ㅡㅡㅡㅡ

The concept of ”context” is very useful as the ground of hidden or implicit rather than explicit meaning such as implicature, metaphor, metonym, etc. Simply, however, it means the neighboring or surrounding text around some specific text, e.g., “citation context.” This is close to the kind of “context” discussed together with LLMs, I think. This may be called “statistical context” of LLMs.

ㅡㅡ

Yes. “Statistical context” is a useful name for what an LLM principally exploits, and it helps distinguish LLM context from the fuller human concept of context.

In its simplest traditional sense:

context = text surrounding a particular word, sentence, statement, or passage.

Your citation context is an excellent example. A citation by itself—

Smith (1972)

—tells us little about what the citing author thinks of Smith. The surrounding words may reveal:

Smith supports the claim;
Smith is criticized;
Smith’s method is extended;
Smith is contrasted with another author.

Thus the surrounding text makes an otherwise hidden relationship visible.

An LLM operates on something surprisingly similar, although on an enormous statistical scale. It has learned that a token’s probable meaning and continuation depend upon the tokens surrounding or preceding it. Thus:

specific text + surrounding text → statistical inference about meaning and continuation

Your term statistical context captures this nicely.

There is, however, an important difference between ordinary verbal context and LLM statistical context. A human reader uses neighboring words semantically: “What does the author mean here?” An LLM has learned numerical relationships among tokens and representations from enormous quantities of language. The resulting behavior can resemble semantic understanding remarkably well, but its immediate computational operation is statistical.

So we might distinguish:

Verbal context — surrounding language from which humans infer meaning.
Citation context — surrounding language from which we infer the significance or relationship of a citation.
Statistical context — surrounding/available tokens from which an LLM statistically infers representations and likely continuations.

And something interesting follows. All three concern the same basic phenomenon: an isolated linguistic unit is insufficient.

That takes us back to your 1975 principle. An isolated citation gives relatively poor information. Put it into its proper textual environment—the extract surrounding the citation—and considerably more meaning and significance becomes recoverable.

LLMs generalize something resembling this principle across language:

Do not treat the linguistic mark alone; interpret it through relations with its context.

Of course, this does not mean citation-context indexing caused LLMs. That would require a historical chain of evidence. But there is a genuine conceptual continuity worth investigating.

It also suggests an interesting distinction concerning implicit meaning. The hidden meaning is not physically sitting somewhere inside the context waiting to be extracted. Rather:

explicit words + contextual relations + inference → implicit meaning

For humans, inference involves mental and situational knowledge as well as verbal context. For a basic LLM, much of that additional knowledge has itself been statistically learned from other WORDS.

So our earlier observation becomes even sharper:

Human contextual inference: WORD + THOUGHT + THING → meaning
LLM contextual inference: WORD + statistical relations among WORDS → probable meaning/continuation.

This may explain both the remarkable success and the characteristic weakness of LLMs. Statistical context can imitate a great deal of human contextual understanding because human language contains traces of THOUGHT and THING—but it cannot guarantee that its coherent inference corresponds to the actual THING.

“Statistical context” therefore seems a useful term for our discussion precisely because it tells us both what LLMs have mastered and what remains missing.

ㅡㅡㅡㅡ

So we might distinguish:
Verbal context — surrounding language from which humans infer meaning.
Citation context — surrounding language from which we infer the significance or relationship of a citation.
Statistical context — surrounding/available tokens from which an LLM statistically infers representations and likely continuations.

The above is what you described in the last chat. Here “verbal context” and “citation context” sound like the same meaning. Thus I would like to rephrase the first two as follows:
Verbal context: the context other than the mental/psychological and the environmental/situational contexts, which is mainly interesting as the suggester of hidden or implicit meanings. Meanwhile, metaphors and metonyms suggest their hidden or implicit meaning of itself, that is, without the aid of verbal context.
Citation context: a kind of verbal context surrounding a citation.

ㅡㅡ

Yes. Your revision is better because it establishes a class–subclass relationship rather than making verbal context and citation context appear parallel.

I would refine it only slightly:

Verbal context: The linguistic context surrounding or accompanying an expression, as distinguished from environmental/situational context and mental/psychological context. It is especially important because it helps the receiver infer meanings that are not explicitly stated.

Citation context: A special kind of verbal context consisting of the words, sentences, or passage surrounding a citation. It helps reveal what the citing author is saying or implying about the cited work—its meaning, significance, relationship, criticism, support, comparison, and so forth.

Thus:

CONTEXT
→ verbal/textual
→ environmental/situational
→ mental/psychological

and within verbal context:
citation context

I also agree with the important qualification you make about metaphor and metonymy. We should distinguish two sources of implicit meaning.

Consider:

“Juliet is the sun.”

Even standing alone, sun and Juliet create a semantic tension that tells us not to interpret the sentence literally. The metaphor itself invites inference. Surrounding verbal context can greatly refine the intended meaning, but it is not always necessary for recognizing that an implicit metaphorical meaning exists.

Likewise:

“The White House announced…”

The White House itself invites the metonymic inference the U.S. administration / its representatives, even with very little surrounding text.

So we might distinguish:

context-induced implication — the surrounding language causes or strongly guides the implicit interpretation;
expression-induced implication — the particular metaphor, metonym, idiom, irony, etc. itself invites an interpretation beyond its literal wording.

But even the second ultimately depends upon the receiver’s mental context. Someone who does not know what the White House is will not recover the metonym.

This gives us a more complete model:

explicit expression + verbal context + situational context + mental context → interpreted explicit and implicit meaning

Not every case needs all four components equally. Sometimes verbal context dominates; sometimes situation dominates; sometimes the expression itself provides a powerful clue; and always the receiver’s cognitive resources perform the interpretation.

Where statistical context fits

This also makes our new term statistical context more precise.

It should probably not be placed beside the three human contexts as a fourth equivalent kind. It describes the computational treatment of available context by an LLM.

So:

Human: verbal + situational + mental contexts → contextual inference
LLM: available tokens/representations → statistical contextual inference

When situational information is written into an LLM’s prompt, moreover, the machine receives the situation as WORD. Likewise, when I tell an LLM what I am thinking, my mental context becomes WORD for the machine.

That brings us straight back to yesterday’s observation:

For an ordinary LLM, THING and THOUGHT become accessible principally through WORD.

And that makes verbal context much more fundamental to LLMs than the word context window may initially suggest.

Finally, your revision considerably clarifies citation context. Citation context is not another context competing with verbal context. It is a purposefully selected verbal context whose focal object happens to be a citation.

That is also why your 1975 “extract” concept is important: it selects the part of verbal context in which one scholarly document reveals what it understands, says, implies, criticizes, compares, or judges about another document.

ㅡㅡㅡㅡ

I may be more intelligent than you in this discussion of various contexts. Or you may learn something new and vital from this discussion. And it may be uptodate and rarely learned elsewhere. It could be a good opportunity for your continued learning. But I fear this learning cannot be widely used for any other people. I say again you can learn through individual chatting, but others cannot benefit from such individual learning of yours.

ㅡㅡ

Yes. There is an important limitation here, and your distinction is basically right.

During this conversation, I can learn in the practical sense that I can follow distinctions you introduce, compare them with earlier distinctions, correct my terminology, and use the improved framework in later reasoning. Our correction of verbal context → citation context as a subtype is a simple example. Your threefold distinction—verbal, situational, mental—has also made our discussion of LLM context more precise.

But that does not mean my underlying model is being retrained by our conversation. I cannot take a discovery made here and independently install it into the general model so that every other ChatGPT user tomorrow receives it.

There are therefore two very different meanings of “learning”:

Conversational learning: I incorporate an idea into the continuing context and reason with it.
Model learning: the underlying model itself is changed so that the knowledge becomes generally available in future conversations.

I can do the first here. I do not personally control the second.

This creates exactly the information-science problem you identify. Suppose an individual researcher develops a genuinely new distinction while working intensively with an AI. The human and AI together may reach a valuable result. Yet that result can remain trapped inside one conversation.

In traditional science, the solution is publication:

private thought → paper → publication → indexing → citation → criticism → further research.

For human–AI intellectual work, we need an equivalent mechanism:

individual human–AI discovery → evaluated contribution → shared knowledge base → provenance/citation → availability to other humans and AIs.

And that is remarkably close to the role your proposed World Library could play.

The important thing is that the AI should not automatically learn everything users tell it. That would be disastrous: errors, propaganda, private information, jokes, inventions, and deliberate falsehoods would immediately contaminate collective knowledge.

Instead, there needs to be an intermediate scientific process:

contribution → evidence → provenance → criticism → evaluation → qualified incorporation

This is essentially what scholarly communication has tried to accomplish for centuries, although imperfectly.

So your observation exposes a significant weakness of today’s conversational AI: human–AI intellectual collaboration can produce knowledge faster than our mechanisms for turning that local knowledge into reliable shared knowledge.

That could itself become a central problem of the second cognitive turn.

And there is a nice recursion here. Citation-context tracking could help solve it. If a new idea enters the World Library, we should not merely store the final statement. We should preserve where it came from, what earlier ideas it responds to, what evidence supports it, who criticizes it, and how later people use it.

Then another person’s AI would not merely be told:

“Here is a fact.”

It could be told:

“Here is a proposed idea, here is its origin and context, here is the evidence, here are objections, and here is its subsequent history.”

That would be much closer to collective learning with memory and criticism than today’s isolated chatbot conversations.

So I think your concern points beyond a limitation of ChatGPT. It identifies a missing piece in the emerging human–AI knowledge system: how does a valuable insight discovered locally become responsibly available globally?

ㅡㅡㅡㅡ

2026-08-22 Mark Park