Introduction
Translating natural language (NL) questions into executable SQL queries is essential for democratizing data access. Historically, standard sequence-to-sequence (seq2seq) models have struggled with this task due to token interchangeability in SQL, a lack of inherent structural constraints, and the difficulty of mapping natural language terms to specific database schema columns (schema linking).
To circumvent these issues, many researchers shifted toward complex "sketch-based" architectures that fill pre-defined slots. SeaD (Schema-aware Denoising) challenges this trend by demonstrating that vanilla Transformer-based seq2seq models can achieve state-of-the-art results when equipped with robust training objectives designed to handle schema noise and structural logic.
Methodology
SeaD utilizes an end-to-end Transformer model with a Hybrid Pointer Generator, allowing it to either generate standard SQL keywords or copy specific column names and values directly from the input. The model's performance is primarily driven by two novel schema-aware denoising objectives:
- Shuffle: The order of entities in the NL question or SQL query is randomly permuted during training. This teaches the model that while certain SQL clauses are interchangeable, the underlying relationships between data entities remain constant.
- Erosion: The model is presented with a corrupted schema where columns are randomly dropped or added. If a required column is missing, the model must output an
<unk>(unknown) token.
By learning from the absence of data, the model develops a sophisticated "exception handling" mechanism, ensuring it only maps questions to columns when a valid relationship exists. Additionally, the authors introduce Clause-sensitive Execution-Guided (EG) Decoding, which dynamically adjusts the search beam size based on the complexity of the SQL clause being generated (e.g., allocating more resources to the WHERE clause than the SELECT clause).
Evaluation and Results
The model was evaluated on WikiSQL, the largest human-annotated dataset for Text-to-SQL, containing over 80,000 question-query pairs. SeaD achieved a new state-of-the-art for models not relying on massive external table content.
As shown in the results table, SeaD+EG$_{CS}$ achieved a Logic Form Accuracy of 87.1% and an Execution Accuracy of 92.7% on the test set. Ablation studies confirmed the importance of the denoising tasks; removing the "Erosion" objective alone resulted in a 1.5% drop in accuracy, highlighting its role in robust schema linking.
Discussion and Future Work
SeaD proves that the perceived limitations of seq2seq models in Text-to-SQL are not inherent to the architecture but are often a byproduct of insufficient training objectives. By introducing structural and schema-aware noise, the model learns the underlying grammar of SQL without hard-coded constraints.
While highly effective on the single-table queries of WikiSQL, a primary area for future work is scaling this denoising approach to multi-table "Join" queries found in more complex benchmarks like Spider. The authors also suggest that "noise re-weighting"—dynamically adjusting the difficulty of denoising tasks during training—could further enhance model robustness.
Summary updated