arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2410.11076cs.CLcs.AI
收藏

PRACTIQ:一个实用的对话式文本到SQL数据集,包含模糊和无法回答的查询

PRACTIQ: A Practical Conversational Text-to-SQL dataset with Ambiguous and Unanswerable Queries

Amazon Web Services(亚马逊云科技);University of Massachusetts at Amherst(马萨诸塞大学阿默斯特分校)

Mingwen Dong, Nischal Ashok Kumar, Yiqun Hu, Anuj Chauhan, Chung-Wei Hang, Shuaichen Chang, Lin Pan, Wuwei Lan, Henghui Zhu, Jiarong Jiang, Patrick Ng, Zhiguo Wang

AI总结:

PRACTIQ数据集旨在解决模糊和无法回答的文本到SQL问题,通过四轮对话生成和多种LLM基准测试,评估系统在复杂查询中的表现。

摘要:

先前的文本到SQL数据集和系统主要关注于意图明确且可回答的用户问题。然而,真实用户的提问往往具有多重解释或由于缺乏相关数据而无法回答。在本工作中,我们构建了一个名为PRACTIQ的实用对话式文本到SQL数据集,其中包含受现实用户问题启发的模糊和无法回答的问题。我们首先通过研究现有文本到SQL数据集确定了四种模糊问题类别和四种无法回答问题类别。然后,我们生成了四轮对话:初始用户问题、助手请求澄清的回复、用户的澄清、以及助手的澄清SQL回复并附有自然语言执行结果的解释。对于某些模糊查询,我们还直接生成了考虑多个方面模糊性的有用SQL回复,而不是请求用户澄清。为了在模糊、无法回答和可回答的问题上评估性能,我们实现了基于大语言模型(LLM)的基准线,使用了各种LLM。我们的方法包括两个步骤:问题类别分类和澄清SQL预测。我们的实验表明,最先进的系统在处理模糊和无法回答的问题时效果不佳。我们将发布我们的数据生成和实验代码到GitHub。

英文摘要:

Previous text-to-SQL datasets and systems have primarily focused on user questions with clear intentions that can be answered. However, real user questions can often be ambiguous with multiple interpretations or unanswerable due to a lack of relevant data. In this work, we construct a practical conversational text-to-SQL dataset called PRACTIQ, consisting of ambiguous and unanswerable questions inspired by real-world user questions. We first identified four categories of ambiguous questions and four categories of unanswerable questions by studying existing text-to-SQL datasets. Then, we generate conversations with four turns: the initial user question, an assistant response seeking clarification, the user's clarification, and the assistant's clarified SQL response with the natural language explanation of the execution results. For some ambiguous queries, we also directly generate helpful SQL responses, that consider multiple aspects of ambiguity, instead of requesting user clarification. To benchmark the performance on ambiguous, unanswerable, and answerable questions, we implemented large language model (LLM)-based baselines using various LLMs. Our approach involves two steps: question category classification and clarification SQL prediction. Our experiments reveal that state-of-the-art systems struggle to handle ambiguous and unanswerable questions effectively. We will release our code for data generation and experiments on GitHub.

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

↑