Relational Linearity is a Predictor of Hallucinations
Yuetian Lu, Yihong Liu, Hinrich Schütze
TL;DR
This work investigates why LLMs hallucinate when asked about unknown subjects by proposing that the linearity of relation representations predicts hallucination likelihood. They introduce Synt-Hal, a synthetic dataset with six relations (covering both linear and nonlinear structures), and measure relational linearity with the $Δ\cos$ metric derived from Linear Relational Embeddings, using an LLM-as-a-judge to label outputs as hallucinations or refusals. Across four instruction-tuned models, they find a strong positive correlation between $Δ\cos$ and hallucination rate on the synthetic data ($r$ between approximately $0.78$ and $0.82$), while natural triples show the opposite trend, suggesting different dynamics when prior knowledge is present. The results imply that abstract, relation-wide representations of linear triples hinder knowledge self-assessment, pointing to directions for augmenting linear-relation representations to improve truthfulness and reduce hallucinations in LLMs.
Abstract
Hallucination is a central failure mode in large language models (LLMs). We focus on hallucinations of answers to questions like: "Which instrument did Glenn Gould play?", but we ask these questions for synthetic entities that are unknown to the model. Surprisingly, we find that medium-size models like Gemma-7B-IT frequently hallucinate, i.e., they have difficulty recognizing that the hallucinated fact is not part of their knowledge. We hypothesize that an important factor in causing these hallucinations is the linearity of the relation: linear relations tend to be stored more abstractly, making it difficult for the LLM to assess its knowledge; the facts of nonlinear relations tend to be stored more directly, making knowledge assessment easier. To investigate this hypothesis, we create SyntHal, a dataset of 6000 synthetic entities for six relations. In our experiments with four models, we determine, for each relation, the hallucination rate on SyntHal and also measure its linearity, using $Δ\cos$. We find a strong correlation ($r \in [.78,.82]$) between relational linearity and hallucination rate, providing evidence for our hypothesis that the underlying storage of triples of a relation is a factor in how well a model can self-assess its knowledge. This finding has implications for how to manage hallucination behavior and suggests new research directions for improving the representation of factual knowledge in LLMs.
