Bilinear representation mitigates reversal curse and enables consistent model editing

Dong-Kyum Kim, Minsung Kim, Jea Kwon, Nakyeong Yang, Meeyoung Cha

TL;DR

The "reversal curse"—a language model's inability to infer "B is A" after being trained on "A is B"—is not an inherent flaw of autoregressive architectures, but an artifact of how knowledge is geometrically stored. By applying proper weight decay regularization during training, models naturally develop an internal bilinear relational structure that eliminates the curse and enables logically consistent model editing.

What Problem Does This Paper Address?

Autoregressive language models are notorious for the "reversal curse." If a model learns during training that "A is the parent of B," it frequently fails to infer the reverse fact, "B is the child of A." This directional asymmetry poses a massive challenge for model editing—the practice of updating specific facts in a pre-trained model without expensive retraining.

For instance, if you edit a model to change "A is the spouse of B" to "A is the spouse of C," a logically consistent model should automatically deduce that "C is the spouse of A" and update its downstream beliefs accordingly. Instead, current editing algorithms suffer from the reversal curse, requiring explicit co-editing of both directions to avoid glaring logical contradictions.

The authors ask a fundamental question: Is this failure an unfixable byproduct of the autoregressive training objective, or is it simply a consequence of how models choose to represent knowledge geometrically?

Methods

To investigate the geometric structure of relational knowledge, the authors trained 12-layer decoder-only Transformers (GPT-NeoX architecture, ~206M parameters) from scratch. They systematically varied the training conditions using different levels of weight decay regularization.

To uncover the geometry of the learned representations, they developed and compared three distinct mathematical probes on the models' hidden states:

  1. Linear Relational Embedding: Models a relation as a local affine transformation ($o_L \approx W_r s_l + b_r$).
  2. Translational Embedding: Models a relation as a simple vector offset ($o_l \approx s_l + v_r$).
  3. Bilinear Relational Embedding: Models a relation as a matrix $M_r$ that mediates the interaction between subject and object embeddings via a score function ($f_r(s_l, o_l) = s_l^\top M_r o_l$).

Because optimizing a bilinear probe in high-dimensional embedding spaces ($d=896$) is computationally prohibitive ($O(d^6)$), the authors utilized a clever SVD-based optimization variant of the RESCAL algorithm to make the computation tractable.

Figure 1: Schematics of relational embedding structures. For a subject s and object o, the relation r is modeled as: (a) linear transformation, (b) vector translation, or (c) bilinear interaction mediated by a relation-specific matrix Mr. As an example, in the fact “Son of Tracy Lance Smith is Cory Lance Smith,” s is “Tracy Lance Smith,” o is “Cory Lance Smith,” and r is son.

Datasets

The authors evaluated their hypothesis using a synthetic family knowledge graph consisting of 1,000 families with 10 entities each. The graph includes eight distinct family relations: husband, wife, father, mother, son, daughter, brother, and sister.

The dataset was split into two groups of 500 families:

  • Group 1 (Full relations): Contained all 36 relational facts per family.
  • Group 2 (Missing relations): The father and mother relations were intentionally withheld during training.

The test set consisted exclusively of the withheld father/mother relations from Group 2. To succeed, the model had to logically compose existing relations (e.g., deducing that if A is the husband of B, and B is the mother of C, then A is the father of C).

Key Insights and Ideas

  • Weight Decay as a Phase Transition Trigger: Regularization acts as a switch between memorization and reasoning. Without sufficient weight decay, models memorize directional text and succumb to the reversal curse. With high weight decay, models undergo a transition, learning a highly generalizable internal structure.
  • The Emergence of Bilinear Geometry: While prior literature suggested language models favor linear or translational embeddings, this paper reveals that a bilinear structure best explains hidden representations. This geometry naturally accommodates inverse relations via matrix transposition ($M_r^\top$) and relation composition via matrix multiplication ($M_{r2}M_{r1}$).
  • Functional Relational Algebra: Probing showed that the learned relation matrices aren't just statistical artifacts; they satisfy formal algebraic properties. The transpose of the "husband" matrix genuinely functions as the "wife" matrix, and multiplying "husband" by "mother" yields the "father" matrix.
  • Edit Early for Logical Propagation: When editing a model, intervening in the early-to-mid layers (layers 1–4) yields the highest logical generalization. This suggests that to successfully update a fact, you must edit the representation where it is being formed, rather than in the middle layers (layers 6–9) where it is already established and utilized.

Key Results

  • Breaking the Curse: Models trained with sufficient weight decay regularization achieved near-perfect accuracy (>98%) on unseen reverse relations, completely overcoming the reversal curse.
Figure 2: (Left) Schematic of the synthetic family knowledge graph. Nodes represent entities, while directed edges represent one of eight distinct family relations used in our experimental evaluation. (Right) Test accuracy on the unseen relations (mother/father) as a function of weight decay. Each weight decay setting was trained using three different random seeds.
  • Probe Accuracy: In successful models, the precision of the bilinear probe rose sharply and peaked above 95% in the middle layers (6–9), far outperforming linear and translational alternatives which hovered near the 33% chance baseline.
  • Predicting Edit Success: The authors found a powerful correlation ($R^2 = 0.939$) between a model's peak bilinear probe accuracy and its maximum logical generalization after an edit. A well-structured bilinear representation directly predicts whether an edit will successfully propagate to logically entailed facts.

Limitations and Future Work

The primary limitation of this study is its reliance on a clean, closed-world synthetic dataset and models trained from scratch. Real-world knowledge graphs are noisy, massive, and highly complex.

Whether these structured bilinear representations naturally emerge—or can be easily induced—in industrial-scale, pre-trained large language models remains an open question. The authors note that it is unlikely all real-world knowledge is encoded via a single, uniform geometry.

Moving forward, the authors suggest developing diagnostic tools to map out the local representational geometry of pre-trained LLMs, paving the way for truly "structure-aware" model editing techniques.

Summary updated

Abstract

The reversal curse--a language model's inability to infer an unseen fact "B is A" from a learned fact "A is B"--is widely considered a fundamental limitation. We show that this is not an inherent failure but an artifact of how models encode knowledge. Our results demonstrate that training from scratch on synthetic relational knowledge graphs leads to the emergence of a bilinear relational structure within the models' hidden representations. This structure alleviates the reversal curse and facilitates inference of unseen reverse facts. Crucially, this bilinear geometry is foundational for consistent model editing: updates to a single fact propagate correctly to its reverse and logically dependent relations. In contrast, models lacking this representation suffer from the reversal curse and fail to generalize model edits, leading to logical inconsistencies. Our results establish that training on a relational knowledge dataset induces the emergence of bilinear internal representations, which in turn support language models in behaving in a logically consistent manner after editing. This suggests that the efficacy of language model editing depends not only on the choice of algorithm but on the underlying representational geometry of the knowledge itself.
BibTeX
@inproceedings{kim2026bilinear,
  author = {Dong-Kyum Kim and Minsung Kim and Jea Kwon and Nakyeong Yang and Meeyoung Cha},
  title = {{Bilinear representation mitigates reversal curse and enables consistent model editing}},
  booktitle = {International Conference on Learning Representations},
  year = {2026},
  url = {https://openreview.net/forum?id=pdNaYcApbz},
}
Figure