NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Resolving Knowledge Conflicts in Large Language Models

Yike Wang, Shangbin Feng, Heng Wang, Weijia Shi, Vidhisha Balachandran, Tianxing He, Yulia Tsvetkov

TL;DR

This paper introduces a framework and evaluation tasks to assess how well Large Language Models (LLMs) handle knowledge conflicts, where provided information clashes with their internal knowledge. They find LLMs are good at detecting conflicts but struggle to pinpoint the exact conflicting parts or provide nuanced, distinct answers, highlighting a need for improved reasoning capabilities.

What Problem Does This Paper Address?

Large Language Models (LLMs) are trained on vast amounts of text, embedding a significant amount of "parametric knowledge." However, when LLMs are presented with external information (e.g., from a prompt or retrieved documents) that contradicts this internal knowledge, a "knowledge conflict" arises. This is a critical issue because it can lead to misinformation, unreliable outputs, and a lack of trustworthiness. Current LLMs often struggle to navigate these conflicts effectively, either by ignoring the external information, hallucinating, or providing a single, potentially incorrect, answer. The authors aim to understand and improve LLMs' ability to handle these conflicts by defining desirable behaviors and developing methods to evaluate them.

Methods

The core of this work is a novel evaluation framework designed to simulate and measure LLM performance on knowledge conflicts. This framework involves:

  1. Knowledge Conflict Generation: They create conflicting knowledge pairs by first eliciting an LLM's parametric knowledge about an entity and then factually modifying it. Two methods are used:
  2. In-domain Named Entity Substitution: Replacing entities (like people, locations) with others of the same type from the same domain.
  3. In-domain Entity Shuffling: Shuffling "main" entities within a context.
  4. Three Evaluation Tasks:
    • Task 1: Contextual Knowledge Conflict Detection: A binary classification task to determine if a given context conflicts with the LLM's internal knowledge.
  5. Task 2: QA-Span Knowledge Conflict Detection: A more granular task to pinpoint the specific piece of information within a passage that conflicts with knowledge, often framed as a question-answering problem.
  6. Task 3: Distinct Answers Generation: Evaluating the LLM's ability to provide multiple, distinct answers based on both the provided (conflicting) context and its own parametric knowledge.
  7. Instruction-Based Approaches: To improve LLM performance, the authors propose new prompting strategies that guide LLMs to decompose tasks, analyze information at a sentence level, and explicitly separate reasoning based on internal vs. external knowledge.

Datasets

The authors introduce a newly constructed dataset for evaluating knowledge conflicts. This dataset comprises:

  • Approximately 10,000 entities across 20 diverse domains.
  • Knowledge conflicts generated using the two methods described above (Named Entity Substitution and Entity Shuffling).
  • The dataset is designed to be challenging and reflect realistic scenarios by including diverse entities, domains, and progressively difficult conflict settings.

Key Insights and Ideas

  • Desiderata for LLMs: The authors propose that LLMs should ideally be able to: 1) identify knowledge conflicts, 2) pinpoint the specific conflicting segments, and 3) provide distinct answers or viewpoints. This empowers users to make informed decisions.
  • LLMs are Good Detectors, Bad Pinpointers: While LLMs can generally detect the presence of a knowledge conflict (Task 1), they struggle significantly with identifying the exact location of the conflict (Task 2) and generating nuanced, distinct answers (Task 3).
  • Prompting Matters: Novel instruction-based prompting strategies can significantly improve LLM performance, particularly in generating distinct answers.
  • Domain Sensitivity: An LLM's ability to handle knowledge conflicts varies greatly depending on the knowledge domain, likely due to the prevalence of conflicting information in their pre-training data.
  • Shuffling vs. Substitution: Conflicts generated through entity shuffling seem to be easier for LLMs to handle than those created by substitution.

Key Results

  • Task 1 (Conflict Detection): LLMs perform well above random chance, achieving high F1 scores (e.g., 0.802 with their proposed method). However, they tend to err on the side of caution, often declaring "no conflict" (high precision, low recall).
  • Task 2 (QA-Span Conflict Detection): Performance drops significantly. The "Self-ask" prompting method shows promise, but overall, LLMs struggle to pinpoint conflicts accurately (F1 scores around 0.535 with their method).
  • Task 3 (Distinct Answers Generation): LLMs achieve around 50% accuracy in simultaneously providing both parametric and conflicting-knowledge-based answers, indicating a substantial challenge. Their proposed approach improves this, reaching an F1 of 0.569.
  • Proposed Approach: Their instruction-based methods show improvements, particularly for Task 1 and Task 3, outperforming baselines on F1 for Task 1.

Limitations and Future Work

  • Factual Correctness of Conflicts: The generated conflicts are created by random entity substitution/shuffling, meaning the "conflicting" information might not be factually plausible or represent a realistic scenario. Future work could focus on generating more semantically meaningful conflicts.
  • Singular Parametric Knowledge: The study assumes a single "correct" parametric answer for an entity. While they argue this is generally true, exploring scenarios with multiple valid parametric answers could be beneficial.
  • Synthetic Data: The dataset is synthetically generated with word-level edits. Real-world knowledge conflicts can be far more complex, involving multi-hop reasoning or subjective viewpoints.
  • Future Directions:
    • Integrating the three tasks into a single, more comprehensive evaluation.
  • Exploring LLM performance on subjective viewpoints and opinions, not just factual conflicts.
  • Investigating LLMs' ability to handle conflicts arising from multi-hop reasoning.
  • Developing more robust methods for pinpointing conflicts and generating distinct, reliable answers.

Summary updated

BibTeX
@inproceedings{wang2024resolving,
  author = {Yike Wang and Shangbin Feng and Heng Wang and Weijia Shi and Vidhisha Balachandran and Tianxing He and Yulia Tsvetkov},
  title = {{Resolving Knowledge Conflicts in Large Language Models}},
  booktitle = {COLM},
  year = {2024},
  url = {https://openreview.net/forum?id=ptvV5HGTNN},
}
Figure