Prompt InsightsOpen Prompt Builder

Prompt Engineering

The Reversal Curse: Why Your LLM Knows A→B but Not B→A

Research confirms LLMs systematically fail to infer bidirectional relationships from unidirectional training data. If your model learned 'A is B,' it may have no idea that 'B is A,' and your prompts need to account for it.

3 min read
Photo: Unsplash

Research confirmed this week that LLMs have a structural blind spot: train a model that 'Tom Cruise's mother is Mary Lee Pfeiffer' and it will likely fail to answer 'Who is Mary Lee Pfeiffer's son?' The Reversal Curse is not a quirk of one model or one task. It is a systematic consequence of how autoregressive training works, and it has direct, practical consequences for anyone writing prompts, building RAG pipelines, or fine-tuning models on domain data.

The pattern

Autoregressive language models are trained to predict the next token given all previous tokens. This means the model learns the statistical pattern of sequences in the order they appear. When training data consistently presents a relationship as A → B, the model encodes that directional path. The reverse path, B → A, is a different sequence with different token order, and unless it also appears in training data, the model has no reliable way to traverse it.

The result is asymmetric knowledge: the model can answer forward queries fluently while failing, or hallucinating, on reverse queries about the same underlying fact.

Why now

This is not a new hypothesis, but it is gaining renewed attention as prompt engineering practitioners run into it at scale. Teams building knowledge-intensive applications, legal document assistants, medical reference tools, and enterprise search, are discovering that their carefully curated fine-tuning datasets produce models with invisible one-way streets. The model sounds confident in both directions, but accuracy on reverse queries can drop dramatically.

The problem compounds in retrieval-augmented generation. If your retrieved chunks consistently phrase facts in one direction, the model inherits that directionality.

How it works in practice

  1. Identify your relationship pairs. Any fact of the form 'X is the Y of Z' has a reverse: 'Z's Y is X.' Map these pairs explicitly in your domain.
  2. Audit your training and context data. Check whether your fine-tuning corpus or your retrieval chunks present relationships bidirectionally. A simple script that counts forward vs. reverse phrasings will surface the imbalance.
  3. Rewrite prompts to state both directions. In a system prompt or few-shot examples, explicitly include both 'A is B' and 'B is A' when the reverse query is likely. Do not assume the model will infer it. The Claude system prompt documentation is a useful reference for structuring this kind of explicit context injection.
  4. Add reverse-query test cases to your eval suite. For every forward factual assertion you test, add the corresponding reverse question. A model that passes forward evals while failing reverse ones is shipping with a hidden defect.
  5. Consider data augmentation for fine-tuning. If you control the training data, generate reverse-phrased versions of every key fact. This is the most durable fix, though it doubles the relevant data requirements.

The trade-off

Explicitly stating both directions of every relationship bloats your context. In a long system prompt or a dense RAG chunk, doubling relational statements has a real token cost and can dilute other signal. The pragmatic approach is to be selective: audit which relationships your users actually query in reverse, and prioritize bidirectional coverage there. Not every fact needs symmetric treatment, only the ones where a wrong answer is costly.

There is also a subtler risk. Aggressively augmenting fine-tuning data with reverse phrasings can introduce repetition artifacts that degrade fluency or cause the model to over-index on certain entity pairs. Test augmented checkpoints carefully before shipping.

Where it goes next

This finding puts pressure on how teams think about model behavior evaluation. Benchmark scores on forward-query tasks are not sufficient signals of knowledge quality. Expect evaluation frameworks to start including reversal probes as a standard component, alongside factuality and hallucination metrics.

It also raises questions for long-running agentic workflows. Jason Liu's work on Codex for multi-prompt context preservation highlights how complex projects accumulate state across many prompts. If early context establishes facts in one direction and later prompts query them in reverse, the reversal curse can silently corrupt reasoning chains across an entire session.

Knowledge is directional until proven otherwise. Build your prompts and evals accordingly.

READY TO ASCEND

Get AI news that respects your time

The signal, distilled. Curated AI news and prompt-engineering insight. No noise.

More in Prompt Engineering