Label Words are Anchors: An Information Flow Perspective for Understanding In-Context Learning
Paper · 2023 · Lean Wang, Lei Li, Damai Dai et al.
Summary
A classification prompt usually shows a system several examples before asking it to label a new input. Each example contains some text and its answer: a review followed by a sentiment label, for example. The system receives the examples as context, without an ordinary training update. Yet this leaves a basic question unanswered: which parts of those examples carry the information that actually shapes the next prediction? “Label Words are Anchors” investigates that question by following interactions between token positions inside the computation.
The paper argues that demonstration labels have a more substantial role than merely naming the available answers. Their internal representations become collection points for information from preceding text. Later computation draws on those representations when deciding how to classify the new input. The authors call these positions anchors. Their main evidence comes from GPT2-XL, with 1.5B parameters, and GPT-J, with 6B parameters, evaluated on sentiment, question type, news topic, and emotion classification. An additional experiment examines semantically unrelated labels with LLaMA-33B.
The authors begin with a gradient-based analysis of attention: the mechanism through which one token position reads information from another. They compare the importance of interactions entering demonstration labels, interactions connecting those labels to the prediction position, and other interactions. Early computation emphasizes the first route; later computation emphasizes the second. They then test the interpretation more directly. Preventing label positions from reading preceding text has a particularly strong effect when the restriction applies near the input. Separately, attention directed toward demonstration labels becomes a useful predictor of the system’s eventual answer in later layers. These findings support an account in which information is first gathered at labels and subsequently consulted there.
The paper develops practical uses for this account. Anchor re-weighting learns small adjustments to the influence of demonstration labels, reporting an average accuracy improvement of 16.7% against standard in-context learning. A compression method preserves internal states at labels and formatting positions rather than retaining complete demonstrations during subsequent inference. The authors report an average acceleration of 1.8×, with individual settings ranging from 1.1× to 2.9×. For GPT-J, they describe an accuracy reduction of 1.5 under compression relative to the uncompressed condition. Finally, distances between label-associated key vectors help identify difficult category pairs on TREC, including Description–Entity. These applications strengthen the case that anchor representations contain useful task information, while the classification setting limits how widely the explanation can be extended.
Interesting ideas
Look for intermediate collection points. A long input need not remain equally important at every stage of computation. Some positions may accumulate information that later processing can access more economically. The reusable idea is to search for where useful information gathers, instead of assuming that every source token must remain directly accessible. This can guide both interpretability and efficient processing and compression. The paper’s labels are one concrete example of such collection points, rather than evidence that labels must be the relevant positions in every task.
Separate gathering from use. A representation can matter because information enters it early, because another position reads it later, or because both occur. The paper makes these roles experimentally distinguishable. Its early-layer restriction tests whether label positions need access to preceding text, while its later-layer analysis asks whether attention towards those positions tracks the final answer. This distinction is useful whenever an explanation involves an intermediate representation: showing that something contains information is different from showing when that information is acquired and how it affects a decision.
Pair visual patterns with controlled changes. An attention visualization can suggest an interesting route without establishing its functional importance. The authors therefore use the visualization to formulate a hypothesis, then change selected interactions and observe the result. Their non-label controls also ask whether the effect is specific to labels. Researchers can reuse this progression from observation to comparison to intervention when studying other internal structures. It gives an attractive diagram a more demanding test than visual plausibility alone.
Preserve the task interface during compression. The successful compression method keeps formatting states alongside label states. Labels alone proved insufficient: without the contextual cues that establish the expected answer type, predictions could drift toward ordinary vocabulary. This suggests a useful distinction between information about an example’s meaning and information about how the task is presented. A compressed representation may need both. The idea applies wherever reducing content risks removing the structural cues that tell a system what kind of response to produce.
Spend supervision on a small, targeted adjustment. Anchor re-weighting uses extra labeled examples to train attention multipliers instead of placing all those examples in the prompt. Its appeal comes from matching the intervention to an observed mechanism: if demonstration information is concentrated at labels, adjusting access to those labels may be productive. This is a reusable design principle for adaptation under limited resources. First locate a narrow computational pathway with evidence behind it; then test whether a small learned change there can use supervision effectively.
Measure behavioral fidelity separately from correctness. The paper evaluates compression and isolation partly through loyalty: how closely the altered system follows the original system’s outputs. Classification accuracy answers a different question, namely whether either output is right. Keeping these measures separate is useful for compression, approximation, and debugging. An alteration can preserve an incorrect answer, change a correct answer, or improve correctness while changing behavior. Agreement alone cannot distinguish those cases.
Interpret distances through the queries that use them. For error diagnosis, the authors do not rely only on unadjusted distances between label keys. They emphasize directions in which target-position queries vary, then compare keys in that query-sensitive space. The broader idea is that a representation’s geometry should be assessed relative to the computation that reads it. A distinction between vectors matters most when downstream operations are sensitive to that distinction.
Deep dive: Label Words are Anchors: An Information Flow Perspective for Understanding In-Context Learning
How label words organize information during in-context learning, and what anchor re-weighting, compression, and error analysis reveal. · about 39 minutes to read
How Mova uses it
For Mova, the small transparent language system written in Rust, the paper is most useful as a set of design and testing ideas. There is no basis for claiming that its anchor mechanism, attention interventions, or compression method is already implemented in Mova. A concrete connection therefore begins with what could be made explicit: where a demonstration’s content is represented, where its label is represented, and which of those representations a classification decision actually consults.
A possible experiment would give Mova labeled examples and record the intermediate structures that connect each example with its category. If Mova represents examples and labels separately, it could expose the operation that associates them. That would make the proposed analogue of an anchor inspectable. The important requirement is a real computational role: a category name becomes relevant to this paper’s idea when it carries information from an example and that information subsequently affects a decision. Merely storing the category name beside the example would establish much less.
The early-versus-late distinction offers a particularly useful way to organize such an experiment. Mova could distinguish construction of a demonstration representation from consultation of that representation for a new input. Removing access to example content during construction would test whether the stored representation depends on that content. Removing access during consultation would test which stored information the final decision requires. These would be conceptual counterparts of the paper’s interventions, with implementation determined by Mova’s own architecture.
Compression is another plausible application. A transparent system could retain an explicit compact record for each demonstrated class while avoiding repeated processing of the full example text. The paper gives a reason to test this approach, but does not establish that a particular Mova record would preserve enough information. A careful comparison would examine correctness, agreement with the uncompressed system, and processing cost. It would also retain the task structure needed to interpret the compact records. The failure of label-only compression in the paper warns that a short representation can lose the expected output format even when it retains apparent category information.
Anchor re-weighting suggests a separate possibility: use a small labeled development set to adjust the influence of class-associated records. In the paper, the learned quantities multiply selected attention entries. Mova would need an independently defined equivalent, such as explicit weights on the evidence supplied by demonstrations. Such weights should remain inspectable, and their effect should be evaluated against using the same labeled examples directly. Calling them anchor weights would be justified only if the weighted records played the gathering-and-consultation role established by the experiment.
Error diagnosis could also benefit from an explicit comparison between category representations. If Mova has a meaningful feature space for demonstrated classes, closely positioned representations might help explain recurring confusions. The paper’s query-sensitive treatment is relevant here: distance should reflect how classification actually uses those features. Without that connection, a distance display could look explanatory while measuring distinctions the decision procedure barely uses.
These are proposals for Mova, not reported outcomes. Their common value is methodological. The paper shows how a claim about internal organization can be turned into observable comparisons, selective restrictions, a compact representation, and an error analysis. A transparent implementation could make each of those steps easier to inspect, while still needing its own evidence that the proposed mechanism operates.
The problem and its context
What happens between examples and an answer?
In-context learning allows a language model to perform a task from examples placed in its input. An example supplies both an input and the response associated with it. A new input follows, and the system predicts its answer by continuing the sequence. The attraction is that this use of examples does not require updating the system’s underlying parameters for each task. The examples themselves supply the immediate context for behavior.
The paper places this capability in the line of work represented by Language Models are Few-Shot Learners. It also notes applications to text classification and mathematical reasoning. Those applications demonstrate useful behavior, but successful behavior does not by itself explain the computation that produces it. A prompt can contain a great deal of text, several answer labels, formatting cues, and the input requiring classification. Their respective roles need to be disentangled.
A review-classification example makes the question concrete. The review contains evidence about sentiment. Its label identifies the class associated with that evidence. Formatting distinguishes the review from its answer and indicates where a new answer should appear. The system might consult review tokens directly throughout processing, or it might construct an intermediate representation that later computation uses. The paper investigates whether demonstration label positions serve that intermediate role.
This matters because an explanation of the information route can support interventions that a description of the prompt alone would not suggest. If label states contain useful summaries of examples, preserving those states might reduce the amount of context needed later. If different labels receive inappropriate influence, targeted re-weighting might improve predictions. If some label representations are difficult to distinguish, their geometry might help explain classification errors.
What earlier work had examined
The authors distinguish research on external influences from research on internal mechanisms. The first group changes properties of the prompt and measures the effect. Relevant properties include example order, formatting, and the choice of demonstrations. Rethinking the Role of Demonstrations is part of this discussion, as is What Makes Good In-Context Examples for GPT-3?. These studies motivate taking prompt construction seriously as an experimental variable.
Other work sought performance improvements through demonstration construction and calibration. The paper cites Calibrate Before Use when discussing preferences and instabilities that can affect predictions. It also places Noisy Channel Language Model Prompting among approaches relevant to classification and calibration. In this context, adding examples is not automatically equivalent to adding reliable evidence. Their wording, arrangement, and interaction with existing preferences can matter.
The second group offers conceptual explanations of the learning process. An Explanation of In-context Learning as Implicit Bayesian Inference supplies one such perspective. Another compares the computation to gradient descent, as in Transformers Learn In-context by Gradient Descent and Why Can GPT Learn In-Context?. The anchor paper introduces a different observational focus: which token positions exchange task-relevant information as processing advances.
These perspectives need not be mutually exclusive. A description in terms of information routes addresses a different level of explanation from an analogy to an inference or optimization procedure. The paper’s distinctive move is to identify a particular kind of position—the demonstrated answer label—and test its role across computational depth. Its practical applications depend on that positional account.
Why attention needs more than a picture
The architecture under study uses transformer attention to combine information across token positions. A position can read from earlier positions, with attention values controlling the contribution of different sources. This makes attention a natural place to inspect how demonstration content might reach a label and how that label might influence the target position.
However, a large attention value does not automatically identify the most consequential interaction. The paper therefore combines attention with a gradient: a measure of the task loss’s sensitivity to changes in the attention entries. Its use of saliency follows the interpretive tradition associated with Deep Inside Convolutional Networks, while the attention-based approximation draws on the practice cited through Are Sixteen Heads Really Better than One?.
The authors also acknowledge that attention weights are only part of the computation, citing Attention Is Not Only a Weight. Their later correlation analysis uses a ranking-based measure partly because attention magnitudes and output probabilities need not share the same numerical scale. This is an important restraint: the paper tests whether an internal attention pattern predicts a decision, instead of assuming that the pattern already is the final probability distribution.
The method, step by step
The investigation proceeds from a proposed information route to selective tests and then to applications. First, the authors mark demonstration labels and the final input position. Next, they measure the importance of different attention routes across layers. They test whether incoming attention is necessary for label representations to acquire useful information, and whether later attention towards those representations tracks the eventual answer. Finally, they use the anchor account to motivate re-weighting, compression, and error diagnosis.
From demonstration labels to anchor applications
The steps in order.
Define the positions being studied
Let the input contain demonstration labels at positions p₁ through p_C. Here C counts the label positions being considered. In the main setup, each class has a demonstrated example, making the relationship between a position and its class straightforward. The target position q is the final position of the input, from which the next answer token will be predicted.
This distinction avoids a possible misunderstanding. The target position is not a label token that has already been generated. It is the position whose internal representation supports prediction of that token. Likewise, a demonstration label is an existing token position inside the context. Its state has already been affected by earlier computation and may contain more than the lexical meaning of its written label.
The paper generally treats a label word as a label token. The exception is TREC’s Abbreviation label, for which the experiments use the first sub-word. That detail matters because the measurements and restrictions operate on token positions. A written category name and its tokenized representation are not always identical objects.
The authors use shallow to mean close to the input and deep to mean closer to the output. Their usage of deep can include the middle portion of the computation: for GPT2-XL, they give layers 25-48 within its 48-layer architecture as an example. The hypothesis concerns a changing computational role across depth, instead of a requirement that only the final layer consult labels.
Calculate attention saliency
For every layer, the authors combine attention entries with the gradient of the task loss with respect to those entries:
I_l = |Σ_h A_(h,l) ⊙ ∂ℒ(x)/∂A_(h,l)|
I_l is the saliency matrix for layer l. A_(h,l) denotes that layer’s attention matrix for head h, and the summation combines heads. The input is x, while ℒ(x) is its task loss, such as cross-entropy for classification. The symbol ∂ indicates a partial derivative. The operation ⊙ multiplies corresponding matrix entries. Absolute-value bars are applied entry by entry after the head contributions are combined.
An entry I_l(i,j) measures the estimated importance of the interaction through which position i reads position j. Information therefore runs from j towards i in this notation. The measure is based on local sensitivity of the task loss. It is an importance estimate, rather than a literal count of semantic information moving between positions.
The authors also report a similar pattern when absolute values are taken before combining heads:
I_l = Σ_h |A_(h,l) ⊙ ∂ℒ(x)/∂A_(h,l)|
The symbols retain the same meanings. The difference is the order of operations: contributions with opposite signs can interact before the absolute value in the main expression, whereas the alternative first makes each head’s contribution non-negative. Similar findings under this change provide a limited check that the observed pattern is not peculiar to that aggregation choice.
Separate the attention routes
The first route contains interactions entering a label from earlier positions:
C_wp = {(p_k, j) : k ∈ [1,C], j < p_k}
C_wp is the set of destination–source pairs for this route. The index k selects a label position p_k, and j selects a preceding position. The condition j < p_k respects the direction allowed by the autoregressive architecture.
The definition is broader than a manually isolated span containing only the associated example’s content. It includes positions preceding the label. This is relevant when interpreting the term aggregation: the metric measures the specified incoming interactions, without assigning every source token to a uniquely bounded demonstration.
The mean saliency on that route is:
S_wp = Σ_((i,j)∈C_wp) I_l(i,j) / |C_wp|
S_wp measures average interaction importance for the chosen route at layer l. The summation adds its saliency entries, and |C_wp| is the number of included entries. Dividing by the set size allows comparison with routes containing different numbers of interactions.
The second route connects demonstration labels with the target:
C_pq = {(q, p_k) : k ∈ [1,C]}
C_pq contains the interactions in which target position q reads one of the label positions p_k. Its average saliency is:
S_pq = Σ_((i,j)∈C_pq) I_l(i,j) / |C_pq|
S_pq is therefore the mean estimated importance of consulting demonstration labels from the prediction position. As before, I_l supplies the interaction scores, and the denominator counts the included entries.
The comparison route contains the remaining forward interactions:
C_ww = {(i,j) : j < i} ∖ C_wp ∖ C_pq
C_ww starts with destination–source pairs permitted by the earlier-to-later direction and removes the pairs already assigned to C_wp and C_pq. The symbol ∖ means set exclusion.
Its mean score is:
S_ww = Σ_((i,j)∈C_ww) I_l(i,j) / |C_ww|
S_ww supplies a reference for interactions outside the proposed anchor routes. It does not imply that the remaining tokens lack information. The comparison asks whether interactions involving labels have unusually high average saliency.
Together, these measures make the hypothesis testable across layers. A large S_wp early in processing is consistent with labels collecting useful context. A large S_pq later is consistent with the target consulting the resulting representations. Comparing each with S_ww helps determine whether the pattern is distinctive relative to the remaining interactions.
Restrict incoming attention to labels
The shallow-layer experiment changes the computation rather than merely observing it. For selected layers, the authors remove incoming attention from preceding positions to a label:
A_l(p,i) = 0, for i < p
A_l is the attention matrix at layer l, p is a label position, and i ranges over earlier positions. The value 0 blocks those particular interactions. This prevents that label position from reading preceding text through attention in the selected layers.
The authors compare restrictions near the beginning and near the end of processing. They also restrict randomly selected non-label positions as a control. That control asks whether the effect reflects the special role of labels or simply the disruption of some token positions.
The main outcomes are behavioral agreement measures. Label loyalty records whether the predicted label remains the same after intervention. Word loyalty compares sets of top-5 vocabulary predictions using Jaccard similarity. Jaccard similarity measures overlap relative to the combined set, allowing the analysis to detect changes beyond the leading class label.
These measures serve different purposes. A classification decision may remain unchanged while the surrounding distribution shifts substantially. Conversely, a small change near a decision boundary can alter the leading label. Using both loyalty measures makes the intervention’s effect more visible.
Relate target attention to the final answer
For each layer, the authors sum attention across heads and inspect the target’s attention towards label positions. They treat those attention scores as predictors of the system’s eventual output class and evaluate that prediction with AUC-ROC.
This is an agreement analysis between an internal signal and the final output. The final output supplies the class to be predicted by the attention signal. Ground-truth task labels do not define the target of this particular analysis. High AUC-ROC therefore shows alignment with the system’s choice, including choices that may be incorrect.
The authors prefer AUC-ROC in part because constant scaling need not preserve equality between attention values and output probabilities. They also want a measure less disturbed by uneven frequencies of predicted labels. When demonstrations are repeated for a class, attention towards that class’s label occurrences is summed.
They define an additional cumulative measure:
R_l = Σ_(i=1)^l (AUCROC_i − 0.5) / Σ_(i=1)^N (AUCROC_i − 0.5)
R_l summarizes the share accumulated through layer l. AUCROC_i is the attention-to-output discrimination score for layer i. The reference 0.5 is subtracted before accumulation. N denotes the total number of layers in this expression.
The measure is motivated by residual computation, through which later states incorporate effects of earlier processing. It provides a depth profile of the measured association. It should be read as the paper’s cumulative summary, rather than a direct experimental decomposition of the final answer into independent causal percentages.
Turn attention toward labels into a classifier analogy
The re-weighting method begins with an approximation connecting output class probability and attention to its demonstration label:
Pr_f(Y=i | X=x) ≈ A(q,p_i) = exp(q_q k_(p_i)ᵀ / √d) / Σ_(j=1)^N exp(q_q k_jᵀ / √d)
Pr_f denotes probability under the conceptual classifier f. X is its input variable, x is a particular input, Y is the class variable, and i selects a class. A(q,p_i) is attention from target position q to label position p_i. The query vector at q is q_q, the label’s key vector is k_(p_i), and ᵀ indicates transposition. The dimension used for attention scaling is d. The function exp exponentiates a score.
Here N indexes token positions included in the attention denominator, instead of the layers indexed by N in the cumulative measure. The approximation sign matters: an attention probability over token positions is being related to a class probability. The paper uses the relationship to motivate a targeted intervention, not to establish exact equality of the complete prediction process.
The next step expresses relative attention to a class against a reference class C:
log(Pr_f(Y=i | X=x) / Pr_f(Y=C | X=x)) = β_iᵀ x̂
The logarithm acts on the probability ratio. The feature vector x̂ is q_q divided by √d. The vector β_i is the difference between key k_(p_i) and reference key k_(p_C). Thus the relative score becomes a linear function of the transformed query.
The authors compare this form with logistic regression:
log(Pr_f(Y=i | X=x) / Pr_f(Y=C | X=x)) = β₀ⁱ + β_iᵀ x
The term β₀ⁱ is a class-specific intercept, β_i is a coefficient vector, and x is the input feature vector in this regression expression. The important addition is the intercept. It suggests a way to adjust relative class influence without changing all of the underlying representations.
The resulting anchor adjustment is:
Â(q,p_i) = exp(β₀ⁱ) A(q,p_i)
 is the modified attention entry. The learned scalar β₀ⁱ controls a positive multiplier through exp. Each relevant head and layer has its own parameter. This makes the intervention more specific than a single final-output bias shared across the whole computation.
