Our new X account is live! Follow @wizwand_team for updates
WorkDL logo mark

Editing-Based SQL Query Generation for Cross-Domain Context-Dependent Questions

About

We focus on the cross-domain context-dependent text-to-SQL generation task. Based on the observation that adjacent natural language questions are often linguistically dependent and their corresponding SQL queries tend to overlap, we utilize the interaction history by editing the previous predicted query to improve the generation quality. Our editing mechanism views SQL as sequences and reuses generation results at the token level in a simple manner. It is flexible to change individual tokens and robust to error propagation. Furthermore, to deal with complex table structures in different domains, we employ an utterance-table encoder and a table-aware decoder to incorporate the context of the user utterance and the table schema. We evaluate our approach on the SParC dataset and demonstrate the benefit of editing compared with the state-of-the-art baselines which generate SQL from scratch. Our code is available at https://github.com/ryanzhumich/sparc_atis_pytorch.

Rui Zhang, Tao Yu, He Yang Er, Sungrok Shim, Eric Xue, Xi Victoria Lin, Tianze Shi, Caiming Xiong, Richard Socher, Dragomir Radev• 2019

Related benchmarks

TaskDatasetResultRank
Text-to-SQLSpider (test)
Execution Accuracy53.4
140
Text-to-SQLSpider (dev)--
100
Text-to-SQLSpider 1.0 (dev)
Exact Match Accuracy57.6
92
Text-to-SQLSpider 1.0 (test)
EM Acc (Overall)53.4
91
Context-dependent Text-to-SQLSParC 1.0 (dev)
Question Match53.4
27
Context-dependent Text-to-SQLCoSQL (dev)
Question Match39.9
22
Context-dependent Text-to-SQLSParC 1.0 (test)
Question Match54.5
12
Context-dependent Text-to-SQLSParC (test)
Question Match47.9
12
Context-dependent Text-to-SQLCoSQL (test)
Question Match40.8
12
Semantic ParsingATIS (dev)
Query Acc36.2
10
Showing 10 of 24 rows

Other info

Code

Follow for update