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

SQLPrompt:基于最小标注数据的上下文内Text-to-SQL

SQLPrompt: In-Context Text-to-SQL with Minimal Labeled Data

Cloud AI Research Team(云AI研究团队);Google DeepMind(谷歌DeepMind)

Ruoxi Sun, Sercan Ö. Arik, Rajarishi Sinha, Hootan Nakhost, Hanjun Dai, Pengcheng Yin, Tomas Pfister

AI总结:

本研究提出SQLPrompt方法,通过创新提示设计、基于执行的一致性解码及多样化候选SQL策略,大幅提升大模型少样本Text-to-SQL性能,缩小了与大量标注数据微调SOTA模型的差距。

摘要:

Text-to-SQL旨在实现从自然语言文本自动生成数据库SQL查询的过程。本研究提出“SQLPrompt”,专门用于提升大语言模型(LLMs)在Text-to-SQL任务上的少样本提示能力。我们的方法包括创新的提示设计、基于执行的一致性解码策略(该策略从多个候选SQL中选出执行结果最一致的SQL),以及一种通过在一致性选择过程中采用不同提示设计(“MixPrompt”)和基础模型(“MixLLMs”)来丰富候选SQL多样性以提升性能的方法。实验表明,在少标注数据的上下文学习场景下,SQLPrompt大幅优于此前方法,缩小了与使用数千条标注数据的微调SOTA模型的差距。

英文摘要:

Text-to-SQL aims to automate the process of generating SQL queries on a database from natural language text. In this work, we propose "SQLPrompt", tailored to improve the few-shot prompting capabilities of Text-to-SQL for Large Language Models (LLMs). Our methods include innovative prompt design, execution-based consistency decoding strategy which selects the SQL with the most consistent execution outcome among other SQL proposals, and a method that aims to improve performance by diversifying the SQL proposals during consistency selection with different prompt designs ("MixPrompt") and foundation models ("MixLLMs"). We show that \emph{SQLPrompt} outperforms previous approaches for in-context learning with few labeled data by a large margin, closing the gap with finetuning state-of-the-art with thousands of labeled data.

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

↑