NeurIPS 2026QuestionsPapersAreasAboutMarkdown

KG-Guard: Graph-Based Hallucination Detection for Knowledge Base Question Answering

Albert Sawczyn, Piotr Bielak, Tomasz Kajdanowicz

NeurIPS page · OpenReview · alphaXiv · Open on the map

Category: LLM Reasoning, Memory & RAG › Retrieval-Augmented Generation · Type: new method · Keywords: graph-based hallucination detection, knowledge base question answering, black-box verification, KBQA evaluation, lightweight detection

Areas: Safety & Security › Language Model Security › Hallucination Detection; Evaluation & Benchmarks › Model Capability Diagnostics › Language Model Reliability; Graph Learning › Graph Reasoning and Representation › Graph-Based Retrieval and Reasoning

Summary

KG-Guard is a lightweight graph-based framework that detects hallucinated answer nodes in KBQA by treating the answering LLM as a black box and classifying each proposed answer node, achieving state-of-the-art detection performance and improving downstream KBQA accuracy.

Explained to a 5-year-old

Sometimes big computer programs that answer questions make up answers that aren't true. To help, we draw a picture of the facts and mark where the program thinks the answer is. Then we look at the picture and decide if the answer is correct. This helps catch mistakes, especially when the answers are used for important things like health. After fixing the wrong answers, the program gets better at giving right answers.

Explained to a 5-year-old, longer

Big computers that answer questions sometimes guess wrong things. They might use information they already know instead of the facts we give them. This problem is especially risky when the answers are used for important things like doctors' decisions. To help, we create a simple picture that shows the facts and where the computer thinks the answer is. We add special marks to show which facts are important and which answers the computer suggests. Then we look at this picture and decide if each suggested answer matches the facts. If an answer doesn't match, we say it's a mistake, or a hallucination. This way we can find wrong answers without changing the big computer. After we tell the system which answers are wrong, it can try again and get better. The method works on many different question datasets and catches more mistakes than other simple checks. It also uses far fewer computer parts than other approaches, making it cheap to run. In the end, this helps keep the answers safe and useful for real-world problems.

For a technical reader

KG-Guard is a lightweight graph-based detector that treats the answering LLM as a black box and classifies each proposed answer node. It builds an augmented graph per KBQA instance, initializing nodes with KG entity embeddings and adding learned vectors for topics and candidate answers. A graph encoder produces verification-oriented representations, which a small MLP combines with the question embedding to output a hallucination score. The detector achieves state-of-the-art F1 scores (82.0, 87.4, 84.3) on WebQSP, ComplexWebQuestions, and PUGG while using ~305× fewer parameters than baselines. Feeding back flagged answers iteratively improves downstream KBQA F1 by 13.0-14.5 points and Exact Match by 16.9-17.6 points.

Problem

Knowledge base question answering (KBQA) systems using LLMs often produce hallucinated answers that rely on parametric knowledge rather than the provided knowledge graph, limiting reliability especially in high-stakes domains. There is a need for a method to detect and correct such hallucinations without modifying the underlying LLM.

Method

The approach treats the answering LLM as a black box and constructs an augmented graph for each KBQA instance, initializing node features with KG entity representations, marking topic and answer nodes with learned vectors, and connecting a virtual question node. A graph encoder produces verification-oriented node embeddings, which are fed to a small MLP that classifies each proposed answer node using its graph representation and the question embedding.

Results

The detector achieves F1 scores of 82.0, 87.4, and 84.3 on WebQSP, ComplexWebQuestions, and PUGG respectively, surpassing LLM-judge and sampling baselines, and feeding back flagged answers improves downstream KBQA F1 by 13.0-14.5 points and Exact Match by 16.9-17.6 points.

Contributions

A graph-based hallucination detection framework that operates as a black-box classifier for answer nodes, delivering state-of-the-art detection performance with orders-of-magnitude fewer parameters, and demonstrating that iterative feedback from the detector significantly boosts KBQA accuracy.

Practical relevance

The approach enables reliable deployment of KBQA systems in critical domains like healthcare by automatically detecting and correcting hallucinations, reducing the risk of erroneous answers.

Research questions this paper is counted under

This page was written by language models from the title and abstract of each paper, and the answers were checked by two other models. It can be wrong: check the paper itself. Suggest a correction