Text-to-SQL aims to map natural language questions to SQL queries. The sketch-based method combined with execution-guided (EG) decoding strategy has shown a strong performance on the WikiSQL benchmark. However, execution-guided decoding relies on database execution, which significantly slows down the inference process and is hence unsatisfactory for many real-world applications. In this paper, we present the Schema Dependency guided multi-task Text-to-SQL model (SDSQL) to guide the network to effectively capture the interactions between questions and schemas. The proposed model outperforms all existing methods in both the settings with or without EG. We show the schema dependency learning partially cover the benefit from EG and alleviates the need for it. SDSQL without EG significantly reduces time consumption during inference, sacrificing only a small amount of performance and provides more flexibility for downstream applications.
翻译:文本到 SQL 旨在将自然语言问题映射到 SQL 查询中。 基于草图的方法,加上执行指南解码战略,在 WikisQL 基准上表现良好。然而,执行指南解码依赖数据库执行,这大大减缓了推断过程,因此许多真实世界应用程序不能令人满意。在本文件中,我们介绍了Schema 依赖性指导多任务文本到 SQL 模型(SDSQL 模型), 以指导网络有效捕捉问题和系统之间的相互作用。 拟议的模型在设置中,无论是否使用EG,都超越了所有现有方法。 我们展示了Schema依赖性学习部分覆盖了EG的好处,并减轻了对它的需求。 SDSQL 不使用 EG 大大缩短了推断过程中的时间消耗,只牺牲了少量的性能,并为下游应用程序提供了更大的灵活性。