A Glitch in the Matrix? Locating and Detecting Language Model Grounding with Fakepedia
arXiv:2312.02073
Abstract
Large language models (LLMs) have an impressive ability to draw on novel information supplied in their context. Yet the mechanisms underlying this contextual grounding remain unknown, especially in situations where contextual information contradicts factual knowledge stored in the parameters, which LLMs also excel at recalling. Favoring the contextual information is critical for retrieval-augmented generation methods, which enrich the context with up-to-date information, hoping that grounding can rectify outdated or noisy stored knowledge. We present a novel method to study grounding abilities using Fakepedia, a novel dataset of counterfactual texts constructed to clash with a model's internal parametric knowledge. In this study, we introduce Fakepedia, a counterfactual dataset designed to evaluate grounding abilities when the internal parametric knowledge clashes with the contextual information. We benchmark various LLMs with Fakepedia and conduct a causal mediation analysis of LLM components when answering Fakepedia queries, based on our Masked Grouped Causal Tracing (MGCT) method. Through this analysis, we identify distinct computational patterns between grounded and ungrounded responses. We finally demonstrate that distinguishing grounded from ungrounded responses is achievable through computational analysis alone. Our results, together with existing findings about factual recall mechanisms, provide a coherent narrative of how grounding and factual recall mechanisms interact within LLMs.
Accepted at ACL 2024 (main conference)
References in corpus (28)
- Survey of Hallucination in Natural Language Generation
- LLaMA: Open and Efficient Foundation Language Models
- Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks
- ReAct: Synergizing Reasoning and Acting in Language Models
- Locating and Editing Factual Associations in GPT
- Augmented Language Models: a Survey
- Textbooks Are All You Need
- Large Language Models Struggle to Learn Long-Tail Knowledge
- Explaining Classifiers with Causal Concept Effect (CaCE)
- A Review on Language Models as Knowledge Bases
- Mass-Editing Memory in a Transformer
- Progress measures for grokking via mechanistic interpretability
- Interpretability in the Wild: a Circuit for Indirect Object Identification in GPT-2 small
- Impact of Pretraining Term Frequencies on Few-Shot Reasoning
- Compositional Explanations of Neurons
- TinyStories: How Small Can Language Models Be and Still Speak Coherent English?
- Eliciting Latent Predictions from Transformers with the Tuned Lens
- Causal Abstraction: A Theoretical Foundation for Mechanistic Interpretability
- Fine-tuning Language Models for Factuality
- Analyzing Feed-Forward Blocks in Transformers through the Lens of Attention Maps
- Interpretability at Scale: Identifying Causal Mechanisms in Alpaca
- Causal Proxy Models for Concept-Based Model Explanations
- Knowledge Conflicts for LLMs: A Survey
- Language Models Implement Simple Word2Vec-style Vector Arithmetic
- Exploring the Potential of AI-Generated Synthetic Datasets: A Case Study on Telematics Data with ChatGPT
- Do Androids Know They're Only Dreaming of Electric Sheep?
- Patchscopes: A Unifying Framework for Inspecting Hidden Representations of Language Models
- Hallucination Augmented Recitations for Language Models