arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2410.13080cs.CL
收藏

图约束推理:基于大语言模型在知识图谱上的忠实推理

Graph-constrained Reasoning: Faithful Reasoning on Knowledge Graphs with Large Language Models

Monash University(莫纳什大学);Shanghai Jiao Tong University(上海交通大学);Griffith University(格里菲斯大学)

Linhao Luo, Zicheng Zhao, Gholamreza Haffari, Yuan-Fang Li, Chen Gong, Shirui Pan

AI总结:

提出图约束推理(GCR)框架,通过KG-Trie将知识图谱结构整合到大语言模型解码过程中以消除幻觉,并结合专用与通用LLM实现零幻觉的忠实推理与最先进的KGQA性能。

摘要:

大语言模型(LLMs)展现出了令人印象深刻的推理能力,但由于知识盲区和幻觉,它们在忠实推理方面仍面临困难。为了解决这些问题,知识图谱(KGs)被用来通过其结构化知识增强LLM推理。然而,现有的KG增强方法,无论是基于检索还是基于智能体,在准确检索知识和大规模高效遍历KGs方面都遇到了困难。在这项工作中,我们引入了图约束推理(GCR),这是一个将KGs中的结构化知识与LLMs中的非结构化推理相连接的新框架。为了消除幻觉,GCR通过KG-Trie将KG结构整合到LLM解码过程中,确保了基于KG的忠实推理。KG-Trie是一个基于前缀树的索引,用于编码KG推理路径。KG-Trie约束了解码过程,允许LLMs直接在图上进行推理,并生成基于KGs的忠实推理路径。此外,GCR利用轻量级的KG专用LLM进行图约束推理,并结合强大的通用LLM对多条推理路径进行归纳推理,从而实现了零推理幻觉的准确推理。在多个KGQA基准上的大量实验表明,GCR实现了最先进的性能,并在无需额外训练的情况下,对未见过的KGs表现出强大的零样本泛化能力。

英文摘要:

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.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