semanticagent-eval
SemanticAgent: A Semantics-Aware Framework for Text-to-SQL Data Synthesis — Gao et al. (2026) (arXiv:2604.21414, 2026)
What this evaluates
Evaluates text-to-SQL generation capabilities across cross-domain parsing, knowledge-intensive reasoning, and enterprise-level SQL workflows. It also assesses the semantic validity, execution correctness, and diversity of synthetically generated training data.
Datasets
- Spider — total 10181; splits: dev (-1), test (-1)
- BIRD — total 12751; splits: dev (-1)
- Spider2.0 — total 135; splits: test (135)
- EHRSQL — total ?; splits: (unstated)
- ScienceBenchmark — total ?; splits: (unstated)
- Spider-Syn — total ?; splits: (unstated)
- Spider-Realistic — total ?; splits: (unstated)
- Spider-DK — total ?; splits: (unstated)
Metrics
test-suite accuracy (TS) (primary) — range: [0, 1]
- Fraction of predictions that match the gold execution results across all provided test databases for a given schema.
execution accuracy (EX) (primary) — range: [0, 1]
- Fraction of predictions whose execution results match the gold execution result on a single database.
Semantic Alignment (SA) — range: [0, 1]
- LLM-based consistency score measuring semantic alignment between the natural language question and the generated SQL query.
Successful Execution Rate (SER) — range: [0, 1]
- Proportion of synthesized SQL queries that execute without syntax or runtime errors.
Input / output format
Input: Natural language question paired with database schema information (table names, column names, and sampled cell values).
Output: A single SQL query string.
Scoring recipe
def compute_accuracy(predictions, golds, db):
correct = 0
for pred, gold in zip(predictions, golds):
if execute_sql(pred, db) == execute_sql(gold, db):
correct += 1
return correct / len(predictions)
# For TS, iterate over multiple test databases per schema and require match on all.
Common pitfalls
- Synthetic data contamination: generated examples may accidentally overlap with public evaluation splits; requires n-gram filtering against the eval set.
- Execution vs. semantic correctness: standard EX/TS metrics only verify syntactic/execution equivalence, not whether the SQL actually answers the natural language question semantically.
- Schema-only generation constraint: synthetic data is built exclusively from schema structures and sampled cells without using gold question-SQL pairs, altering the data distribution compared to standard fine-tuning.
Evidence (verbatim from paper)
Spider (dev), Spider-Syn, and Spider-Realistic are evaluated with test-suite accuracy (TS), while the remaining benchmarks are evaluated with execution accuracy (EX). EX compares execution results on a single database, whereas TS evaluates predictions over multiple test databases.
Citation
@misc{gao2026semanticagent,
title={SemanticAgent: A Semantics-Aware Framework for Text-to-SQL Data Synthesis},
author={Gao et al. (2026)},
year={2026},
note={arXiv:2604.21414}
}
1---2name: semanticagent-eval3description: Evaluates text-to-SQL generation capabilities across cross-domain parsing, knowledge-intensive reasoning, and enterprise-level SQL workflows. It also assesses the semantic validity, execution correctness, and diversity of synthetically generated training data. Use when the user wants to benchmark on Spider, BIRD, Spider2.0, EHRSQL, ScienceBenchmark, Spider-Syn, Spider-Realistic, Spider-DK, or asks about evaluating this task. Reports test-suite accuracy (TS), execution accuracy (EX).4---56# semanticagent-eval78> SemanticAgent: A Semantics-Aware Framework for Text-to-SQL Data Synthesis — Gao et al. (2026) (arXiv:2604.21414, 2026)910## What this evaluates1112Evaluates text-to-SQL generation capabilities across cross-domain parsing, knowledge-intensive reasoning, and enterprise-level SQL workflows. It also assesses the semantic validity, execution correctness, and diversity of synthetically generated training data.1314## Datasets1516- **Spider** — total 10181; splits: dev (-1), test (-1)17- **BIRD** — total 12751; splits: dev (-1)18- **Spider2.0** — total 135; splits: test (135)19- **EHRSQL** — total ?; splits: (unstated)20- **ScienceBenchmark** — total ?; splits: (unstated)21- **Spider-Syn** — total ?; splits: (unstated)22- **Spider-Realistic** — total ?; splits: (unstated)23- **Spider-DK** — total ?; splits: (unstated)2425## Metrics2627- `test-suite accuracy (TS)` **(primary)** — range: [0, 1]28 - Fraction of predictions that match the gold execution results across all provided test databases for a given schema.29- `execution accuracy (EX)` **(primary)** — range: [0, 1]30 - Fraction of predictions whose execution results match the gold execution result on a single database.31- `Semantic Alignment (SA)` — range: [0, 1]32 - LLM-based consistency score measuring semantic alignment between the natural language question and the generated SQL query.33- `Successful Execution Rate (SER)` — range: [0, 1]34 - Proportion of synthesized SQL queries that execute without syntax or runtime errors.3536## Input / output format3738**Input**: Natural language question paired with database schema information (table names, column names, and sampled cell values).3940**Output**: A single SQL query string.4142## Scoring recipe4344```python45def compute_accuracy(predictions, golds, db):46 correct = 047 for pred, gold in zip(predictions, golds):48 if execute_sql(pred, db) == execute_sql(gold, db):49 correct += 150 return correct / len(predictions)51# For TS, iterate over multiple test databases per schema and require match on all.52```5354## Common pitfalls5556- Synthetic data contamination: generated examples may accidentally overlap with public evaluation splits; requires n-gram filtering against the eval set.57- Execution vs. semantic correctness: standard EX/TS metrics only verify syntactic/execution equivalence, not whether the SQL actually answers the natural language question semantically.58- Schema-only generation constraint: synthetic data is built exclusively from schema structures and sampled cells without using gold question-SQL pairs, altering the data distribution compared to standard fine-tuning.5960## Evidence (verbatim from paper)6162> Spider (dev), Spider-Syn, and Spider-Realistic are evaluated with test-suite accuracy (TS), while the remaining benchmarks are evaluated with execution accuracy (EX). EX compares execution results on a single database, whereas TS evaluates predictions over multiple test databases.6364## Citation6566```bibtex67@misc{gao2026semanticagent,68 title={SemanticAgent: A Semantics-Aware Framework for Text-to-SQL Data Synthesis},69 author={Gao et al. (2026)},70 year={2026},71 note={arXiv:2604.21414}72}73```7475- arXiv: 2604.21414