arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2409.04181cs.CL
收藏

结合大语言模型(LLM)和知识图谱(KG)减少问答中的幻觉

Combining LLMs and Knowledge Graphs to Reduce Hallucinations in Question Answering

Zuse Institute Berlin(柏林泽尼茨研究所)

Larissa Pusch, Tim O. F. Conrad

AI总结:

针对生物医学等领域问答系统的幻觉问题,提出结合LLM与KG的混合方法,基于LangChain框架引入查询检查器,在50个生物医学问题基准集上测试显示能减少错误,GPT-4 Turbo表现最优,开源模型经提示工程也具潜力,并开发了易用界面。

摘要:

自然语言处理的进步彻底改变了我们与数据库等数字信息系统的交互方式,使其更易于访问。然而,挑战依然存在,尤其是在准确性至关重要的领域,如生物医学领域。一个关键问题是幻觉问题,即模型生成底层数据不支持的信息,可能导致危险的错误信息。本文提出了一种新颖方法,通过结合大语言模型(LLM)和知识图谱(KG)来弥合这一差距,以生物医学知识图谱为例,提高问答系统的准确性和可靠性。我们的方法基于LangChain框架,纳入了一个查询检查器,确保LLM生成的查询在语法和语义上有效,然后用于从知识图谱中提取信息,大幅减少幻觉等错误。我们使用包含50个生物医学问题的新基准数据集评估了整体性能,测试了多个LLM,包括GPT-4 Turbo和llama3:70b。结果表明,虽然GPT-4 Turbo在生成准确查询方面优于其他模型,但llama3:70b等开源模型通过适当的提示工程显示出潜力。为了使该方法易于访问,我们开发了一个用户友好的基于网络的界面,允许用户输入自然语言查询,查看生成和纠正的Cypher查询,并验证结果路径的准确性。总体而言,这种混合方法有效解决了数据缺口和幻觉等常见问题,为问答系统提供了可靠且直观的解决方案。生成本文结果和用户界面的源代码可在我们的Git仓库中找到:https://git.zib.de/lpusch/cyphergenkg-gui

英文摘要:

Advancements in natural language processing have revolutionized the way we can interact with digital information systems, such as databases, making them more accessible. However, challenges persist, especially when accuracy is critical, as in the biomedical domain. A key issue is the hallucination problem, where models generate information unsupported by the underlying data, potentially leading to dangerous misinformation. This paper presents a novel approach designed to bridge this gap by combining Large Language Models (LLM) and Knowledge Graphs (KG) to improve the accuracy and reliability of question-answering systems, on the example of a biomedical KG. Built on the LangChain framework, our method incorporates a query checker that ensures the syntactical and semantic validity of LLM-generated queries, which are then used to extract information from a Knowledge Graph, substantially reducing errors like hallucinations. We evaluated the overall performance using a new benchmark dataset of 50 biomedical questions, testing several LLMs, including GPT-4 Turbo and llama3:70b. Our results indicate that while GPT-4 Turbo outperforms other models in generating accurate queries, open-source models like llama3:70b show promise with appropriate prompt engineering. To make this approach accessible, a user-friendly web-based interface has been developed, allowing users to input natural language queries, view generated and corrected Cypher queries, and verify the resulting paths for accuracy. Overall, this hybrid approach effectively addresses common issues such as data gaps and hallucinations, offering a reliable and intuitive solution for question answering systems. The source code for generating the results of this paper and for the user-interface can be found in our Git repository: https://git.zib.de/lpusch/cyphergenkg-gui

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

↑