arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2405.11706cs.AIcs.DBcs.IRcs.LO
收藏

提高大语言模型问答的准确性:本体来救援!

Increasing the LLM Accuracy for Question Answering: Ontologies to the Rescue!

data.world AI Lab(data.world AI实验室)

Dean Allemang, Juan Sequeda

AI总结:

针对Text-to-SPARQL问答中LLM生成错误路径查询的问题,提出OBQC本体语义检查与LLM修复相结合的方法,将基准准确率提升至72%、错误率降至20%。

摘要:

越来越多的证据表明,采用企业SQL数据库的知识图谱/语义表示(即Text-to-SPARQL)的大语言模型(LLM)问答(QA)系统,相比直接在SQL数据库上回答问题的系统(即Text-to-SQL),能够实现更高的准确性。我们此前的基准研究表明,通过使用知识图谱,准确率从16%提升到了54%。问题仍然存在:我们如何进一步提高准确率并降低错误率?基于此前研究中观察到的现象——LLM生成的不准确SPARQL查询会沿着错误的路径行进——我们提出一种方法,包括:1)基于本体的查询检查(OBQC):利用知识图谱的本体检测错误,检查LLM生成的SPARQL查询是否符合本体语义;2)LLM修复:将错误解释提供给LLM,用以修复SPARQL查询。使用chat with the data基准,我们的主要发现是:该方法将总体准确率提高到72%,其中额外包含8%的“我不知道”未知结果。因此,总体错误率为20%。这些结果进一步证明,投入构建知识图谱(即本体)能够为LLM驱动的问答系统提供更高的准确性。

英文摘要:

There is increasing evidence that question-answering (QA) systems with Large Language Models (LLMs), which employ a knowledge graph/semantic representation of an enterprise SQL database (i.e. Text-to-SPARQL), achieve higher accuracy compared to systems that answer questions directly on SQL databases (i.e. Text-to-SQL). Our previous benchmark research showed that by using a knowledge graph, the accuracy improved from 16% to 54%. The question remains: how can we further improve the accuracy and reduce the error rate? Building on the observations of our previous research where the inaccurate LLM-generated SPARQL queries followed incorrect paths, we present an approach that consists of 1) Ontology-based Query Check (OBQC): detects errors by leveraging the ontology of the knowledge graph to check if the LLM-generated SPARQL query matches the semantic of ontology and 2) LLM Repair: use the error explanations with an LLM to repair the SPARQL query. Using the chat with the data benchmark, our primary finding is that our approach increases the overall accuracy to 72% including an additional 8% of "I don't know" unknown results. Thus, the overall error rate is 20%. These results provide further evidence that investing knowledge graphs, namely the ontology, provides higher accuracy for LLM powered question answering systems.

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

↑