keqing: knowledge-based question answering is a nature chain-of-thought mentor of LLM
Chaojie Wang, Yishi Xu, Zhong Peng, Chenxi Zhang, Bo Chen, Xinrun Wang, Lei Feng, Bo An
TL;DR
The paper tackles hallucination in LLM-based knowledge QA by introducing Keqing, a four-stage KBQA framework that retrieves structured knowledge from a knowledge graph and guides LLMs via interpretable, chain-of-thought–style reasoning paths. It replaces traditional embedding-based retrieval with symbolic KG triplet retrieval aligned to predefined question templates, followed by candidate reasoning over retrieved triplets and a final response generation that exposes the reasoning process. Keqing leverages LoRA-finetuned LLaMA for decomposition, RoBERTa-based template matching, and ChatGPT for final reasoning and explanation, achieving competitive results on MetaQA and WebQSP while improving transparency. The work demonstrates that knowledge-based question answering can serve as a natural CoT mentor for LLMs, enabling scalable, interpretable, and more reliable QA over large knowledge graphs.
Abstract
Large language models (LLMs) have exhibited remarkable performance on various natural language processing (NLP) tasks, especially for question answering. However, in the face of problems beyond the scope of knowledge, these LLMs tend to talk nonsense with a straight face, where the potential solution could be incorporating an Information Retrieval (IR) module and generating response based on these retrieved knowledge. In this paper, we present a novel framework to assist LLMs, such as ChatGPT, to retrieve question-related structured information on the knowledge graph, and demonstrate that Knowledge-based question answering (Keqing) could be a nature Chain-of-Thought (CoT) mentor to guide the LLM to sequentially find the answer entities of a complex question through interpretable logical chains. Specifically, the workflow of Keqing will execute decomposing a complex question according to predefined templates, retrieving candidate entities on knowledge graph, reasoning answers of sub-questions, and finally generating response with reasoning paths, which greatly improves the reliability of LLM's response. The experimental results on KBQA datasets show that Keqing can achieve competitive performance and illustrate the logic of answering each question.
