Do Robot Snakes Dream like Electric Sheep? Investigating the Effects of Architectural Inductive Biases on Hallucination

Jerry Huang, Prasanna Parthasarathi, Mehdi Rezagholizadeh, Boxing Chen, Sarath Chandar

Abstract

As Large Language Models (LLMs) transition from research to production, the phenomenon of hallucination remains a significant hurdle. While the Transformer architecture dominates the field, alternative recurrent architectures like State-Space Models (SSMs) are gaining traction due to their efficiency. This paper investigates how these fundamental architectural choices influence a model's tendency to hallucinate. We find a distinct trade-off: recurrent models exhibit higher "faithfulness" to provided context but struggle with "factuality" regarding rare world knowledge compared to their attention-based counterparts.

Introduction

The reliability of LLMs is often undermined by hallucinations—the generation of factually incorrect or contextually inconsistent information. While much effort has gone into mitigating these errors within the Transformer paradigm, the rise of recurrent architectures like Mamba and RWKV introduces new variables. Unlike Transformers, which utilize attention mechanisms to access the entire history of a conversation, recurrent models compress context into a fixed-size hidden state. This study explores whether this "compression bottleneck" fundamentally alters the nature of hallucinations, specifically focusing on the tension between recalling external facts (Factuality) and adhering to internal prompts (Faithfulness).

Methodology

The researchers evaluated a broad spectrum of open-source LLMs across three paradigms: Attention-Only (e.g., LLaMA, Mistral), Recurrent (e.g., Mamba, Finch), and Hybrid (e.g., Jamba, RecurrentGemma). To isolate architectural effects from training data variances, they performed "controlled surgery" on LLaMA-3 8B, creating hybrid variants by replacing portions of attention layers with Mamba layers and retraining on identical datasets. Evaluation was conducted using the Hallucination Leaderboard, encompassing 20 tasks across categories like closed-book QA, summarization, and instruction following.

Architectural Trade-offs: Factuality vs. Faithfulness

A primary finding is the "compression bottleneck" inherent in recurrent models. By forcing information into a fixed-size state, these models struggle to retain "long-tail" or rare knowledge. In the PopQA benchmark, which tests obscure facts, recurrent models like FalconMamba significantly underperformed compared to Transformer-based models of similar size. For instance, FalconMamba achieved an Exact Match (EM) score of only 0.7, while the attention-based Falcon scored 17.5.

Conversely, this same bottleneck appears to provide a protective effect against "memorization traps." In the MemoTrap task, models are prompted to complete common proverbs in unconventional ways. Transformers often default to the over-learned completion from their training data (a hallucination of the "truth"), whereas recurrent models more reliably follow the specific instructions of the prompt.

Performance comparison on PopQA (Factuality) and MemoTrap (Faithfulness) across different model architectures.

Scaling and Instruction Tuning

The study also highlights divergent scaling behaviors. While factuality generally improves with model size across all architectures, faithfulness in recurrent models tends to plateau early. A small Mamba model can match the faithfulness of a much larger LLaMA model, but further scaling of the recurrent architecture does not yield proportional gains in faithfulness.

Furthermore, while Supervised Fine-Tuning (SFT) significantly boosts the faithfulness of Transformers, its impact on recurrent models is markedly lower. This suggests that recurrent models possess an "inherent" faithfulness due to their inductive bias, leaving less room for improvement via traditional tuning methods.

Scaling trends for Factuality and Faithfulness scores relative to model size (number of parameters) across different paradigms.

Conclusion

The choice of architecture introduces specific inductive biases that shape how an LLM hallucinates. Recurrent models are naturally more faithful to context but less capable of broad factual recall. Hybrid models offer a potential middle ground, though they often inherit the specific weaknesses of their recurrent components in factual tasks. These findings suggest that the optimal architecture may depend on the specific application: tasks requiring high contextual fidelity (e.g., summarization of legal or medical documents) may favor recurrent or hybrid structures, while general-purpose knowledge retrieval remains the stronghold of attention-based models.

Summary updated

BibTeX
@inproceedings{huang2025do,
  author = {Jerry Huang and Prasanna Parthasarathi and Mehdi Rezagholizadeh and Boxing Chen and Sarath Chandar},
  title = {{Do Robot Snakes Dream like Electric Sheep? Investigating the Effects of Architectural Inductive Biases on Hallucination}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2025},
}
Figure