Implement and train the re-weighting
The ordinary attention matrix is computed as:
A_lʰ = softmax(QKᵀ / √d)
A_lʰ is the attention matrix for head h in layer l. Q and K contain query and key vectors, respectively. The softmax converts scaled compatibility scores into attention weights, and d is the scaling dimension.
The authors then modify selected entries:
Â_lʰ(k,j) = exp(β_(0,lh)ⁱ) A_lʰ(k,j) if k=q and j=p_i; otherwise Â_lʰ(k,j) = A_lʰ(k,j)
The row index k identifies the destination and j the source. Only entries connecting target q with label position p_i receive the learned multiplier. β_(0,lh)ⁱ identifies the parameter for label i, layer l, and head h. All other entries retain their original values.
The head output becomes:
Attention_lʰ(Q,K,V) = Â_lʰ V
V contains the value vectors combined by attention. The modified attention matrix Â_lʰ determines their contribution. The implementation multiplies selected entries after softmax; the stated procedure does not add another normalization step.
The parameters are trained with an auxiliary labeled set:
β★ = argmin_β ℒ(X_train,Y_train)
β is the collection of learned re-weighting parameters, and β★ denotes the optimizing choice. X_train and Y_train are auxiliary inputs and their labels. The loss ℒ depends on predictions made using β, even though that dependence is not written as an additional argument.
For each class, the procedure uses one ordinary demonstration and four additional labeled examples for auxiliary training. The demonstrations remain fixed within a seed. The authors use Adam, with learning rate 0.01, β₁ set to 0.9, and β₂ set to 0.999. Memory constraints lead to batch size 1. Training runs for 10 epochs. This application is evaluated with GPT2-XL because of computational limits.
Cache the internal states that matter
The compression application starts from the architecture’s autoregressive direction. A demonstration label’s representation can depend on earlier text, but cannot depend on a target input that appears later. The label states can therefore be computed before processing subsequent target inputs.
The paper writes the cached collection as:
H = {{h_lⁱ}_(i=1)^C}_(l=1)^N
H contains hidden states across label positions and layers. The vector h_lⁱ is the state of label occurrence i at layer l. C counts the stored label occurrences, and N is the layer count.
During inference, these states are supplied at their respective layers in place of the complete demonstrations. However, the implemented successful method also retains states associated with formatting. The authors call it Hidden_anchor.
That qualification is central. Preliminary label-state-only compression could lose the expected answer type and favor common vocabulary such as “the.” The retained formatting includes elements such as “Review:” and “Sentiment:”. The method therefore preserves contextualized class information and cues about the task’s input–output structure.
Compare category keys in a query-sensitive space
The error analysis asks why some labels receive similar attention. Attention depends on compatibility between the target query and each label key. Similar keys can yield similar scores, making corresponding categories harder to distinguish.
The authors adapt the comparison to the distribution of target queries. They first center the observed query vectors:
Q̂ = (q₁ − q̄, …, q_T − q̄)
Q̂ collects centered queries. The vector q_t comes from target position t among the sampled inputs, T is the number of such queries, and q̄ is their mean. Centering removes the common average before identifying directions of variation.
They select directions of maximal variance, subject to orthogonality:
v_i = argmax_(‖v‖=1, v ⟂ v₁,…,v_(i−1)) Var{vᵀ Q̂}
v_i is the next selected direction. The candidate v must have unit norm, indicated by ‖v‖=1, and must be perpendicular to previously selected directions. Var measures variance of the projected centered queries. For the first direction, there are no earlier directions imposing an orthogonality constraint.
The scale associated with each direction is:
σ_i = √Var{v_iᵀ Q̂}
σ_i is the standard deviation of query projections onto direction v_i. The transformed key feature is then:
k̂_i = σ_i v_iᵀ k
k is an original label key, and k̂_i is its feature along the selected direction. Multiplication by σ_i gives greater emphasis to directions with more query variation. Collecting these features yields the transformed vector k̂.
Finally, the predicted pairwise confusion score is:
Confusion_ij^pred = ‖k̂_(p_i) − k̂_(p_j)‖ / max_(s≠t) ‖k̂_(p_s) − k̂_(p_t)‖
The numerator measures distance between transformed keys for labels i and j. The denominator is the largest distance among distinct label pairs, indexed by s and t. The norm supplies the distance. The normalization places the score on the paper’s 0-1 scale.
In spite of the name, a smaller score indicates greater predicted confusion. The empirical comparison uses pairwise AUC-ROC from actual output probabilities: retain test examples belonging to the selected category pair, normalize their probabilities within that pair, and evaluate discrimination. Values closer to 1 indicate less confusion there as well.
Experiments and results
Tasks, systems, and evaluation conditions
The main investigation covers SST-2, TREC, AGNews, and EmoC. These supply distinct classification settings: sentiment, question category, news topic, and emotion. The paper’s dataset references include Learning Question Classifiers, Character-level Convolutional Networks for Text Classification, and EmoContext. This variety tests whether the proposed label role appears across different kinds of class meaning.
GPT2-XL is the primary system because its 1.5B parameter size fits the authors’ resources while supporting useful in-context behavior. GPT-J, with 6B parameters, extends the main intervention and correlation analyses. The usual evaluation description specifies 1000 sampled test inputs, with a demonstration for each class drawn from training data. Reported averages generally use five random seeds, fixed to 42, 43, 44, 45, and 46.
The local descriptions distinguish some experiments more narrowly. The intervention setup describes fixed demonstrations for a single seed, while the saliency and re-weighting discussions explicitly refer to averages across seeds. The error-diagnosis study has its own setting: GPT2-XL on all 500 TREC test examples, with 1 demonstrated example per class. These conditions should be retained when comparing findings across the paper.
The authors identify an official implementation accompanying the research and say that supplementary code supports replication of experiments and analyses. The paper also supplies demonstration templates and additional experimental details in its appendix. These materials matter because both the prompt structure and the location of label tokens are part of what is being measured.
Information routes change with depth
The saliency comparisons show a consistent qualitative pattern. Early layers have relatively strong S_wp, the route into label positions. Later layers give greater prominence to S_pq, the route connecting demonstration labels with the target. Both label-related routes generally exceed the average saliency of the remaining interactions.
The main discussion illustrates this pattern on SST-2 and AGNews, while the appendix reports similar behavior for TREC and EmoC. The agreement across tasks supports the claim that the observed organization is not confined to a single sentiment example.
These are comparisons of mean interaction saliency. They do not establish that every label-related edge is important or that other tokens cease to contribute. Their value is that the hypothesized gathering and consultation phases correspond to a recurring pattern in the measured attention interactions.
The separate attention-to-output analysis provides a numerical summary. In deeper layers, AUC-ROC approaches 0.8 when attention towards label positions is used to predict the eventual output class. The reported curves are averaged across the classification datasets for GPT2-XL and GPT-J.
Label-attention prediction of output class, averaged across SST-2, TREC, AGNews, and EmoC
Deep-layer attention distinguishes the eventual output label above the reference level.
The numbers
| System or setting | AUC-ROC |
|---|---|
| Reference level used in the cumulative measure | 0.5 |
| Deep-layer label attention, reported approximation (this paper) | 0.8 |
The reference row is the baseline used in the cumulative formula, instead of a measured competing system. The deep-layer value is the paper’s approximate characterization of the curves. It should not be interpreted as classification accuracy or as an identical score reached by every layer and dataset.
R_l adds a complementary depth profile. Little of the cumulative above-reference association appears in shallow processing, while middle and later layers account for most of its increase. That pattern is consistent with labels being prepared before their representations become strongly associated with the final decision.
Accuracy after anchor re-weighting
The re-weighting experiment compares the learned adjustment with ordinary in-context learning using the same demonstration set. It also compares against ordinary prompting that includes the auxiliary training examples as additional demonstrations. This second baseline is important because the new method receives extra labeled data.
The standard conditions are described as 1-shot per class for the smaller demonstration set and 5-shot per class when the auxiliary examples are placed in context. For AGNews, the paper notes a length restriction and uses three demonstrations per class in the larger-context comparison.
The authors report an average accuracy boost of 16.7% over standard in-context baselines. They describe particularly substantial improvements for SST-2 and EmoC and report the re-weighting method as the best overall option in the comparison. The aggregate percentage should be kept in that reported form: the narrative does not establish an alternative interpretation as an absolute percentage-point change.
A useful finding is that directly adding examples does not produce a consistently stable gain. The paper connects this with possible noise and calibration issues. Re-weighting uses the additional examples differently: they train the influence multipliers, while inference retains the shorter demonstration context.
The authors describe almost no additional inference-speed cost from this adjustment. That claim concerns use after training. Learning the multipliers still requires the auxiliary optimization procedure, including repeated processing of its labeled examples.
Compression quality and efficiency
The compression comparison evaluates Hidden_anchor against alternatives designed to separate contextualized information from token identity. Text_anchor retains formatting and label text without the contextualized states. Hidden_random preserves formatting states and an equal number of randomly selected non-label states. Hidden_random-top selects the highest-label-loyalty result from 20 randomly chosen non-label sets.
The authors assess classification accuracy, label loyalty, and word loyalty. Hidden_anchor leads the compression comparisons across the reported metrics for GPT2-XL and GPT-J. This combination of measures matters: the method is evaluated both for correctness and for its ability to preserve the original behavior.
For GPT-J, the narrative reports an accuracy reduction of 1.5 compared with the uncompressed condition. The statement describes a loss relative to full-context inference; it is not a final accuracy value. The paper treats the reduction as small, but the importance of such a change would depend on the intended application.
The reported average speedup is 1.8×. Across settings, acceleration ranges from 1.1× to 2.9×, and the authors observe larger gains for GPT-J. They also connect efficiency with demonstration length relative to the target input length. AGNews, which has the longest demonstrations among the analyzed datasets, yields the highest acceleration in their discussion.
The result establishes an efficiency–fidelity tradeoff under these conditions. It does not make every prompt equally compressible. The amount of removable demonstration context and the architecture’s processing costs both affect the practical outcome.
Diagnosing confused categories
The error analysis compares query-sensitive anchor distances with pairwise discrimination on TREC. Its empirical target is not a conventional count of mistaken labels alone. Instead, it uses output probabilities for each selected category pair and evaluates their ability to distinguish the true classes through AUC-ROC.
The distance-based analysis identifies Description–Entity as the most difficult pair. It also reflects substantial confusion involving Entity–Abbreviation and Description–Abbreviation. The paper presents this correspondence through heatmaps instead of supplying a single numerical correlation coefficient in the narrative.
This result gives the anchor account an explanatory application beyond average accuracy. Similar class-associated keys can make attention scores similar for a range of target queries. The observed correspondence supports that route as a possible source of errors, without establishing it as the cause of every mistaken classification.
What the ablations show
Restricting labels early has a distinctive effect
The central controlled comparison changes both the affected positions and the affected depth. The authors restrict attention entering label positions in the first 5 layers, compare this with restriction in the last 5 layers, and include randomly selected non-label positions.
The strongest disruption occurs when demonstration labels lose incoming attention near the beginning. Comparable restriction late in processing has much less effect, as does restriction at random non-label positions. This supports the claim that labels acquire useful information early, rather than only serving as final lexical answer options.
The controls narrow the interpretation. The non-label comparison argues against treating any arbitrary restricted position as equally consequential. The late-layer comparison argues against an account in which labels must gather their information afresh at every stage. The result instead fits a representation that becomes useful after earlier processing has already constructed it.
The principal measures here are loyalty scores. A decline in loyalty means that the system’s predictions change relative to unrestricted computation. It should not automatically be described as an equal-sized decline in classification accuracy. The intervention demonstrates behavioral dependence on the restricted route, with the exact relationship to correctness requiring a separate measure.
The result persists across restriction depths
The appendix varies how many layers receive the restriction. Early label isolation remains disruptive, while late isolation has relatively little effect even as the selected range expands.
This matters because a comparison involving only the first and last 5 layers could be sensitive to that particular choice. Varying the range shows that the qualitative conclusion is not tied solely to those endpoints. It supports a broader difference between early information acquisition and later use.
The analysis does not locate an exact universal boundary at which acquisition finishes. The saliency profiles and cumulative attention relationships vary over depth rather than identifying a single mandatory transition layer. The evidence supports a phase-like organization, with more gathering early and more consultation later.
More demonstrations preserve the main pattern
The authors repeat the analysis with two examples per class. The resulting demonstration totals are 4 for SST-2, 12 for TREC, 8 for AGNews, and 8 for EmoC. They report saliency, isolation, and attention-to-output patterns resembling those from the smaller contexts.
This comparison addresses whether the main result depends on a particularly sparse prompt. Repeating classes introduces multiple label occurrences and more preceding content, yet the broad gathering-and-consultation account remains useful.
For the attention correlation calculation, the paper sums attention over occurrences belonging to the same class. This detail preserves the intended class-level interpretation. A target may distribute attention across repeated demonstrations without changing which class the combined signal favors.
The finding should be kept within the tested increase. It does not show that the same behavior remains stable under arbitrarily long demonstration sequences or every possible arrangement of examples.
Unrelated labels test the role of lexical meaning
Meaningful labels already supply clues about a classification task. A sentiment label, for example, has an ordinary semantic association with the class. The authors therefore investigate whether labels can still act as anchors when their written forms are unrelated to the task categories.
GPT2-XL and GPT-J perform near random guessing under the semantically unrelated setting considered by the authors. They consequently use LLaMA in its LLaMA-33B configuration for an SST-2 experiment. The class labels become “A” and “B,” with eight demonstrations per class. The reported SST-2 accuracy is 83.0%.
Within that setting, restricting early access to labels has a more pronounced effect than late restriction or non-label restriction. Later-layer label attention also remains associated with the final prediction. This supports a positional and contextual role for anchors that goes beyond the ordinary meaning of a sentiment word.
The experiment changes the system and demonstration count alongside the label scheme. It therefore supplies evidence that the mechanism can appear with unrelated labels under those conditions. It does not establish that label semantics never matter, or that every system can learn arbitrary label mappings equally well.
The paper connects this question with Larger Language Models Do In-context Learning Differently. The important controlled feature is the replacement of semantically meaningful class names, while the surrounding experimental conditions remain essential to interpreting success.
Contextualized states outperform the label text alone
Text_anchor is a revealing compression baseline because it retains recognizable labels and formatting. If those strings alone explained the compressed method’s success, there would be less reason to preserve their internal states from the full demonstration.
Hidden_anchor performs better. The result supports the claim that the states contain useful information acquired while processing the examples. The labels act as carriers of context-dependent representations, rather than merely reminders of which words may be output.
The random-state baselines test whether a similarly sized selection of internal states would work equally well. Their weaker performance supports the relative usefulness of anchor locations. Hidden_random-top makes this comparison more demanding by selecting the best label-loyalty outcome among 20 random sets.
This remains a comparison against the specified random-selection procedures. It does not prove that no other compact state selection could outperform anchors. The paper identifies an effective and interpretable choice, rather than exhausting the space of compression strategies.
Formatting is part of the successful representation
The unsuccessful label-state-only attempt is a substantive ablation. It shows that retaining states presumed to carry example meaning can still lose information needed to produce the right kind of output.
Formatting cues help establish the task interface: which text is an input, which text is an answer, and what should follow at the target position. Preserving those cues alongside anchors restores an important part of the contextual setup.
This limits an overly strong reading of the title. The useful computational bottleneck is not demonstrated to consist exclusively of labels. The practical method depends on labels together with retained structure. The paper’s account is strongest when it acknowledges that class evidence and output-format evidence serve related but distinguishable functions.
Error diagnosis is stable across projection sizes
The distance analysis varies the number of query-variation directions used to transform label keys. The appendix compares M = 5,10,20,50,100,200 and reports broadly similar predicted confusion patterns. The chosen setting is M=10.
Here M counts selected directions, rather than examples or attention heads. Similar outcomes under different projection sizes suggest that the visible category relationships are not determined by one narrow dimensionality choice.
The evidence remains qualitative. The paper shows comparable confusion patterns, but does not establish invariance of every pairwise score. Nor does projection stability turn an association between representation distance and confusion into a causal intervention on errors.
Limitations
The authors’ stated limits
The authors explicitly limit their investigation to classification. The setup offers a small set of label candidates and a clearly identifiable position where a class is predicted. Generative tasks can require extended outputs whose useful intermediate positions are less obvious. The paper does not establish that demonstration labels provide the same organizing structure there.
They also state that conventional in-context learning is the principal setting. Chain-of-Thought Prompting falls outside the tested mechanism. A sequence containing intermediate reasoning introduces additional candidate representations and interactions, so the classification findings cannot simply be transferred to it.
Hardware limits are another explicit constraint. GPT2-XL and GPT-J supply most of the evidence, and the authors call for replication at larger scales. The appendix’s LLaMA-33B experiment extends the scope in a specific way, but it is not a full repetition of all analyses and applications with that system.
The practical applications have narrower coverage than the main hypothesis tests. Anchor re-weighting is evaluated with GPT2-XL, while the error-diagnosis application focuses on GPT2-XL and TREC. Compression is studied with both principal systems. These differences matter when deciding which findings have cross-system support.
Limits visible in the measurement design
A careful reader should distinguish saliency from a direct measurement of semantic content. The saliency score depends on attention, task loss, and a local gradient approximation. A high value indicates estimated task sensitivity at that interaction. It does not independently reveal which fact, phrase, or semantic feature has been encoded.
Likewise, mean saliency across a route compresses variation among its individual interactions. A route can have a high mean without every edge being equally important. The comparison is useful for identifying a recurring organizational pattern, but less specific about which source tokens supply which aspects of an example.
The label-isolation intervention establishes a stronger functional relationship, because selected attention routes are actually changed. Even so, it is a substantial restriction that may disturb several aspects of computation at once. The result supports the importance of early access at labels; it does not reconstruct the precise content acquired there.
The deep-layer AUC-ROC analysis is correlational. Its target is the system’s own eventual class choice. Strong agreement shows that label attention is informative about that choice, instead of proving that it is the sole cause of the choice or that the choice is correct.
R_l should receive similar caution. It accumulates above-reference association scores across layers, motivated by residual processing. It is not obtained by independently removing each layer’s contribution and measuring a causal share of the final answer. Its value is descriptive: it summarizes where the association appears along depth.
Limits of the practical claims
The re-weighting method uses extra supervision. Its advantage cannot be described as an improvement obtained without additional labeled information. The comparison against putting those examples directly in context is therefore an essential part of the evaluation.
Re-weighting also introduces trainable parameters and an optimization stage. The underlying system is largely preserved, but the application is no longer ordinary prompting alone. Its low inference overhead does not eliminate training cost or the need to decide which auxiliary examples are representative.
The logistic-regression analogy is a motivation for the intervention. The full prediction procedure includes more than attention to a set of label keys, and the attention denominator includes token positions beyond those labels. The approximation helps explain why multiplicative adjustments might be useful; it is not a complete mathematical equivalence between in-context classification and logistic regression.
Compression depends on retaining formatting states. This prevents a strong conclusion that labels alone contain everything required from demonstrations. It also suggests that changing the prompt structure could change which non-label positions need to be preserved.
The speedup depends on context lengths and the amount of demonstration processing avoided. The reported acceleration range therefore belongs to the tested settings. It cannot be treated as a fixed multiplier for any input or architecture. Similarly, the reported GPT-J accuracy loss does not establish that every dataset loses the same amount.
Loyalty measures preserve a distinction that should remain visible in deployment decisions. A compressed system can faithfully reproduce an incorrect original answer. High loyalty is useful evidence about preservation of behavior, but correctness must still be evaluated separately.
Limits of the error explanation
The distance analysis offers a possible explanation for particular confusions. It does not show that changing the distance between anchors would necessarily repair those errors. That would require an intervention connecting a representation change with improved pairwise discrimination.
The predicted score also depends on observed query variation. It is therefore tied to how the system encounters the task distribution, rather than being a context-free property of written category names. A different distribution could emphasize different directions.
Finally, the heatmap correspondence is not reported as a numerical correlation coefficient in the narrative. The paper identifies convincing category pairs and visual agreement, but that evidence should not be strengthened into an unreported quantitative guarantee. The useful conclusion is that anchor geometry can support diagnosis, with further testing needed to establish a general error predictor.
What came after
The later citation record places the anchor idea among research on task representations, attention concentration, context compression, reasoning, and safety. A citation establishes that a later work refers to this paper. It does not on its own establish that the later method implements anchor re-weighting, uses the same compression procedure, or independently confirms the proposed mechanism. The connections below distinguish the subjects of those works from claims about a particular technical dependency.
From label positions to task representations
Function Vectors in Large Language Models brings the later discussion towards representations of task function. The conceptual connection is the possibility that task-relevant behavior can be associated with internal representations more compact than the complete demonstration sequence. The anchor paper provides a specific positional account of where useful information gathers. The title of the later work points towards a broader representation-level question, without establishing that its vectors are identical to label states.
Label Words as Local Task Vectors in In-Context Learning is especially close in subject. Its title explicitly combines label words with task vectors, making the relationship to anchors direct at the level of the research question. It invites examination of label representations as task-bearing objects. The citation alone does not determine how the later work defines locality, constructs a vector, or evaluates the connection.
Beyond Task-Level Context: Class-Conditional Context Vectors for Implicit In-Context Learning places class-specific representations at the center of its title. This is a natural direction to compare with anchors because the original study assigns demonstrated classes identifiable internal positions. The question becomes whether useful context should be represented globally for a task or separately for its classes. No particular equivalence between the later vectors and the paper’s cached states follows from the citation.
Task-Related In-Context Learning and Incomplete In-context Learning indicate further changes to the context-learning setting. For the anchor account, such work raises the question of what information must be present for class-associated representations to become useful. Their titles establish the topics, while leaving their precise relationship to the gathering-and-consultation hypothesis open.
Unraveling the Mechanics of Learning-Based Demonstration Selection for In-Context Learning returns to the choice of examples. The anchor perspective suggests a concrete way to think about selection: examples may matter partly through the representations they induce at later-consulted positions. That is a question the original study makes available for investigation, rather than a result that can automatically be attributed to the later work.
Compression and internal reuse
PyramidKV: Dynamic KV Cache Compression based on Pyramidal Information Funneling names an information-funneling account of cache compression. The shared engineering concern is whether retained internal state can be reduced while preserving useful computation. The anchor paper supports a particular selection criterion—demonstration labels together with formatting—whereas the later title identifies a different compression framework.
KV-Embedding: Training-free Text Embedding via Internal KV Re-routing in Decoder-only LLMs connects internal key–value routing with text representations. Its topic is relevant to the original paper’s distinction between visible label strings and contextualized internal states. Both make internal representations candidates for reuse, but the title does not establish that the later method uses labels as its routing destinations.
BubbleRAG: Interactive Cognitive Offloading with Thought Bubble in Retrieval-Augmented Generation identifies offloading as its concern. Compared with the anchor paper, the broad question is how information can be retained in a form that supports later processing without repeatedly carrying all of its original expression. That conceptual similarity should not be mistaken for evidence that thought bubbles implement anchor-state compression.
Attention concentration and multimodal settings
OPERA: Alleviating Hallucination in Multi-Modal Large Language Models via Over-Trust Penalty and Retrospection-Allocation places attention-related trust and allocation in a multimodal hallucination setting. The relevant connection is that concentrated influence can be worth diagnosing and modifying. The anchor study shows a beneficial concentration pattern for classification; it does not establish that every concentration of attention is useful.
Shallow Focus, Deep Fixes: Enhancing Shallow Layers Vision Attention Sinks to Alleviate Hallucination in LVLMs explicitly distinguishes shallow and deep processing in its title. This makes depth-dependent roles a clear point of comparison. However, a demonstration label carrying class information and a visual attention sink are different objects; their relationship requires evidence beyond a shared interest in attention and depth.
From Redundancy to Relevance: Information Flow in LVLMs Across Reasoning Tasks places information flow in a broader task and modality setting. Why Multimodal In-Context Learning Lags Behind? Unveiling the Inner Mechanisms and Bottlenecks similarly signals an investigation of mechanisms and bottlenecks. Both subjects extend beyond the original classification evidence, making them relevant to the limits the authors themselves identify.
Exploring Attention Attractors in Large Language Models names a neighboring phenomenon: positions that attract attention. The anchor account supplies an important distinction for such comparisons. Receiving attention is one observation; collecting task-relevant information and subsequently supporting a prediction is a more specific functional claim.
TokenPenalty: Alleviating Attention Sinks and Positional Decay in LVLMs and Latent Attention Denoising identify corrective interventions in attention-related behavior. Their titles suggest a useful contrast in research questions: when should concentrated influence be preserved, re-weighted, or suppressed? The original paper answers that question only for its tested anchor applications.
Two Pathways to Truthfulness: On the Intrinsic Encoding of LLM Hallucinations points toward internal explanations of truthful and untruthful output. The connection remains methodological: internal representations may help explain observed behavior, but a classification anchor study does not itself establish a mechanism of hallucination.
Reasoning, supervision, and behavioral control
Navigate through Enigmatic Labyrinth: A Survey of Chain of Thought Reasoning belongs to a reasoning setting that the anchor paper explicitly leaves unexplored. Feature Extraction and Steering for Enhanced Chain-of-Thought Reasoning and Beyond Examples: Towards Automated Thought-level In-Context Reasoning likewise name reasoning representations and interventions. They are relevant places to ask whether useful intermediate states can be identified and controlled, while the classification mechanism requires fresh validation there.
What Happened in LLMs Layers when Trained for Fast vs. Slow Thinking: A Gradient Perspective explicitly combines depth with gradient analysis. This makes it methodologically adjacent to the saliency portion of the anchor study. Its stated subject concerns differences associated with fast and slow thinking, rather than the specific flow between demonstration labels and a class prediction.
One-Shot Learning as Instruction Data Prospector for Large Language Models and Teaching Small Language Models Reasoning through Counterfactual Distillation concern different uses of examples and supervision. Their relevance is to the broader design choice illustrated by anchor re-weighting: labeled examples can support an auxiliary procedure rather than merely becoming a longer prompt. The listed titles do not establish that either later work adopts the paper’s attention multipliers.
Influences on LLM Calibration returns to calibration, loss functions, and prompt styles. This connects with the original paper’s caution that output preferences and example arrangement can complicate interpretation. MulDimIF addresses evaluation and improvement of instruction following, another setting where correctness, behavioral consistency, and internal diagnosis need to remain distinct.
Safety and broader synthesis
Intention Analysis Makes LLMs A Good Jailbreak Defender and Revisiting Jailbreaking for Large Language Models: A Representation Engineering Perspective place later citations in safety-related behavioral analysis. LED-Merging names safety–utility conflicts in merging, while On Safety Risks in Experience-Driven Self-Evolving Agents concerns experience-driven agents. These topics show the breadth of the citation neighborhood. They do not establish a safety application of label anchors.
Finally, A Survey on In-context Learning provides a broader framing for the field. The anchor paper’s contribution within that landscape is unusually concrete: it identifies a candidate internal route, measures its changing role across depth, restricts parts of that route, and tests applications suggested by the result. The later works span many different questions, but the reusable standard is the same: an internal explanation becomes more convincing when it supports selective experiments and useful predictions about behavior.
Institutions
Fields, topics and concepts
Shelves 4The field of science this work belongs to (OpenAlex fields).Computer Science · 19,503 worksArtificial Intelligence · 18,805 worksArts and Humanities · 17,959 worksLanguage and Linguistics · 17,789 works
Topics 1Research subjects and languages the work is about.Language models & pretraining · 4,145 works
Cite
Cite as Lean Wang, Lei Li, Damai Dai, Deli Chen, Hao Zhou, Fandong Meng, Jie Zhou and Xu Sun. 2023. Label Words are Anchors: An Information Flow Perspective for Understanding In-Context Learning. arXiv:2305.14160.
@misc{wang2023label,
title = {{Label Words are Anchors: An Information Flow Perspective for Understanding In-Context Learning}},
author = {Lean Wang, Lei Li, Damai Dai, Deli Chen, Hao Zhou, Fandong Meng, Jie Zhou and Xu Sun},
year = {2023},
doi = {10.48550/arxiv.2305.14160},
eprint = {2305.14160},
archivePrefix = {arXiv},
url = {https://doi.org/10.48550/arxiv.2305.14160}
}References
- Ekin Akyürek, Dale Schuurmans, Jacob Andreas, Tengyu Ma, and Denny Zhou. 2022. What learning algorithm is in-context learning? investigations with linear models (https://arxiv.org/abs/2211.15661). ArXiv preprint, abs/2211.15661. our card
- Tom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, and Dario Amodei. 2020. Language models are few-shot learners (https://proceedings.neurips.cc/paper/2020/hash/1457c0d6bfcb4967418bfb8ac142f64a-Abstract.html). In Advances in Neural Information Processing Systems 33: Annual Conference on Neural Information Processing Systems 2020, NeurIPS 2020, December 6-12, 2020, virtual. our card
- Ankush Chatterjee, Kedhar Nath Narahari, Meghana Joshi, and Puneet Agrawal. 2019. SemEval-2019 task 3: EmoContext contextual emotion detection in text (https://doi.org/10.18653/v1/S19-2005). In Proceedings of the 13th International Workshop on Semantic Evaluation, pages 39–48, Minneapolis, Minnesota, USA. Association for Computational Linguistics. our card
- Damai Dai, Yutao Sun, Li Dong, Yaru Hao, Zhifang Sui, and Furu Wei. 2022. Why can gpt learn in-context? language models secretly perform gradient descent as meta optimizers (https://arxiv.org/abs/2212.10559). ArXiv preprint, abs/2212.10559. our card
- Qingxiu Dong, Lei Li, Damai Dai, Ce Zheng, Zhiyong Wu, Baobao Chang, Xu Sun, Jingjing Xu, and Zhifang Sui. 2023. A survey for in-context learning (https://arxiv.org/abs/2301.00234). ArXiv preprint, abs/2301.00234. OpenAlex ↗ · Scholar ↗
- Eduard Hovy, Laurie Gerber, Ulf Hermjakob, Chin-Yew Lin, and Deepak Ravichandran. 2001. Toward semantics-based answer pinpointing (https://aclanthology.org/H01-1069). In Proceedings of the First International Conference on Human Language Technology Research. our card
- Diederik P. Kingma and Jimmy Ba. 2015. Adam: A method for stochastic optimization (http://arxiv.org/abs/1412.6980). In 3rd International Conference on Learning Representations, ICLR 2015, San Diego, CA, USA, May 7-9, 2015, Conference Track Proceedings. our card
- Goro Kobayashi, Tatsuki Kuribayashi, Sho Yokoi, and Kentaro Inui. 2020. Attention is not only a weight: Analyzing transformers with vector norms (https://doi.org/10.18653/v1/2020.emnlp-main.574). In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing (EMNLP), pages 7057–7075, Online. Association for Computational Linguistics. our card
- Xiaonan Li, Kai Lv, Hang Yan, Tianyang Lin, Wei Zhu, Yuan Ni, Guotong Xie, Xiaoling Wang, and Xipeng Qiu. 2023a. Unified demonstration retriever for in-context learning (https://arxiv.org/abs/2305.04320). ArXiv preprint, abs/2305.04320. our card
- Xin Li and Dan Roth. 2002. Learning question classifiers (https://aclanthology.org/C02-1150). In COLING 2002: The 19th International Conference on Computational Linguistics. OpenAlex ↗ · Scholar ↗
- Yingcong Li, Muhammed Emrullah Ildiz, Dimitris Papailiopoulos, and Samet Oymak. 2023b. Transformers as algorithms: Generalization and stability in in-context learning. OpenAlex ↗ · Scholar ↗
- Jiachang Liu, Dinghan Shen, Yizhe Zhang, Bill Dolan, Lawrence Carin, and Weizhu Chen. 2022. What makes good in-context examples for GPT-3? (https://doi.org/10.18653/v1/2022.deelio-1.10) In Proceedings of Deep Learning Inside Out (DeeLIO 2022): The 3rd Workshop on Knowledge Extraction and Integration for Deep Learning Architectures, pages 100–114, Dublin, Ireland and Online. Association for Computational Linguistics. our card
- Paul Michel, Omer Levy, and Graham Neubig. 2019. Are sixteen heads really better than one? (https://proceedings.neurips.cc/paper/2019/hash/2c601ad9d2ff9bc8b282670cdd54f69f-Abstract.html) In Advances in Neural Information Processing Systems 32: Annual Conference on Neural Information Processing Systems 2019, NeurIPS 2019, December 8-14, 2019, Vancouver, BC, Canada, pages 14014–14024. our card
- Sewon Min, Mike Lewis, Hannaneh Hajishirzi, and Luke Zettlemoyer. 2022a. Noisy channel language model prompting for few-shot text classification (https://doi.org/10.18653/v1/2022.acl-long.365). In Proceedings of the 60th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers), pages 5316–5330, Dublin, Ireland. Association for Computational Linguistics. our card
- Sewon Min, Xinxi Lyu, Ari Holtzman, Mikel Artetxe, Mike Lewis, Hannaneh Hajishirzi, and Luke Zettlemoyer. 2022b. Rethinking the role of demonstrations: What makes in-context learning work? (https://aclanthology.org/2022.emnlp-main.759) In Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing, pages 11048–11064, Abu Dhabi, United Arab Emirates. Association for Computational Linguistics. our card
- Alec Radford, Jeffrey Wu, Rewon Child, David Luan, Dario Amodei, Ilya Sutskever, et al. 2019. Language models are unsupervised multitask learners. OpenAI blog, 1(8):9. OpenAlex ↗ · Scholar ↗
- Karen Simonyan, Andrea Vedaldi, and Andrew Zisserman. 2013. Deep inside convolutional networks: Visualising image classification models and saliency maps. CoRR, abs/1312.6034. our card
- Richard Socher, Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Ng, and Christopher Potts. 2013. Recursive deep models for semantic compositionality over a sentiment treebank (https://aclanthology.org/D13-1170). In Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, pages 1631–1642, Seattle, Washington, USA. Association for Computational Linguistics. our card
- Hugo Touvron, Thibaut Lavril, Gautier Izacard, Xavier Martinet, Marie-Anne Lachaux, Timothée Lacroix, Baptiste Rozière, Naman Goyal, Eric Hambro, Faisal Azhar, Aurelien Rodriguez, Armand Joulin, Edouard Grave, and Guillaume Lample. 2023. Llama: Open and efficient foundation language models (https://api.semanticscholar.org/CorpusID:257219404). ArXiv, abs/2302.13971. our card
- Johannes von Oswald, Eyvind Niklasson, E. Randazzo, João Sacramento, Alexander Mordvintsev, Andrey Zhmoginov, and Max Vladymyrov. 2022. Transformers learn in-context by gradient descent (https://arxiv.org/abs/2212.07677). ArXiv preprint, abs/2212.07677. our card
- Ben Wang and Aran Komatsuzaki. 2021. GPT-J-6B: A 6 Billion Parameter Autoregressive Language Model. https://github.com/kingoflolz/mesh-transformer-jax. OpenAlex ↗ · Scholar ↗
- Jason Wei, Xuezhi Wang, Dale Schuurmans, Maarten Bosma, Ed Huai hsin Chi, F. Xia, Quoc Le, and Denny Zhou. 2022. Chain of thought prompting elicits reasoning in large language models (https://arxiv.org/abs/2201.11903). ArXiv preprint, abs/2201.11903. our card
- Jerry W. Wei, Jason Wei, Yi Tay, Dustin Tran, Albert Webson, Yifeng Lu, Xinyun Chen, Hanxiao Liu, Da Huang, Denny Zhou, and Tengyu Ma. 2023. Larger language models do in-context learning differently (https://api.semanticscholar.org/CorpusID:257378479). ArXiv, abs/2303.03846. our card
- Sang Michael Xie, Aditi Raghunathan, Percy Liang, and Tengyu Ma. 2022. An explanation of in-context learning as implicit bayesian inference (https://openreview.net/forum?id=RdJVFCHjUMI). In The Tenth International Conference on Learning Representations, ICLR 2022, Virtual Event, April 25-29, 2022. OpenReview.net. our card
- Jiacheng Ye, Zhiyong Wu, Jiangtao Feng, Tao Yu, and Lingpeng Kong. 2023. Compositional exemplars for in-context learning (https://arxiv.org/abs/2302.05698). ArXiv preprint, abs/2302.05698. our card
- Kang Min Yoo, Junyeob Kim, Hyuhng Joon Kim, Hyunsoo Cho, Hwiyeol Jo, Sang-Woo Lee, Sang-goo Lee, and Taeuk Kim. 2022. Ground-truth labels matter: A deeper look into input-label demonstrations (https://aclanthology.org/2022.emnlp-main.155). In Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing, pages 2422–2437, Abu Dhabi, United Arab Emirates. Association for Computational Linguistics. our card
- Xiang Zhang, Junbo Jake Zhao, and Yann LeCun. 2015. Character-level convolutional networks for text classification (https://proceedings.neurips.cc/paper/2015/hash/250cf8b51c773f3f8dc8b4be867a9a02-Abstract.html). In Advances in Neural Information Processing Systems 28: Annual Conference on Neural Information Processing Systems 2015, December 7-12, 2015, Montreal, Quebec, Canada, pages 649–657. our card
- Zihao Zhao, Eric Wallace, Shi Feng, Dan Klein, and Sameer Singh. 2021. Calibrate before use: Improving few-shot performance of language models (http://proceedings.mlr.press/v139/zhao21c.html). In Proceedings of the 38th International Conference on Machine Learning, ICML 2021, 18-24 July 2021, Virtual Event, volume 139 of Proceedings of Machine Learning Research, pages 12697–12706. PMLR. our card
This page in Markdown https://md.research.elamur.ai/free/en/papers/wang-2023-label-words-anchors-information-flow/