arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2306.04480cs.CL
收藏

探索上下文依赖 Text-to-SQL 解析中的组合泛化

Exploring the Compositional Generalization in Context Dependent Text-to-SQL Parsing

Tsinghua University(清华大学)

Aiwei Liu, Wei Liu, Xuming Hu, Shuang Li, Fukun Ma, Yawen Yang, Lijie Wen

AI总结:

本文首次研究上下文依赖 Text-to-SQL 的组合泛化,构建 CoSQL-CG 与 SParC-CG 基准,并提出 p-align 通过对齐历史 SQL 与当前话语提升模型泛化性能。

摘要:

在上下文依赖的 Text-to-SQL 任务中,生成的 SQL 语句会根据每次交互中的用户输入话语进行迭代细化。每次交互的输入文本都可视为对先前 SQL 语句的组件修改,这些修改还可进一步提取为修改模式。由于这些修改模式也可以与其他 SQL 语句组合,模型应当具备针对这些新颖组合的组合泛化能力。本工作首次探索了上下文依赖 Text-to-SQL 场景中的组合泛化。为促进相关研究,我们通过重新组合修改模式与现有 SQL 语句,构建了两个具有挑战性的基准,分别命名为 CoSQL-CG 和 SParC-CG。随后的实验表明,当前所有模型在我们提出的基准上都表现不佳。此外,我们发现更好地将先前 SQL 语句与输入话语对齐,能够赋予模型更强的组合泛化能力。基于这些观察,我们提出了一种名为 p-align 的方法,以提升 Text-to-SQL 模型的组合泛化能力。进一步实验验证了该方法的有效性。源代码和数据均已公开。

英文摘要:

In the context-dependent Text-to-SQL task, the generated SQL statements are refined iteratively based on the user input utterance from each interaction. The input text from each interaction can be viewed as component modifications to the previous SQL statements, which could be further extracted as the modification patterns. Since these modification patterns could also be combined with other SQL statements, the models are supposed to have the compositional generalization to these novel combinations. This work is the first exploration of compositional generalization in context-dependent Text-to-SQL scenarios. To facilitate related studies, we constructed two challenging benchmarks named \textsc{CoSQL-CG} and \textsc{SParC-CG} by recombining the modification patterns and existing SQL statements. The following experiments show that all current models struggle on our proposed benchmarks. Furthermore, we found that better aligning the previous SQL statements with the input utterance could give models better compositional generalization ability. Based on these observations, we propose a method named \texttt{p-align} to improve the compositional generalization of Text-to-SQL models. Further experiments validate the effectiveness of our method. Source code and data are available.

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

↑