SQL-Checker: Error Detection and Labeling for Text-to-SQL with Interpretability Analysis
Xingyu Ma, Xin Tian, Lingxiang Wu, Xuepeng Wang, Xueming Tang, Jinqiao Wang
摘要
Text-to-SQL technology converts natural language queries into SQL statements for database retrieval. Recent advances in large language models (LLMs) have improved Text-to-SQL performance, but generated SQL often contains semantic or syntax errors that degrade user experience and system stability. Existing SQL error detection methods are costly, lack interpretability, and do not support error labeling. To overcome these issues, we propose SQL-Checker a specialized model for Text-to-SQL error detection. We first analyze common error factors in Text-to-SQL, and we design a novel data synthesis framework based on these error factors. This framework simulates error factors to construct a basic error SQL data, and then using an error analysis template to distill high-quality SQL error analysis data from large-scale models. For complex errors, a self-guided iterative distillation strategy further enhances data quality. SQL-Checker is then trained on this distilled dataset. Additionally, we refine SQL error labeling and, integrate error label recognition into the detection task, enabling macro-level cause analysis. Experiments show SQL-Checker achieves state-of-the-art results on multiple error detection datasets. Incorporating SQL-Checker into the Text-to-SQL pipeline also improves execution accuracy.
问问这篇 Paper
问问你的智能体。
Lune 读过与它相关的顶会 Paper,每个回答都会注明依据哪几篇。
相关 Paper
- SQLens: An End-to-End Framework for Error Detection and Correction in Text-to-SQLYue Gong, Chuan Lei, Xiao Qin, Kapil Vaidya 等NeurIPS 2025 · 被引用 21 次
- ErrorLLM: Modeling SQL Errors for Text-to-SQL RefinementZijin Hong, Hao Chen, Zheng Yuan, Qinggang Zhang 等KDD 2026 · 被引用 3 次
- Structure-Guided Large Language Models for Text-to-SQL GenerationQinggang Zhang, Hao Chen, Junnan Dong, Shengyuan Chen 等ICML 2025
- Developing and Benchmarking Verification Algorithms to Improve Text-to-SQL GenerationTarfah Alrashed, Madhup Sukoon, David R. Karger, Natasha F. NoyVLDB 2026
- Understanding, Detecting, and Repairing Real-World In-Context-Learning-Based Text-to-SQL ErrorsJiawei Shen, Chengcheng Wan, Ruoyi Qiao, Jiazhen Zou 等FSE 2026 · 被引用 1 次
