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

针对阿拉伯语上下文依赖文本到SQL的提示工程技术

Prompt Engineering Techniques for Context-dependent Text-to-SQL in Arabic

Department of Computer Science University of Central Florida Orlando, Florida, USA(计算机科学系 佛罗里达中央大学 奥兰多分校)

Saleh Almohaimeed, May Alsofyani, Saad Almohaimeed, Mansour Al Ghanim, Liqiang Wang

AI总结:

本文提出Ar-SParC数据集及GAT corrector方法,通过提示工程技术提升阿拉伯语文本到SQL任务的性能。

摘要:

近年来,跨领域、上下文依赖的文本到SQL任务引起了广泛关注。它使没有SQL知识的用户能够用自然语言与数据库进行对话。然而,大多数可用的数据集和研究都是用英语进行的,还有一些是中文。截至目前,没有人尝试在阿拉伯语中解决这项任务。在本文中,我们介绍了Ar-SParC,第一个阿拉伯语的跨领域、上下文依赖的文本到SQL数据集。该数据集包含3,450个相互关联的问题序列,每个序列包含平均大约三个问题,总计产生10225个问题及其对应的SQL查询。我们对Ar-SParC数据集进行了40次实验,使用了两种大型语言模型,GPT-3.5-turbo和GPT-4.5-turbo,应用了10种不同的提示工程技术,包括四种问题表示方法和六种上下文学习技术。此外,我们开发了一种名为GAT corrector的新方法,该方法在所有40次实验中提升了性能,使零样本设置下的执行准确率(EX)和交互准确率(IX)平均提高了1.9%,在上下文学习设置下平均增加了1.72% EX和0.92% IX。最后,我们进行了两项额外的消融研究,以解释为什么GAT corrector在阿拉伯语中优于之前的GAT verifier技术。

英文摘要:

In recent years, the task of cross-domain, context-dependent text-to-SQL has received significant attention. Enables users with no prior knowledge of SQL to have a conversation with databases using natural language. However, most of the available datasets and research have been conducted in English, along with some work in Chinese. To this date, no effort has been made to address this task in the Arabic language. In this paper, we introduce Ar-SParC, the first Arabic cross-domain, context-dependent text-to-SQL dataset. The dataset consists of 3,450 sequences of interrelated questions, each sequence containing an average of approximately three questions, which results in a total of 10225 questions along with their corresponding SQL queries. We conducted 40 experiments on the Ar-SParC dataset using two large language models, GPT-3.5-turbo and GPT-4.5-turbo, applying 10 different prompt engineering techniques, including four question representation methods and six in-context learning techniques. Furthermore, we developed a novel approach named GAT corrector, which enhanced the performance across all 40 experiments, yielding an average improvement of 1.9% in execution accuracy (EX) and 1.9% in interaction accuracy (IX) under zero-shot settings, and an average increase of 1.72% EX and 0.92% IX under in-context learning settings. Finally, we conducted an ablation study with two more experiments to explain why the GAT corrector outperformed the previous GAT verifier technique, particularly for the Arabic language.

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

↑