Diverse Parallel Data Synthesis for Cross-Database Adaptation of Text-to-SQL Parsers

Abhijeet Awasthi, Ashutosh Sathe, Sunita Sarawagi


Abstract
Text-to-SQL parsers typically struggle with databases unseen during the train time. Adapting Text-to-SQL parsers to new database schemas is a challenging problem owing to a vast diversity of schemas and zero availability of natural language queries in new schemas. We present ReFill, a framework for synthesizing high-quality and textually diverse parallel datasets for adapting Text-to-SQL parsers. Unlike prior methods that utilize SQL-to-Text generation, ReFill learns to retrieve-and-edit text queries in existing schemas and transfer them to the new schema. ReFill utilizes a simple method for retrieving diverse existing text, masking their schema-specific tokens, and refilling with tokens relevant to the new schema. We show that this process leads to significantly more diverse text queries than achievable by standard SQL-to-Text generation models. Through experiments on several databases, we show that adapting a parser by finetuning it on datasets synthesized by ReFill consistently outperforms prior data-augmentation methods.
Anthology ID:
2022.emnlp-main.794
Volume:
Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing
Month:
December
Year:
2022
Address:
Abu Dhabi, United Arab Emirates
Editors:
Yoav Goldberg, Zornitsa Kozareva, Yue Zhang
Venue:
EMNLP
SIG:
Publisher:
Association for Computational Linguistics
Note:
Pages:
11548–11562
Language:
URL:
https://aclanthology.org/2022.emnlp-main.794
DOI:
10.18653/v1/2022.emnlp-main.794
Bibkey:
Cite (ACL):
Abhijeet Awasthi, Ashutosh Sathe, and Sunita Sarawagi. 2022. Diverse Parallel Data Synthesis for Cross-Database Adaptation of Text-to-SQL Parsers. In Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing, pages 11548–11562, Abu Dhabi, United Arab Emirates. Association for Computational Linguistics.
Cite (Informal):
Diverse Parallel Data Synthesis for Cross-Database Adaptation of Text-to-SQL Parsers (Awasthi et al., EMNLP 2022)
Copy Citation:
PDF:
https://aclanthology.org/2022.emnlp-main.794.pdf