Saved in:
Bibliographic Details
Main Authors: Luo, Linhao, Zhao, Zicheng, Haffari, Gholamreza, Li, Yuan-Fang, Gong, Chen, Pan, Shirui
Format: Preprint
Published: 2024
Subjects:
Online Access:https://arxiv.org/abs/2410.13080
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866918036936589312
author Luo, Linhao
Zhao, Zicheng
Haffari, Gholamreza
Li, Yuan-Fang
Gong, Chen
Pan, Shirui
author_facet Luo, Linhao
Zhao, Zicheng
Haffari, Gholamreza
Li, Yuan-Fang
Gong, Chen
Pan, Shirui
contents Large language models (LLMs) have demonstrated impressive reasoning abilities, but they still struggle with faithful reasoning due to knowledge gaps and hallucinations. To address these issues, knowledge graphs (KGs) have been utilized to enhance LLM reasoning through their structured knowledge. However, existing KG-enhanced methods, either retrieval-based or agent-based, encounter difficulties in accurately retrieving knowledge and efficiently traversing KGs at scale. In this work, we introduce graph-constrained reasoning (GCR), a novel framework that bridges structured knowledge in KGs with unstructured reasoning in LLMs. To eliminate hallucinations, GCR ensures faithful KG-grounded reasoning by integrating KG structure into the LLM decoding process through KG-Trie, a trie-based index that encodes KG reasoning paths. KG-Trie constrains the decoding process, allowing LLMs to directly reason on graphs and generate faithful reasoning paths grounded in KGs. Additionally, GCR leverages a lightweight KG-specialized LLM for graph-constrained reasoning alongside a powerful general LLM for inductive reasoning over multiple reasoning paths, resulting in accurate reasoning with zero reasoning hallucination. Extensive experiments on several KGQA benchmarks demonstrate that GCR achieves state-of-the-art performance and exhibits strong zero-shot generalizability to unseen KGs without additional training.
format Preprint
id arxiv_https___arxiv_org_abs_2410_13080
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle Graph-constrained Reasoning: Faithful Reasoning on Knowledge Graphs with Large Language Models
Luo, Linhao
Zhao, Zicheng
Haffari, Gholamreza
Li, Yuan-Fang
Gong, Chen
Pan, Shirui
Computation and Language
Large language models (LLMs) have demonstrated impressive reasoning abilities, but they still struggle with faithful reasoning due to knowledge gaps and hallucinations. To address these issues, knowledge graphs (KGs) have been utilized to enhance LLM reasoning through their structured knowledge. However, existing KG-enhanced methods, either retrieval-based or agent-based, encounter difficulties in accurately retrieving knowledge and efficiently traversing KGs at scale. In this work, we introduce graph-constrained reasoning (GCR), a novel framework that bridges structured knowledge in KGs with unstructured reasoning in LLMs. To eliminate hallucinations, GCR ensures faithful KG-grounded reasoning by integrating KG structure into the LLM decoding process through KG-Trie, a trie-based index that encodes KG reasoning paths. KG-Trie constrains the decoding process, allowing LLMs to directly reason on graphs and generate faithful reasoning paths grounded in KGs. Additionally, GCR leverages a lightweight KG-specialized LLM for graph-constrained reasoning alongside a powerful general LLM for inductive reasoning over multiple reasoning paths, resulting in accurate reasoning with zero reasoning hallucination. Extensive experiments on several KGQA benchmarks demonstrate that GCR achieves state-of-the-art performance and exhibits strong zero-shot generalizability to unseen KGs without additional training.
title Graph-constrained Reasoning: Faithful Reasoning on Knowledge Graphs with Large Language Models
topic Computation and Language
url https://arxiv.org/abs/2410.13080