Lune

EMNLP2023Top-tier venue

Interactive Text-to-SQL Generation via Editable Step-by-Step Explanations

Yuan Tian, Zheng Zhang, Zheng Ning, Toby Jia-Jun Li, Jonathan K. Kummerfeld, Tianyi Zhang

Abstract

Relational databases play an important role in business, science, and more. However, many users cannot fully unleash the analytical power of relational databases, because they are not familiar with database languages such as SQL. Many techniques have been proposed to automatically generate SQL from natural language, but they suffer from two issues: (1) they still make many mistakes, particularly for complex queries, and (2) they do not provide a flexible way for non-expert users to validate and refine incorrect queries. To address these issues, we introduce a new interaction mechanism that allows users to directly edit a stepby-step explanation of a query to fix errors. Our experiments on multiple datasets, as well as a user study with 24 participants, demonstrate that our approach can achieve better performance than multiple SOTA approaches. Our code and datasets are available at https: //github.com/magic-YuanTian/STEPS .

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

8 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Cerebra: Aligning Implicit Knowledge in Interactive SQL Authoring cites RESDSQL: Decoupling Schema Linking and Skeleton Parsing for Text-to-SQL
  • Cerebra: Aligning Implicit Knowledge in Interactive SQL Authoring cites Sphinteract: Resolving Ambiguities in NL2SQL Through User Interaction
  • Cerebra: Aligning Implicit Knowledge in Interactive SQL Authoring cites SQLucid: Grounding Natural Language Database Queries with Interactive Explanations
  • Cerebra: Aligning Implicit Knowledge in Interactive SQL Authoring cites Graphix-T5: Mixing Pre-trained Transformers with Graph-Aware Layers for Text-to-SQL Parsing
  • Cerebra: Aligning Implicit Knowledge in Interactive SQL Authoring cites Improving Steering and Verification in AI-Assisted Data Analysis with Interactive Task Decomposition
  • Cerebra: Aligning Implicit Knowledge in Interactive SQL Authoring cites Text-to-SQL Empowered by Large Language Models: A Benchmark Evaluation
  • Cerebra: Aligning Implicit Knowledge in Interactive SQL Authoring cites Jupybara: Operationalizing a Design Space for Actionable Data Analysis and Storytelling with LLMs
  • RESDSQL: Decoupling Schema Linking and Skeleton Parsing for Text-to-SQL cites GraPPa: Grammar-Augmented Pre-Training for Table Semantic Parsing
  • Sphinteract: Resolving Ambiguities in NL2SQL Through User Interaction cites Text-to-SQL Empowered by Large Language Models: A Benchmark Evaluation
  • Text-to-SQL Empowered by Large Language Models: A Benchmark Evaluation cites RESDSQL: Decoupling Schema Linking and Skeleton Parsing for Text-to-SQL
  • Text-to-SQL Empowered by Large Language Models: A Benchmark Evaluation cites Graphix-T5: Mixing Pre-trained Transformers with Graph-Aware Layers for Text-to-SQL Parsing
  • Jupybara: Operationalizing a Design Space for Actionable Data Analysis and Storytelling with LLMs cites Improving Steering and Verification in AI-Assisted Data Analysis with Interactive Task Decomposition
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers8

  1. Improving Steering and Verification in AI-Assisted Data Analysis with Interactive Task DecompositionMajeed Kazemitabaar, Jack Williams, Ian Drosos, Tovi Grossman et al.UIST 2024 · 49 citations
  2. SQLucid: Grounding Natural Language Database Queries with Interactive ExplanationsYuan Tian, Jonathan K. Kummerfeld, Toby Jia-Jun Li, Tianyi ZhangUIST 2024 · 13 citations
  3. Sphinteract: Resolving Ambiguities in NL2SQL Through User InteractionFuheng Zhao, Shaleen Deep, Fotis Psallidas, Avrilia Floratou et al.VLDB 2025 · 12 citations
  4. Jupybara: Operationalizing a Design Space for Actionable Data Analysis and Storytelling with LLMsHuichen Will Wang, Larry Birnbaum, Vidya SetlurCHI 2025 · 11 citations
  5. Cerebra: Aligning Implicit Knowledge in Interactive SQL AuthoringYunfan Zhou, Qiming Shi, Zhongsu Luo, Xiwen Cai et al.CHI 2026 · 2 citations

Builds on11

  1. Text-to-SQL Empowered by Large Language Models: A Benchmark EvaluationDawei Gao, Haibin Wang, Yaliang Li, Xiuyu Sun et al.VLDB 2024 · 609 citations
  2. RESDSQL: Decoupling Schema Linking and Skeleton Parsing for Text-to-SQLHaoyang Li, Jing Zhang, Cuiping Li, Hong ChenAAAI 2023 · 343 citations
  3. Graphix-T5: Mixing Pre-trained Transformers with Graph-Aware Layers for Text-to-SQL ParsingJinyang Li, Binyuan Hui, Reynold Cheng, Bowen Qin et al.AAAI 2023 · 164 citations
  4. GraPPa: Grammar-Augmented Pre-Training for Table Semantic ParsingTao Yu, Chien-Sheng Wu, Xi Victoria Lin, Bailin Wang et al.ICLR 2021 · 59 citations
  5. IGSQL: Database Schema Interaction Graph Based Neural Model for Context-Dependent Text-to-SQL GenerationYitao Cai, Xiaojun WanEMNLP 2020 · 41 citations

Related papers

  1. SQLens: An End-to-End Framework for Error Detection and Correction in Text-to-SQLYue Gong, Chuan Lei, Xiao Qin, Kapil Vaidya et al.NeurIPS 2025 · 21 citations
  2. Pi-SQL: Enhancing Text-to-SQL with Fine-Grained Guidance from Pivot Programming LanguagesYongdong Chi, Hanqing Wang, Yun Chen, Yan Yang et al.EMNLP Findings 2025
  3. Know What I don't Know: Handling Ambiguous and Unknown Questions for Text-to-SQLBing Wang, Yan Gao, Zhoujun Li, Jian-Guang LouACL Findings 2023 · 21 citations
  4. MAGIC: Generating Self-Correction Guideline for In-Context Text-to-SQLArian Askari, Christian Pölitz, Xinye TangAAAI 2025 · 44 citations
  5. Speak to your Parser: Interactive Text-to-SQL with Natural Language FeedbackAhmed Elgohary, Saghar Hosseini, Ahmed Hassan AwadallahACL 2020 · 13 citations
Dusk over the sea between two cliffs drawn in fine vertical lines