liveBook · Manning

Value

As explained in Rearchitecting LLMs

A value is a vector containing the semantic information that attention aggregates from tokens selected by query-key compatibility.

In attention, a value (V) vector carries a token’s semantic information. Query–key compatibility determines how much of each token’s value contributes to the current token’s enriched embedding. section 3.1.2

“Spring” in a sentence

For “Fresh water flows from the mountain spring daily,” the query for “spring” compares with the keys of other tokens. The resulting weights determine how much each token’s value contributes to “spring”’s context. section 3.1.2

Figure 3.4 Attention mechanism for the token "spring." The Query (Q) from "spring" compares with the Keys (K) of all tokens through dot product operations. The resulting scores, after softmax normalization, determine what fraction of each Value (V) contributes to create the enriched embedding.

Diagram of how query–key scores determine each value’s contribution. section 3.1.2

How Rearchitecting LLMs covers it

How deep it goes
Defines the value’s semantic role and explains its weighting through query–key dot products and softmax scores.
Examples
Uses “spring” seeking context from “mountain” in a sentence about fresh water.
What you can do after
Understand how attention weights select value information to enrich a token embedding.
How it connects
Links values to queries, keys, attention, and multi-head attention.

Also explained in

Compare how 2 books explain value →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Rearchitecting LLMs. The section links point to the parts of the book it draws on.