大语言模型时代下的文本到SQL调研:我们目前在哪里,未来将去向何处?
A Survey of Text-to-SQL in the Era of LLMs: Where are we, and where are we going?
AI总结:
本文综述了大语言模型时代下文本到SQL技术的发展现状、核心方法及未来挑战。
摘要:
将用户自然语言查询(NL)转换为SQL查询(即文本到SQL,简称NL2SQL)可以显著降低访问关系数据库的障碍,并支持各种商业应用。随着大语言模型(LLMs)的出现,文本到SQL的性能得到了显著提升。在本文的综述中,我们全面回顾了由LLMs驱动的文本到SQL技术,涵盖其整个生命周期,从以下四个方面进行:(1)模型:处理NL模糊性和不充分性,并正确映射NL与数据库模式和实例的文本到SQL转换技术;(2)数据:从训练数据的收集、由于训练数据稀缺导致的数据合成,到文本到SQL基准;(3)评估:使用不同的度量标准和粒度从多个角度评估文本到SQL方法;(4)错误分析:分析文本到SQL错误以找到根本原因,并指导文本到SQL模型进化。此外,我们还提供了一条开发文本到SQL解决方案的规则。最后,我们讨论了在LLMs时代文本到SQL的研究挑战和开放问题。文本到SQL手册:https://github.com/HKUSTDial/NL2SQL手册
英文摘要:
Translating users' natural language queries (NL) into SQL queries (i.e., Text-to-SQL, a.k.a. NL2SQL) can significantly reduce barriers to accessing relational databases and support various commercial applications. The performance of Text-to-SQL has been greatly enhanced with the emergence of Large Language Models (LLMs). In this survey, we provide a comprehensive review of Text-to-SQL techniques powered by LLMs, covering its entire lifecycle from the following four aspects: (1) Model: Text-to-SQL translation techniques that tackle not only NL ambiguity and under-specification, but also properly map NL with database schema and instances; (2) Data: From the collection of training data, data synthesis due to training data scarcity, to Text-to-SQL benchmarks; (3) Evaluation: Evaluating Text-to-SQL methods from multiple angles using different metrics and granularities; and (4) Error Analysis: analyzing Text-to-SQL errors to find the root cause and guiding Text-to-SQL models to evolve. Moreover, we offer a rule of thumb for developing Text-to-SQL solutions. Finally, we discuss the research challenges and open problems of Text-to-SQL in the LLMs era. Text-to-SQL Handbook: https://github.com/HKUSTDial/NL2SQL_Handbook
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。