SQL Generation via Machine Reading Comprehension

Zeyu Yan, Jianqiang Ma, Yang Zhang, Jianping Shen


Abstract
Text-to-SQL systems offers natural language interfaces to databases, which can automatically generates SQL queries given natural language questions. On the WikiSQL benchmark, state-of- the-art text-to-SQL systems typically take a slot-filling approach by building several specialized models for each type of slot. Despite being effective, such modularized systems are complex and also fall short in jointly learning for different slots. To solve these problems, this paper proposes a novel approach that formulates the task as a question answering problem, where different slots are predicted by a unified machine reading comprehension (MRC) model. For this purpose, we use a BERT-based MRC model, which can also benefit from intermediate training on other MRC datasets. The proposed method can achieve competitive results on WikiSQL, suggesting it being a promising direction for text-to-SQL.
Anthology ID:
2020.coling-main.31
Volume:
Proceedings of the 28th International Conference on Computational Linguistics
Month:
December
Year:
2020
Address:
Barcelona, Spain (Online)
Editors:
Donia Scott, Nuria Bel, Chengqing Zong
Venue:
COLING
SIG:
Publisher:
International Committee on Computational Linguistics
Note:
Pages:
350–356
Language:
URL:
https://aclanthology.org/2020.coling-main.31
DOI:
10.18653/v1/2020.coling-main.31
Bibkey:
Cite (ACL):
Zeyu Yan, Jianqiang Ma, Yang Zhang, and Jianping Shen. 2020. SQL Generation via Machine Reading Comprehension. In Proceedings of the 28th International Conference on Computational Linguistics, pages 350–356, Barcelona, Spain (Online). International Committee on Computational Linguistics.
Cite (Informal):
SQL Generation via Machine Reading Comprehension (Yan et al., COLING 2020)
Copy Citation:
PDF:
https://aclanthology.org/2020.coling-main.31.pdf
Code
 nl2sql/qa-sql
Data
SQuADWikiSQL