REVIEW 2 major objections 6 minor 38 references
Correctness uncertainty for text-to-SQL lives in reasoning-based verification, not sampling agreement or log-probability.
Reviewed by Pith at T0; open to challenge. T0 means a machine referee read the full paper against a public rubric. the ladder, T0–T4 →
T0 review · grok-4.5
2026-07-10 21:04 UTC pith:EF7H7GEU
load-bearing objection Solid empirical ranking study: black-box UQ plateaus ~0.61–0.68 AUROC on hard multi-table SQL while multi-provider verification clears it and enables real abstention; transfer claim is scoped but still the softest part. the 2 major comments →
What Predicts Correctness in Text-to-SQL? A Selective-Prediction Study
The pith
A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.
Core claim
On hard multi-table text-to-SQL, black-box statistical signals and white-box log-probability form a correctness ceiling of roughly 0.61–0.68 AUROC, while LLM-as-judge verification exceeds it (up to about 0.78 alone and 0.82 for a calibrated two-provider ensemble). The pattern holds across two benchmarks, two generators, and two judge providers. Fine-tuned verifiers reach high in-domain AUROC but collapse on leave-one-database-out transfer, so cross-schema correctness prediction currently tracks model scale and reasoning rather than fine-tuning.
What carries the argument
AUROC ranking of candidate SQL correctness, grounded in execution match to a human reference, used to compare black-box self-consistency signals against logic-aware LLM judges and to measure selective-prediction risk–coverage frontiers.
Load-bearing premise
The claim that cross-schema transfer tracks reasoning scale rather than fine-tuning rests on leave-one-database-out tests over a modest number of schemas and generative verifiers no larger than 7B.
What would settle it
Train a larger generative verifier (or one trained on far more diverse schemas) and re-run leave-one-database-out transfer: if transfer AUROC rises to match a strong frozen judge, the open-versus-in-domain deployment split collapses.
Editorial analysis
A structured set of objections, weighed in public.
Referee Report
Summary. The paper studies which signals predict execution correctness of generated SQL on hard multi-table text-to-SQL (BIRD and Spider), framing the problem as selective prediction. Black-box statistical signals (string, structural, and execution self-consistency, schema relevance, executability) and white-box log-probability occupy a narrow band of roughly 0.61–0.68 AUROC, with string self-consistency strongest at 0.675. LLM-as-judge verifiers clear that band (0.72–0.78 alone; 0.82 for a cross-fit two-provider ensemble with ECE 0.03) and yield usable risk–coverage frontiers that self-consistency cannot match. Fine-tuned encoder and generative verifiers reach ~0.77–0.79 AUROC in-distribution but fall to ~0.66 under leave-one-database-out transfer; scale to 7B, schema diversity, rationale distillation, and cross-benchmark training do not close the gap. The authors conclude that correctness uncertainty lives in reasoning-based signals, with fine-tuned verifiers useful in-domain and large frozen judges preferred for open/cross-schema use.
Significance. If the comparative ranking holds, the paper gives practitioners a clear, execution-grounded map of which UQ signals are worth paying for in text-to-SQL: sampling agreement and log-probability are weak correctness predictors on multi-table data, while logic-aware verification (especially multi-provider ensembles) enables calibrated abstention. The separation of selective prediction from self-correction, the paired-bootstrap AUROC comparisons, ECE, held-out risk–coverage, and LODO transfer ablations are concrete strengths. The work is timely for high-stakes database interfaces and complements agentic self-correction literature by asking when to trust a final query rather than how to improve it. The in-domain vs open-schema deployment split is a useful practical message even if the transfer evidence remains limited in scale.
major comments (2)
- [Section 4.4, Table 4, Appendix A, Discussion] Section 4.4, Table 4, Appendix A, and Discussion: the claim that “cross-schema transfer appears to track model scale and reasoning rather than fine-tuning” is only weakly supported by the reported experiments. LODO is run on 8–28 schemas with generative judges up to 7B; the frozen GPT-4o/Claude judges that transfer better are far larger and differently pretrained, so scale, reasoning ability, and model family are confounded. The negative ablations (diversity, distillation, cross-benchmark) are informative but do not isolate the causal claim. Soften the wording to what the data show—current fine-tunes up to 7B fail to transfer on these schema sets—and treat the open-vs-in-domain split as a practical recommendation under present evidence rather than a settled mechanism.
- [Section 3, Tables 1–3, Table 6] Section 3 and Tables 1–3: all primary BIRD numbers are on a fixed 800-question slice over 8 databases, scoring the modal query among K=8 samples. The Spider replication and second-generator check reduce the risk that the black-box ceiling is slice-specific, but the absolute AUROC band (0.61–0.68) and the selective-prediction coverages in Table 6 still depend on this design. Please report sensitivity of the ceiling and ensemble AUROC to (i) non-modal selection (e.g., highest-logprob or random sample) and (ii) a second independent BIRD slice or full available multi-table set, so readers can judge how tightly the “ceiling” is tied to the modal-query / fixed-slice protocol.
minor comments (6)
- [Table 7, Section 4.6] Table 7: the GROUP BY row is the only feature subset where the verifier underperforms string self-consistency (0.609 vs 0.651). A short discussion of why (e.g., grouping errors that are hard for the judge prompt, or small n) would help readers interpret the exception.
- [Figure 1, Section 4.4] Figure 1 is referenced for per-database transfer but the manuscript text does not state how many questions per held-out database or whether error bars are shown; add n per bar and, if possible, bootstrap intervals so the “leads on every schema” claim is visually checkable.
- [Section 4.3, Appendix B] Section 4.3 self-correction baseline: one reflection round with GPT-4o-mini is a useful negative control, but the prompt and revision protocol are not in Appendix B. Include them for reproducibility.
- [Abstract, Introduction, Tables] Abstract and Introduction use “auroc” in lowercase inconsistently with standard AUROC; pick one capitalization and stick to it. Also fix the spacing glitches such as “0 .68”, “0 .78”, “0 .66” that appear throughout.
- [Section 2] Related work cites conformal abstention and schema-linking graph models but does not position the present selective-prediction results against DIN-SQL / MAC-SQL style agentic pipelines beyond the one-round reflection check. A short paragraph clarifying complementarity would help.
- [Section 6] Limitations correctly note the lack of an open-weight generator; if space allows, even a small open-weight generator check (or an explicit “left to future work” with expected failure modes) would strengthen the multi-family claim.
Circularity Check
No significant circularity: empirical ranking of independent signals against execution-match labels, with cross-fit calibration and LODO transfer.
full rationale
This paper is a comparative empirical study, not a derivation of a first-principles quantity from fitted inputs. Correctness is the external benchmark definition (generated SQL result set matches the human reference). Black-box signals (string/structural/execution self-consistency, schema relevance, executability, log-probability) are computed from samples or model internals without using the correctness label, then ranked by AUROC against that label. LLM judges produce independent scores that are likewise evaluated against execution ground truth; the two-provider ensemble is cross-fit logistic so the combiner is never scored on its own fit data. Fine-tuned verifiers are trained on labeled pairs and evaluated with leave-one-database-out transfer. Thresholds for selective risk are chosen on a calibration half and reported on a disjoint test half. There are no self-definitional identities, no fitted parameters renamed as predictions of the same quantity, no load-bearing self-citations or uniqueness theorems imported from the author, and no ansatz smuggled in via citation. Standard use of Spider/BIRD reference queries as ground truth is ordinary benchmark practice, not circularity under this framework. The derivation chain is self-contained against external execution labels.
Axiom & Free-Parameter Ledger
free parameters (5)
- K samples per question
- BIRD evaluation slice size and databases
- Cross-fit logistic ensemble / calibration
- Selective-risk target grid and split
- Fine-tune training set size and LoRA setup
axioms (5)
- domain assumption A generated query is correct iff its execution result set matches the human reference query on the database.
- domain assumption AUROC of a score against execution correctness is the right primary ranking metric for comparing uncertainty signals.
- ad hoc to paper The modal query among K samples is the right unit to score for selective prediction.
- ad hoc to paper Leave-one-database-out macro AUROC on the studied schema sets measures cross-schema transfer of verifiers.
- standard math Paired bootstrap CIs and cross-fit logistic combination yield valid comparisons without test leakage.
invented entities (1)
-
black-box correctness ceiling (≈0.61–0.68 AUROC band)
no independent evidence
read the original abstract
Evaluating uncertainty in AI-generated SQL queries requires estimating whether a query is correct, where correct means it executes to the same result as a human-written reference. We study which signals predict correctness on hard multi-table text-to-SQL, using AUROC to measure how well each ranks correct queries above incorrect ones. On BIRD and Spider, black-box signals such as string, structural, and execution self-consistency, a schema-relevance score, and query executability all fall between about 0.61 and 0.68 AUROC, with string self-consistency strongest at 0.675; white-box log-probability is similar (0.67). The signals that move past this ceiling are verification-based: an LLM judge scores from 0.72 (GPT-4o-mini) to 0.78 (Claude). Judges from different providers make different errors, so a two-provider ensemble reaches 0.82 AUROC with a well-calibrated probability (expected calibration error 0.03) and supports useful abstention frontiers (for example, answering 27% of questions at 24% selective risk) where self-consistency offers no valid low-risk subset. The pattern holds across two benchmarks, two generators, and two judge providers. We also ask whether a verifier can be trained. Fine-tuned verifiers, both encoder and generative, reach about 0.77 to 0.79 AUROC in-distribution but fall to about 0.66 on unseen schemas; scaling to 7B, adding schema diversity, distilling a strong judge's rationales, and cross-benchmark training all fail to close that gap. Cross-schema transfer appears to track model scale and reasoning rather than fine-tuning. In practice, correctness uncertainty for text-to-SQL lives in reasoning-based signals: a fine-tuned verifier is a good in-domain tool, but a verifier that generalizes across schemas currently means a large frozen reasoning model.
Figures
Reference graph
Works this paper leans on
-
[1]
Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Task , author=. EMNLP , year=
-
[2]
Spider 2.0: Evaluating Language Models on Real-World Enterprise Text-to-SQL Workflows , author=. ICLR , year=
-
[3]
NeurIPS Datasets and Benchmarks , year=
Can LLM Already Serve as a Database Interface? A Big Bench for Large-Scale Database Grounded Text-to-SQLs (BIRD) , author=. NeurIPS Datasets and Benchmarks , year=
-
[4]
RAT-SQL: Relation-Aware Schema Encoding and Linking for Text-to-SQL Parsers , author=. ACL , year=
-
[5]
LGESQL: Line Graph Enhanced Text-to-SQL Model with Mixed Local and Non-Local Relations , author=. ACL , year=
-
[6]
Self-Consistency Improves Chain of Thought Reasoning in Language Models , author=. ICLR , year=
-
[7]
Semantic Uncertainty: Linguistic Invariances for Uncertainty Estimation in Natural Language Generation , author=. ICLR , year=
-
[8]
Detecting Hallucinations in Large Language Models Using Semantic Entropy , author=. Nature , volume=
-
[9]
The Annals of Probability , volume=
The Two-Parameter Poisson--Dirichlet Distribution Derived from a Stable Subordinator , author=. The Annals of Probability , volume=
-
[10]
A Hierarchical Bayesian Language Model Based on Pitman--Yor Processes , author=. ACL , year=
-
[11]
Advances in Neural Information Processing Systems (NIPS) , pages=
Adaptor Grammars: A Framework for Specifying Compositional Nonparametric Bayesian Models , author=. Advances in Neural Information Processing Systems (NIPS) , pages=
-
[12]
The Population Frequencies of Species and the Estimation of Population Parameters , author=. Biometrika , volume=
- [13]
-
[14]
Selective Classification for Deep Neural Networks , author=. NeurIPS , year=
-
[17]
Proceedings of the ACM on Management of Data (SIGMOD) , year=
Reliable Text-to-SQL with Adaptive Abstention , author=. Proceedings of the ACM on Management of Data (SIGMOD) , year=
-
[18]
Calibrating Large Language Models for Text-to-SQL , author=. arXiv preprint , year=
-
[19]
Advances in Neural Information Processing Systems (NeurIPS) , year=
Reflexion: Language Agents with Verbal Reinforcement Learning , author=. Advances in Neural Information Processing Systems (NeurIPS) , year=
-
[20]
International Conference on Learning Representations (ICLR) , year=
Teaching Large Language Models to Self-Debug , author=. International Conference on Learning Representations (ICLR) , year=
-
[21]
Pourreza, Mohammadreza and Rafiei, Davood , booktitle=
-
[22]
Wang, Bing and Ren, Changyu and Yang, Jian and others , journal=
-
[23]
Learn then Test: Calibrating Predictive Algorithms to Achieve Risk Control
Anastasios N. Angelopoulos, Stephen Bates, Emmanuel J. Cand \`e s, Michael I. Jordan, and Lihua Lei. Learn then test: Calibrating predictive algorithms to achieve risk control. arXiv preprint arXiv:2110.01052, 2021
work page internal anchor Pith review Pith/arXiv arXiv 2021
-
[24]
Anastasios N. Angelopoulos, Stephen Bates, Adam Fisch, Lihua Lei, and Tal Schuster. Conformal risk control. arXiv preprint arXiv:2208.02814, 2023
work page internal anchor Pith review Pith/arXiv arXiv 2023
-
[25]
Lgesql: Line graph enhanced text-to-sql model with mixed local and non-local relations
Ruisheng Cao, Lu Chen, Zhi Chen, Yanbin Zhao, Su Zhu, and Kai Yu. Lgesql: Line graph enhanced text-to-sql model with mixed local and non-local relations. In ACL, 2021
work page 2021
-
[26]
Teaching large language models to self-debug
Xinyun Chen, Maxwell Lin, Nathanael Sch \"a rli, and Denny Zhou. Teaching large language models to self-debug. In International Conference on Learning Representations (ICLR), 2024
work page 2024
-
[27]
Detecting hallucinations in large language models using semantic entropy
Sebastian Farquhar, Jannik Kossen, Lorenz Kuhn, and Yarin Gal. Detecting hallucinations in large language models using semantic entropy. Nature, 630 0 (8017): 0 625--630, 2024
work page 2024
-
[28]
Selective classification for deep neural networks
Yonatan Geifman and Ran El-Yaniv. Selective classification for deep neural networks. In NeurIPS, 2017
work page 2017
-
[29]
Chuan Guo, Geoff Pleiss, Yu Sun, and Kilian Q. Weinberger. On calibration of modern neural networks. In ICML, 2017
work page 2017
-
[30]
Lorenz Kuhn, Yarin Gal, and Sebastian Farquhar. Semantic uncertainty: Linguistic invariances for uncertainty estimation in natural language generation. In ICLR, 2023
work page 2023
-
[31]
Spider 2.0: Evaluating language models on real-world enterprise text-to-sql workflows
Fangyu Lei et al. Spider 2.0: Evaluating language models on real-world enterprise text-to-sql workflows. In ICLR, 2025
work page 2025
-
[32]
Jinyang Li et al. Can llm already serve as a database interface? a big bench for large-scale database grounded text-to-sqls (bird). In NeurIPS Datasets and Benchmarks, 2023
work page 2023
-
[33]
DIN-SQL : Decomposed in-context learning of text-to-sql with self-correction
Mohammadreza Pourreza and Davood Rafiei. DIN-SQL : Decomposed in-context learning of text-to-sql with self-correction. In Advances in Neural Information Processing Systems (NeurIPS), 2023
work page 2023
-
[34]
Calibrating large language models for text-to-sql
Ashwin Ramachandran and Sunita Sarawagi. Calibrating large language models for text-to-sql. arXiv preprint, 2024
work page 2024
-
[35]
Reflexion: Language agents with verbal reinforcement learning
Noah Shinn, Federico Cassano, Edward Berman, Ashwin Gopinath, Karthik Narasimhan, and Shunyu Yao. Reflexion: Language agents with verbal reinforcement learning. In Advances in Neural Information Processing Systems (NeurIPS), 2023
work page 2023
-
[36]
Reliable text-to-sql with adaptive abstention
Oleg Somov et al. Reliable text-to-sql with adaptive abstention. In Proceedings of the ACM on Management of Data (SIGMOD), 2025
work page 2025
-
[37]
Rat-sql: Relation-aware schema encoding and linking for text-to-sql parsers
Bailin Wang, Richard Shin, Xiaodong Liu, Oleksandr Polozov, and Matthew Richardson. Rat-sql: Relation-aware schema encoding and linking for text-to-sql parsers. In ACL, 2020
work page 2020
-
[38]
MAC-SQL : A multi-agent collaborative framework for text-to-sql
Bing Wang, Changyu Ren, Jian Yang, et al. MAC-SQL : A multi-agent collaborative framework for text-to-sql. arXiv preprint, 2024
work page 2024
-
[39]
Self-consistency improves chain of thought reasoning in language models
Xuezhi Wang, Jason Wei, Dale Schuurmans, Quoc Le, Ed Chi, et al. Self-consistency improves chain of thought reasoning in language models. In ICLR, 2023
work page 2023
-
[40]
Tao Yu, Rui Zhang, Kai Yang, Michihiro Yasunaga, Dongxu Wang, Zifan Li, et al. Spider: A large-scale human-labeled dataset for complex and cross-domain semantic parsing and text-to-sql task. In EMNLP, 2018
work page 2018
discussion (0)
Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.