This study explores the realm of knowledge-base question answering (KBQA). KBQA is considered a challenging task, particularly in parsing intricate questions into executable logical forms. Traditional semantic parsing (SP)-based methods require extensive data annotations, which result in significant costs. Recently, the advent of few-shot in-context learning, powered by large language models (LLMs), has showcased promising capabilities. Yet, fully leveraging LLMs to parse questions into logical forms in low-resource scenarios poses a substantial challenge. To tackle these hurdles, we introduce Interactive-KBQA, a framework designed to generate logical forms through direct interaction with knowledge bases (KBs). Within this framework, we have developed three generic APIs for KB interaction. For each category of complex question, we devised exemplars to guide LLMs through the reasoning processes. Our method achieves competitive results on the WebQuestionsSP, ComplexWebQuestions, KQA Pro, and MetaQA datasets with a minimal number of examples (shots). Importantly, our approach supports manual intervention, allowing for the iterative refinement of LLM outputs. By annotating a dataset with step-wise reasoning processes, we showcase our model's adaptability and highlight its potential for contributing significant enhancements to the field.
翻译:本研究探索知识库问答领域。知识库问答被视为一项具有挑战性的任务,尤其在将复杂问题解析为可执行逻辑形式方面。传统基于语义解析的方法需要大量数据标注,导致高昂成本。近年来,基于大语言模型的少样本上下文学习展现出显著潜力。然而,在低资源场景下充分运用大语言模型将问题解析为逻辑形式仍面临重大挑战。为解决这些难题,我们提出交互式知识库问答框架,该框架通过直接与知识库交互生成逻辑形式。在该框架中,我们开发了三类通用知识库交互接口。针对每类复杂问题,我们设计了示例以引导大语言模型完成推理过程。在WebQuestionsSP、ComplexWebQuestions、KQA Pro和MetaQA数据集上,我们的方法仅需极少量示例即可获得具有竞争力的结果。重要的是,该方法支持人工干预,可对模型输出进行迭代优化。通过标注包含逐步推理过程的数据集,我们展示了模型的适应性及其对该领域做出显著贡献的潜力。