Elamur Research

Improving Text-to-SQL Evaluation Methodology

Paper · 2018 · Catherine Finegan-Dollak, Jonathan K. Kummerfeld, Li Zhang et al.

Summary

A database assistant can answer an unfamiliar question without constructing an unfamiliar query. The wording may be new, yet the underlying request may match something the assistant encountered during training. Improving Text-to-SQL Evaluation Methodology examines this distinction and shows why it matters for evaluation and benchmarks. A test can establish that a system handles alternative expressions of familiar requests while revealing much less about whether it can assemble SQL for a request with a new structure.

The authors investigate this problem through dataset analysis, data repair, and controlled comparisons of evaluation settings. They standardize existing resources, correct annotation problems, identify equivalent queries, and explicitly mark the values that connect a question to its SQL. They also introduce Advising, a collection of questions about University of Michigan courses over a database containing fictional student records. Across the datasets they examine, questions originating with people require structural features that the large automatically generated collection does not cover, especially joins and nested queries. Their argument is therefore about both the contents of a benchmark and the way its examples are divided.

The central experiment contrasts two kinds of split. A question-based split separates question–query examples, allowing differently worded questions with the same underlying SQL structure to occur in training and testing. A query-based split first replaces entity values with typed variables, groups identical resulting queries, and assigns each group to a single partition. This second arrangement asks whether a system can produce SQL structures absent from training within the same domain. A deliberately restricted baseline makes the distinction concrete: it chooses a training-derived SQL template and fills its slots, so it cannot solve a genuinely new query structure. Nonetheless, it competes strongly with more flexible systems under several conventional splits.

Performance falls substantially when familiar query structures are withheld. Supplying correct entity annotations does not eliminate that difficulty, although it frequently improves results. The paper also shows why evaluating only with anonymized values gives an incomplete picture: recognizing which words denote database values, and determining their types, is itself a substantive part of the task. The authors recommend complementary evaluations across datasets, across both splitting procedures, and with entity names left in place. Their conclusion is not that conventional tests are useless, but that each test supports a narrower claim than a single accuracy score may suggest.

Interesting ideas

Test the claimed capability directly. A benchmark should make the ability named in a research claim necessary for success. If the claim concerns composing unfamiliar structures, holding out fresh wording is insufficient when the required output structure remains familiar. The authors make structural novelty an explicit property of the split. The same reasoning applies wherever many inputs map to a small family of outputs: a test of new expressions and a test of new underlying tasks answer different questions, even when both use previously unseen examples.

Build a baseline with a known ceiling. The template baseline is useful because its limitation is clear before any experiment: it can select and populate stored structures, but cannot create a missing one. Strong results from such a restricted system reveal what a benchmark permits. This is a reusable diagnostic strategy. Instead of judging a benchmark only through sophisticated systems, include a simpler competitor that exploits the suspected shortcut. Its success can expose an evaluation ambiguity more clearly than a small improvement from a more elaborate architecture.

Measure structure alongside collection size. The paper distinguishes question count, distinct queries, abstract SQL patterns, table references, and nesting. These measurements describe different kinds of variety. A collection can contain many examples while repeatedly exercising a narrow construction. In other structured prediction tasks, researchers can similarly inspect the diversity of operations or compositions represented in the targets. Size remains relevant for training, but it should not stand in for an account of what the data actually asks a system to do.

Treat annotation repair as experimental work. Canonical formatting, explicit variable mappings, and checks for equivalent queries make the comparison more interpretable. They also uncover missing or contradictory constraints that would otherwise contaminate both training and evaluation. This lesson extends to any task whose reference outputs admit multiple surface forms. Before attributing errors to a system, establish whether the reference representation is consistent, whether equivalent answers are handled coherently, and whether the input really licenses every constraint in the target.

Separate assisted performance from complete performance. Correct entity annotations isolate part of the SQL construction problem, but they also supply information that a deployed interface must recover for itself. Reporting both assisted and unassisted conditions preserves the usefulness of that simplification without confusing it with complete task performance. The general principle is to name any privileged input and evaluate its practical counterpart as well. Otherwise, an apparently minor preprocessing decision can conceal a major source of uncertainty.

Choose target representations with evaluation in mind. The logical-form comparison shows that output representations can preserve different amounts of linguistic variation. Equivalent requests may collapse to the same SQL while receiving different logical forms. As a consequence, grouping examples by target identity can yield different experimental challenges depending on the representation. Researchers should inspect what their targets identify as the same task before interpreting a structural split as a direct measure of compositional ability.

Deep dive: Improving Text-to-SQL Evaluation Methodology

How text-to-SQL evaluation can confuse familiar query templates with generalization, and how better datasets and splits expose the gap. · about 36 minutes to read

How Mova uses it

For Mova, the small transparent language system written in Rust, the most concrete application is an evaluation design instead of a claim about an existing implementation. The paper does not describe Mova, and its findings do not establish that Mova already has SQL generation, query canonicalization, or a particular benchmark pipeline. What it offers is a way to make any future structured-query experiments more informative.

A useful starting point would be to keep separate records for the user’s wording, the intended structured request, and the values supplied by that wording. Suppose a future Mova interface could interpret course-related questions. A request about an instructor and a request about a meeting day might each be familiar, while their combination could still be new. Evaluation could distinguish alternative expressions of those familiar requests from questions requiring their constraints to be combined. This would make the intended generalization visible in the test construction.

The template baseline also suits a transparent system as a diagnostic reference. A future implementation could expose the selected request structure and the spans used to fill its arguments. That would make failures inspectable: the system might choose the wrong structure, attach a value to the wrong role, or fail to combine constraints. This is a possible use of the paper’s decomposition, not evidence that such a component is already built. Its value would lie in making a limited capability easy to recognize and compare against something more flexible.

Entity handling deserves its own boundary. Replacing an instructor’s name or a course identifier with a correct type would let Mova’s SQL-related reasoning be tested under controlled conditions. Keeping the original question would test whether it can recover those values and roles itself. The paper suggests reporting both conditions, with the source of the annotations made explicit. A transparent design would benefit from recording how each value was identified, instead of presenting the supplied annotation as an invisible preprocessing success.

Finally, Mova could use this work when deciding what counts as progress. A higher score on paraphrases of familiar requests would support a claim about robustness to wording. Success on withheld request structures would support a different claim about composition within the tested domain. Neither would automatically establish reliability on another database or on unrestricted user requests. The practical borrowing is a disciplined match between the test, the visible processing steps, and the capability being claimed.

The problem and its context

Text-to-SQL connects an ordinary-language request to an executable database query. A person describes the information they want; the system must express that request using the database’s tables, fields, relationships, and operations. This is a form of semantic parsing: language is mapped into a structured representation of meaning. Here, that representation is SQL, which can be executed against a relational database.

The appeal is straightforward. Many people need information stored in databases without knowing how those databases are organized or how to write queries. A natural-language interface could make that information accessible. But the task includes several different challenges. The system must interpret the request, identify relevant values, connect phrases to schema elements, and assemble the required operations. A benchmark that simplifies or repeatedly reuses some of those decisions may measure a useful skill while leaving others mostly untested.

The paper places its contribution within work on natural-language database interfaces dating to the 1970s. In the database community, earlier approaches frequently relied on matching patterns, applying grammars, or constructing intermediate query representations. Some incorporated user feedback. According to the authors, the relevant systems were generally unavailable for direct reuse, and many depended on resources built for particular domains. This limited both reproducible comparisons and straightforward application across datasets.

The NLP literature had also developed methods for translating language into logical representations used to query knowledge bases. The authors cite work including Semantic Parsing via Paraphrasing. SQL generation was receiving increasing attention alongside that broader research. The paper’s concern is not to replace the accumulated parsing techniques with an entirely new formalism. It asks whether the evaluation practices surrounding them make their strengths and weaknesses sufficiently visible.

Earlier approaches and the data bottleneck

One earlier statistical interface discussed in the paper is PRECISE. It sought high precision for questions satisfying constraints that connected words with database values, attributes, and relations. It did not attempt unrestricted coverage, and adapting it involved substantial domain engineering, including a specialized lexicon. Other approaches used syntactic relations or transferred techniques from logical parsing. These examples show that text-to-SQL had long involved a tradeoff between coverage, domain preparation, and the assumptions a system could make about its inputs.

More recent publicly available systems made broader comparisons possible. The authors examine sequence-based generation, an attention-equipped variant, a copying extension, and a tree-producing parser adapted from logical-form generation. Attention connects this work to Neural Machine Translation by Jointly Learning to Align and Translate: the relevant idea is that output generation can attend to different parts of an input sentence. The paper uses such architectures as experimental subjects instead of treating architectural novelty as its principal contribution.

Training these systems requires paired questions and queries. Producing those annotations is costly, especially when the SQL is complex. The paper describes several responses to that bottleneck. Automatically generated queries can be paired with template-like questions and then rewritten by people. Feedback-based learning can use a user’s judgment about a predicted answer. Other approaches avoid directly relying on the same paired-data setup, but those are outside the study’s scope.

The authors’ concern is that solutions to the data bottleneck can change what the resulting benchmark represents. If query generation starts from a restricted inventory of patterns, fluent human paraphrases do not expand the inventory of SQL operations. The questions may look natural while still requiring only a narrow range of executable structures. Conversely, collections elicited from people pursuing a task may contain relationships and constraints that are inconvenient to generate automatically but necessary for realistic use.

Why a disjoint test set can still be misleading

Standard machine learning practice separates training, development, and testing examples. That prevents the same labeled example from being used both to fit and to evaluate a system. Yet the definition of an example matters. If several questions express the same database request, splitting the question–query pairs independently can distribute versions of that request across all partitions.

Under such a split, an unfamiliar sentence may require selecting a known SQL structure and inserting new values. That remains a real language-understanding problem. Word order, paraphrase, and value recognition can all be difficult. The narrower point is that success does not necessarily require assembling a query structure that was absent from training.

The distinction becomes especially important for composition. Knowing how to ask which courses an instructor teaches and knowing how to ask which courses meet on a particular day does not establish that a system can combine those restrictions. A conventional split may test the combination only if the relevant structure happens not to appear in training. The authors seek a complementary test that guarantees this separation at the chosen level of query identity.

Their methodological argument therefore has several connected parts. The data must contain the structural features relevant to the intended application. The split must withhold the kind of novelty being claimed. The evaluation must also disclose whether entity identification has been supplied. Improving only one of these aspects would leave the others capable of producing an overly broad interpretation of a score.

The method, step by step

The study proceeds by making the datasets comparable, measuring their structure, and then changing the conditions under which existing systems are evaluated. The authors contribute standardized data and code, together with the Advising collection. Their procedure is best understood as an experimental pipeline: repair the references, define query identity, construct contrasting splits, and compare systems whose capabilities differ in interpretable ways.

Building a more informative text-to-SQL evaluation

The steps in order.

Building a more informative text-to-SQL evaluationStep 1: Collect datasets and construct Advising1. Collect datasets and construct AdvisingStep 2: Identify equivalent questions and queries2. Identify equivalent questions and queriesStep 3: Standardize SQL writing conventions3. Standardize SQL writing conventionsStep 4: Annotate values and their question spans4. Annotate values and their question spansStep 5: Measure query diversity and complexity5. Measure query diversity and complexityStep 6: Create question and query splits6. Create question and query splitsStep 7: Compare systems with and without anonymization7. Compare systems with and without anonymization

Establish what each dataset contains

The authors use collections with different domains and collection procedures. ATIS concerns flight-booking requests. GeoQuery concerns United States geography and originated with Prolog annotations before receiving SQL versions. Restaurants asks about establishments, cuisines, and locations. Scholar concerns academic publications, with automatically produced SQL checked through user judgments.

Academic has a related subject area but a different origin. Its questions were written to match logical queries expressible through the Microsoft Academic Search interface. That makes it human-written, while also tying the language and query inventory to a particular interface. The paper later returns to this regularity when explaining why Academic behaves differently from several other datasets.

Yelp and IMDB were collected from people who understood the kinds of information available without knowing the database schemas. WikiSQL followed a different route: queries over individual Wikipedia tables were generated automatically, and crowd workers made their corresponding questions read more naturally. These differences in collection procedure are central to the analysis. The authors do not treat all question–query pairs as interchangeable evidence merely because they share the same output language.

Advising adds a task-oriented domain involving course information at the University of Michigan. Its database includes fictional student records. Some questions came from a departmental Facebook page; others were written by computer science students who knew the database and were asked to imagine an advising appointment. This combines naturally occurring requests with deliberately elicited questions grounded in a practical task.

Construct and check Advising

The authors initially assigned SQL to the Advising questions by hand. They then assessed each pair along separate dimensions. Accuracy concerned whether executing the SQL answered the question correctly. Helpfulness concerned whether the resulting information served the likely purpose behind the question. At least two annotators evaluated each pair, using a two-point accuracy scale and a three-point helpfulness scale.

This distinction matters because a query can be narrowly compatible with a sentence without being useful to its asker. Evaluating helpfulness introduces a check on that gap. The paper does not present helpfulness as the main experimental metric for the parsers; it uses the judgments to improve the dataset. Low-scoring cases were revised or excluded.

The collection was expanded through paraphrasing using the method cited from Jiang and colleagues, followed by manual checking. Paraphrases initially retained the same named entities. The authors then annotated entity types in both questions and queries and replaced values with randomly selected alternatives of matching types.

That procedure changes wording and values together while preserving their alignment. A course identifier in the question must be changed consistently in the SQL. An instructor name must remain an instructor value rather than being replaced by an unrelated kind of item. The resulting expansion creates many linguistic realizations of a smaller inventory of underlying requests, a property that later becomes important for the splitting experiment.

Remove accidental disagreement in SQL

SQL admits multiple ways to express the same request. Some differences are merely stylistic; others involve distinct constructions that produce an equivalent answer. If those differences are ignored, a dataset can appear more structurally diverse than the intended questions warrant, and exact-output evaluation can become harder to interpret.

The authors manually grouped questions with equivalent meanings where their SQL differed. Another person checked every identified group and executed the queries. When several queries were valid, the standardized data retained the alternatives, although the experiments used the first one. This preserves more information in the resource than the evaluation directly exploits.

They also imposed consistent writing conventions. Selected fields, source tables, and filtering constraints were placed in alphabetical order. Table aliases were made systematic: an alias records the table name and which occurrence of that table it denotes within the query. Capitalization and spacing were standardized as well.

These operations aim to reduce irrelevant surface variation rather than change the database request. The authors checked the canonicalization code with unit tests and inspected its output manually. They separately repaired meaning-related problems, including ambiguous combinations of conjunction and disjunction. The distinction is important: formatting normalization and correction of an incorrect constraint are different interventions, even when both make a dataset more consistent.

Annotate the values connecting language and SQL

The variable annotation process identifies which parts of the question contribute values to the query. It begins with SQL comparisons. One side frequently contains a literal, such as a number or quoted string, while the other indicates what kind of database value it is. A direct textual match can then connect the literal to a span in the question.

Direct copying does not cover every case. The authors constructed dictionaries for correspondences such as airline names and their abbreviated database forms, as well as written times and their encoded values. Ambiguous mappings were flagged for manual attention. A place name, for example, may plausibly belong to different entity categories, so simple string matching cannot always determine the intended role.

This work also exposed annotation errors. Some SQL omitted a restriction stated in the question; other SQL included a restriction the question never supplied. The authors found incorrect comparisons and inconsistent interpretations of relative time expressions. Variable annotation therefore served both as preparation for anonymized experiments and as a structured audit of the reference queries.

The final annotations make it possible to replace an entity with a typed variable in both the input and the output. They also make template construction more reliable because the system can distinguish fixed SQL structure from the values that must be filled for a particular question.

Describe diversity without reducing it to size

The paper measures several properties rather than proposing a single complexity score. Question count records the number of linguistic examples. Unique query count records distinct SQL after variable anonymization. Their quotient measures how many question examples correspond, on average, to a distinct anonymized query:

Question count / Unique query count

“Question count” is the number of questions in the collection. “Unique query count” is the number of distinct queries after entity values have been replaced by variables. The division therefore describes repetition at that level of query identity. A larger value indicates more questions per underlying query, but says nothing by itself about whether those questions are easy to interpret.

SQL patterns abstract further. They replace specific schema names, such as table and field names, while retaining the broader arrangement of the query. Distinct queries can therefore instantiate the same pattern. Counting patterns provides another view of diversity, and the average number of queries per pattern reveals repeated structural molds that unique-query counts alone can hide.

The remaining measurements concern structure inside a query. Total table references count every use of a table, including repeated uses. Unique table counts ignore repetition, so the two measurements differ when a table is joined to itself. The authors also count SELECT statements and measure nesting depth. These capture related but distinct properties: a query can contain several subqueries without placing them all along the same nested chain.

Build the complementary splits

For the question-based condition, the unit assigned to a partition is a question paired with its query. Distinct questions can therefore carry the same SQL structure into different partitions. For the query-based condition, the authors first substitute typed variables for entity values. Queries identical after that substitution form a group, and all associated questions remain together when the group is assigned to training, development, or testing.

This definition makes the experiment more precise than a vague requirement for “new questions.” It withholds a particular target structure, as represented by the standardized anonymized SQL. It does not withhold an entire domain or database schema. The target is generalization to unfamiliar queries within the familiar setting represented by that dataset.

The authors provide both labeling schemes for Advising and for several established collections, including ATIS, GeoQuery, and Scholar. For the smaller resources, they provide question-based and query-based buckets suitable for cross-validation. This accommodates limited dataset sizes without abandoning the central distinction between grouping by linguistic example and grouping by query structure.

Compare systems with different capabilities

The experimental systems include a basic sequence-to-sequence generator, a version with attention, and an attention-based copying extension. The copying system can emit a special COPY symbol. When that symbol receives the strongest output score, the system substitutes the input token receiving the greatest normalized attention score.

Training that extension uses a loss with separate contributions for output-symbol prediction and copying. The output-symbol contribution is categorical cross-entropy over the decoder vocabulary. When the correct symbol is COPY, another categorical cross-entropy term trains the attention distribution to select the appropriate input token. When copying is not required, that additional contribution is zero. The paper describes this objective verbally instead of presenting a separate mathematical derivation.

The comparison also includes Dong and Lapata’s sequence-to-tree parser, applied to SQL, and the system from Iyer and colleagues. For the latter, the authors enable paraphrase-based augmentation but omit template-based augmentation because suitable templates are unavailable for most collections. They do not compare unavailable earlier interfaces requiring substantial specialized resources for each domain.

The new baseline deliberately narrows the output space. A bidirectional LSTM assigns a tag to each input word, indicating either that the word is unused or that it supplies a typed slot. Representations from the sentence ends feed a small network that selects a SQL template. The tags and template are predicted through a shared architecture, although agreement between them is not explicitly enforced.

Templates are extracted from training queries using the variable annotations. Every value explicitly supplied by the question becomes a fillable slot. This baseline can change values within a known structure, but its template inventory prevents it from producing a structure missing from training. An oracle variant assumes perfect selection among available templates and perfect slot filling, exposing the coverage limit of that inventory.

Finally, the authors evaluate ordinary inputs and an oracle-entity condition. In the latter, correct typed variables replace entity names. This isolates some SQL-generation decisions while supplying the entity analysis. Keeping these conditions separate allows the experiments to distinguish a system’s structural limitations from the effects of privileged information about values.

Experiments and results

The experiments ask related but separable questions. How different are the available collections? Can a system restricted to known templates succeed on conventional tests? What happens when query structures are withheld? How much does correct entity information change the outcome? The evidence comes from descriptive dataset statistics, exact SQL accuracy, and closer inspection of generated outputs.

The main accuracy table distinguishes question and query splits and separates ordinary inputs from the oracle-entity condition. These conditions are essential to interpreting every score. An accuracy figure without its dataset, split, and entity treatment would conceal much of the paper’s argument.

Collection size does not determine structural coverage

Advising contains 4570 questions but 211 unique anonymized queries. The reported question-to-query ratio is 21.7. This reflects the collection process: paraphrases and entity replacements expand linguistic coverage around a smaller set of requests. That is valuable for testing language variation, but it does not create the same kind of diversity as adding new query structures.

WikiSQL contains 80,654 questions and 77,840 unique queries, with a reported ratio of 1.0. On that measurement it looks much less repetitive. Yet its queries come from 488 abstract patterns, and the largest pattern contains 42,816 queries. Those facts illustrate why query counts and pattern counts cannot substitute for each other. Many distinct queries can still instantiate the same arrangement of operations.

ATIS contains 5280 questions, 947 unique queries, and 751 patterns. Its pattern inventory is larger than WikiSQL’s despite its much smaller question collection. The paper uses this contrast to challenge the idea that the largest dataset necessarily provides the broadest training or evaluation coverage.

The structural measurements sharpen the distinction. WikiSQL has a mean table count of 1 and a maximum of 1. Its SELECT-count and nesting-depth measurements are likewise 1. It therefore does not test the joins and nesting that appear in the human-originated collections examined by the authors.

Advising’s mean number of table references is 3.2, with a maximum of 9. ATIS has a mean of 6.4 and a maximum of 32. These counts include repeated references to a table, so they should not be confused with distinct schema tables. They nonetheless show that the task-oriented collections require substantially richer relational constructions than an isolated-table setting.

The authors find that every human-generated collection except Yelp includes some nesting. The average query in each human-generated collection also uses more than a single table. Their recommendation follows from coverage rather than from a claim that every application needs the same SQL: an evaluation intended to represent human task-oriented requests should include the structures those requests actually require.

Data repair affects the experimental foundation

The manual equivalence checks identified 380 affected ATIS queries grouped into 141 sets. GeoQuery had 39 affected queries in 17 sets, while Scholar had 152 affected queries in 60 sets. These are counts of cases where equivalent questions had received different SQL, not accuracy improvements from a parser.

The distinction matters because these repairs alter how query identity is measured. Without resolving accidental variation, a structural split could separate alternative annotations of the same request and mistakenly treat them as distinct targets. Conversely, a strict output comparison could penalize a valid formulation because the reference used another one.

The authors also report correcting ambiguous conjunction and disjunction in 30 ATIS queries. Alongside the broader variable audit, this shows that the methodological contribution depends on labor-intensive inspection as well as an automatic splitting rule. The quality of the experimental target cannot simply be assumed.

A restricted baseline succeeds on familiar structures

Advising provides a particularly clear demonstration. The following chart uses accuracy with entity names retained. It compares the template baseline with the attention-and-copying generator under both splits.

Advising accuracy without variable anonymization

Strong question-split results coexist with failure when query structures are withheld.

Advising accuracy without variable anonymizationTemplate baseline, question split (this paper): 80Template baseline, question split (thispaper)80Template baseline, query split: 0Template baseline, query split0Attention and copying, question split: 70Attention and copying, question split70Attention and copying, query split: 0Attention and copying, query split0
The numbers
System or settingaccuracy %
Template baseline, question split (this paper)80
Template baseline, query split0
Attention and copying, question split70
Attention and copying, query split0

The baseline’s strong question-split score is not evidence of structural invention. Its design rules that out. Instead, the score demonstrates that selecting a familiar structure and locating its arguments can cover much of this test condition. Advising’s paraphrase expansion helps explain why the same underlying request can be available in several linguistic forms.

The query-split baseline score follows directly from its output restriction. Every required anonymized query is absent from the training template inventory. That predictable failure is what makes the baseline diagnostic: its success elsewhere tells the reader that structural novelty was not necessary for those successful predictions.

The attention-and-copying system has a more flexible output mechanism, yet it also fails on Advising’s query split in this condition. Architectural freedom to generate tokens is therefore not enough to establish successful composition. The test demands that the generated sequence express the right combination of database operations.

Restaurants offers another example of the strength of familiar-structure evaluation. Without anonymization, the template baseline reaches 95 on the question split. Several more flexible systems reach 100 there. On the query split, their performance is far weaker. These outcomes should be read alongside the collection’s small inventory of 23 unique queries, rather than as proof that unrestricted restaurant querying has been solved.

Flexible generation retains some ability to handle new queries

The results are not uniformly zero outside the template baseline. ATIS shows that the more flexible systems sometimes produce an unseen query correctly. The next comparison again retains entity names and uses SQL accuracy.

ATIS accuracy without variable anonymization

Copying improves both settings, while withholding query structures remains harder.

ATIS accuracy without variable anonymizationAttention, question split: 46Attention, question split46Attention, query split: 18Attention, query split18Attention and copying, question split (this paper): 51Attention and copying, question split(this paper)51Attention and copying, query split: 32Attention and copying, query split32
The numbers
System or settingaccuracy %
Attention, question split46
Attention, query split18
Attention and copying, question split (this paper)51
Attention and copying, query split32

This is a more nuanced result than a blanket claim that the systems only memorize. The copying architecture has measurable success on the query split, so its behavior exceeds the inventory restriction of the template baseline. At the same time, the conventional score still gives a substantially more favorable impression of its ability.

GeoQuery likewise shows both partial generalization and a change in relative system performance. The copying system leads the displayed question-split comparison, while Iyer and colleagues’ system has the strongest query-split score among these entries.

GeoQuery accuracy without variable anonymization

The strongest displayed question-split setting does not lead on the query split.

GeoQuery accuracy without variable anonymizationAttention and copying, question split (this paper): 71Attention and copying, question split(this paper)71Attention and copying, query split: 20Attention and copying, query split20Dong and Lapata, question split: 62Dong and Lapata, question split62Dong and Lapata, query split: 31Dong and Lapata, query split31Iyer and colleagues, question split: 66Iyer and colleagues, question split66Iyer and colleagues, query split: 40Iyer and colleagues, query split40
The numbers
System or settingaccuracy %
Attention and copying, question split (this paper)71
Attention and copying, query split20
Dong and Lapata, question split62
Dong and Lapata, query split31
Iyer and colleagues, question split66
Iyer and colleagues, query split40

The change in ordering matters for method comparison. If a benchmark asks different questions under its alternative splits, the system preferred under one condition need not be preferred under the other. Reporting both therefore reveals more than reporting a lower score on a supposedly harder version of the same test.

For Scholar, the copying system scores 59 on the question split and 5 on the query split without anonymization. The template baseline scores 52 and 0, respectively. Here too, conventional evaluation gives the restricted system a competitive result, while the structural split exposes a difficulty shared by more flexible approaches.

Less redundant collections behave differently

The collections originating in the database community show a smaller separation between the two splitting procedures. Their question-to-query ratios are close to the condition where each question has its own query. As a consequence, independently partitioning questions already comes closer to withholding query structures.

Academic is the most striking example. With entity names present, the copying system scores 81 on the question split and 74 on the query split. The authors suggest that its regular wording and compositional request structures may help. Its questions share a fixed opening and then specify a requested field with optional restrictions.

This is an explanation offered from inspection, not a controlled proof of the cause. The authors explicitly investigate whether low redundancy alone could explain good structural-split performance and find that it cannot. IMDB and Yelp also have relatively little repetition, yet their query-split results remain weak.

For example, the copying system obtains 26 and 9 on IMDB’s question and query splits without anonymization. On Yelp, the corresponding scores are 12 and 4. These figures show why reducing repetition and improving compositional success must be kept conceptually separate.

Correct entity information changes the task

Anonymization can provide a strong signal. On GeoQuery, the attention system scores 73 on the question split with oracle entities, compared with 63 when names remain in place. Its query-split figures are 31 with oracle entities and 21 without anonymization. These are results for the attention system under different input conditions, not a direct measurement of an isolated entity recognizer.

Advising makes the effect especially visible for attention without copying: its question-split accuracy is 29 without anonymization and 88 with oracle entities. The ordinary-input copying system reaches 70. This comparison shows how both privileged annotations and an architecture designed to recover input values can change apparent difficulty.

The broader result is that correct entity information improves many outcomes but does not erase the structural-split problem. The authors therefore recommend including evaluation on original, non-anonymized questions. A system’s ability to select SQL operations and its ability to interpret database values interact, and neither should disappear silently from the reported task.

What the ablations show

The paper offers controlled changes to evaluation conditions and targeted output analyses rather than a component-removal study of a single proposed architecture. Its most informative comparisons change the split, provide entity information, remove repeated paraphrases, inspect error types, and replace SQL with logical forms. Together, these analyses help distinguish several explanations for the main results.

The template oracle measures available coverage

The oracle baseline assumes perfect choices within the training template inventory. It therefore asks a counterfactual question: how much of the test set could be solved if recognizing the right familiar template and filling its slots were flawless?

Under oracle entities, the question-split oracle score is 100 for Advising and 100 for Restaurants. It is 69 for ATIS, 78 for GeoQuery, and 84 for Scholar. These values describe the coverage of familiar structures under the particular evaluation setup. They are not achieved results from a fully functioning parser.

The distinction between the learned baseline and its oracle also prevents an overly simple reading of the paper. Question-based evaluation can remain difficult even when many structures are familiar. A system may fail to recognize a paraphrase, select the right template, or supply the correct arguments. The methodological objection is that solving these problems does not by itself establish the ability to construct an unfamiliar query.

For the lower-redundancy collections, the oracle is much less successful. That supports the interpretation that their conventional splits already contain more structural novelty. It also shows why dataset size alone cannot explain the template baseline’s success or failure: the small Restaurants collection supports a strong baseline, while other small collections do not.

Removing repeated questions does not solve structural generalization

One possible explanation for poor query-split results is that repeated paraphrases distort training. Perhaps a collection with less repetition would encourage more general rules. The authors test this by creating non-redundant query-split versions that retain a single question per query for Advising and several established datasets.

Accuracy stays unchanged or declines compared with the ordinary query-split condition. The paper reports no improvement from this manipulation. Redundancy can make the question and query splits differ more sharply, but eliminating repeated questions does not automatically produce the capability needed for unseen structures.

This is a useful distinction between measurement and learning. Grouping repeated structures correctly improves what the evaluation asks. Deleting examples is a different intervention, with consequences for the training evidence available. The finding does not establish that paraphrases are always beneficial, but it rules out a simple account in which repetition alone explains the observed structural failures.

Error categories separate values from structures

The authors inspect outputs from the attention-and-copying system. They distinguish correct predictions, outputs whose only problem is an entity value, outputs matching an incorrect existing template, and outputs with no matching dataset template. This categorization is more informative than treating all incorrect SQL as the same kind of failure.

An incorrect familiar template suggests that the system selected the wrong request structure. A query with no template match is more ambiguous. It may be malformed SQL caused by a small generation error. It may also be an attempted recombination of familiar pieces, which is necessary for structural generalization even when the attempt fails.

Advising’s query-split analysis contains 675 outputs in the incorrect-template category and 25 in the no-template-match category. The corresponding correct count is 5 in that analyzed set. These counts support the paper’s concern that familiar-structure reuse can persist even when it is inappropriate for the test question.

ATIS behaves differently. Its query-split analysis includes 111 correct outputs and 162 outputs with no template match. This does not mean that the unmatched outputs are successful compositions; the category explicitly includes ordinary errors. It shows that the system is producing unfamiliar structures frequently enough to make a closer analysis worthwhile.

Query length offers a suggestive, incomplete explanation

The authors compare the lengths of reference queries across error categories. In question-based testing, correct cases are generally shorter than cases assigned an incorrect template or no matching template. That is consistent with longer SQL being harder to predict, but the analysis does not isolate length from every other source of difficulty.

They also observe that incorrect familiar-template predictions tend to correspond to shorter references than predictions with no template match. This suggests a behavioral pattern: for shorter requests, the system more often reuses a familiar query, while longer requests more frequently trigger novel sequences.

On ATIS, the mean reference length for correct predictions is 55.1 in the question split and 69.2 in the query split. GeoQuery’s corresponding means are 19.6 and 21.5. The authors suggest that longer queries may provide more opportunities to recombine pieces, which could help in the structural-split condition.

They present that explanation cautiously. Scholar does not follow the same pattern, and its query-split analysis contains only 17 correct predictions. The length observations are therefore useful clues about behavior, not a general law that longer SQL is easier to compose.

Entity-only errors understate the value of entity information

The copying system produces relatively few errors attributable only to entity names. That supports the claim that copying handles many direct value transfers effectively. It does not establish that entity interpretation is unimportant.

Correct typed annotations also provide information about the intended role of a phrase. Identifying a name as referring to an airport instead of a city can influence structural choices, beyond just the final literal placed in SQL. The gains from oracle entities therefore remain meaningful even when the narrow entity-only error category is small.

This analysis cautions against interpreting error categories as independent modules. A mistaken understanding of a value can lead to the wrong template, and would then appear as a structural error instead of an entity-only error. The paper’s paired input conditions offer evidence that manual output categorization alone cannot capture.

Logical forms weaken the split effect

The authors repeat the split comparison using logical-form annotations for ATIS and GeoQuery and retrain the baseline and full system from Jia and Liang. Here, changing the split has only a limited effect, whether performance is assessed through logical-form predictions or the answers those forms produce.

Inspection suggests that the target representations explain part of the difference. After identifying variables, the logical-form collections contain a larger inventory of distinct targets. They preserve distinctions related to how a question is phrased that the SQL representation collapses.

For example, alternative descriptions of a state whose capital has the greatest population can receive different logical forms while sharing the same SQL. In ATIS, explicitly mentioning flights can introduce a logical-form condition that is absent from a differently phrased request with the same practical intent.

The implication is specific. The SQL findings do not transfer unchanged to every semantic representation. A representation that tracks linguistic structure more closely can make conventional training already demand more composition. Evaluating generalization therefore requires examining both the partitioning rule and the abstraction encoded in the targets.

Limitations

The paper is strongest as a diagnosis of particular evaluation practices. It does not provide a universal test of database-language understanding, and it does not claim that one splitting rule resolves every ambiguity in measuring generalization. Several limits are stated directly by the authors; others follow from the scope of their experiments.

Limits the authors identify

Exact SQL matching can reject a semantically valid answer. The authors identify at least one prediction that expresses an equivalent request through a different construction but is marked wrong. A query that orders candidates and selects the leading result can, in the discussed case, correspond to another that compares against a maximum found by a subquery.

Canonical formatting reduces stylistic variation, but it cannot make every equivalent SQL program identical. Retaining alternative valid references helps preserve the data, yet the experiments use the first reference. As a result, exact accuracy is an imperfect measure of semantic correctness, particularly when a system produces a new formulation.

The available system comparison is also restricted. The authors could not obtain public implementations of the earlier non-neural interfaces discussed in their review. Several such approaches would additionally require specialized resources for every domain. The experiments therefore support conclusions about the evaluated systems and benchmark conditions, not an exhaustive ranking of all database interfaces.

The paper also limits its treatment of other learning approaches. It mentions methods that avoid the same paired-data bottleneck but does not evaluate them. The methodology may motivate questions about those systems, yet their behavior cannot be inferred directly from these experiments.

Finally, some explanations remain tentative. The account of Academic’s relative success is based on the regularity observed in its questions and queries. The proposed relationship between length and recombination receives mixed support across datasets. The authors explicitly urge caution where the number of correct examples is small.

Limits visible in the experimental setup

The query split withholds structures within a dataset’s domain. It does not independently test transfer to an unfamiliar schema or subject area. A system can face a new combination of familiar tables and operations without facing a new database. These are different forms of generalization, and the reported results should not be expanded into claims about all of them.

The definition of novelty also depends on representation. Queries are grouped after typed-value replacement and standardization, with manual equivalence work addressing some additional variation. This is a practical construction, not a complete procedure for proving SQL equivalence. The logical-form comparison makes that dependence especially clear.

Complexity measurements are informative but partial. Table references, nesting, and pattern inventories describe the SQL target. They do not fully measure linguistic ambiguity, implicit intent, or the reasoning required to choose the right database operation. A short query can be hard to infer, while a long query can follow a familiar pattern.

Collection procedures introduce further boundaries. Advising is grounded in a practical domain, but its expansion deliberately reuses request structures through paraphrases and typed replacements. Academic is human-written, yet its questions are tied to the expressiveness of a search interface. “Human-generated” therefore does not denote a uniform distribution of unrestricted user behavior.

The Advising quality process checks accuracy and helpfulness, but it does not establish that the collection exhausts advising needs. Fictional student records permit the intended database setting without demonstrating performance over every real institutional circumstance. Its value is as a challenging, carefully checked resource, not as proof of complete application coverage.

The oracle-entity condition is likewise an analytic simplification. It supplies correct mappings and types rather than measuring a deployable entity-processing pipeline. Results under that condition help locate difficulty, but should not be presented as end-to-end performance without making the assistance explicit.

There is also no demonstrated causal guarantee that a particular architectural change will close the structural-split gap. Copying helps in several comparisons, and sequence generation sometimes succeeds on unseen structures. Neither observation establishes a general solution to composition. The paper primarily improves the ability to observe the problem.

What the conclusions can support

The evidence supports evaluating several dimensions separately: linguistic variation over familiar requests, unfamiliar query structures in a known domain, and value interpretation from ordinary questions. It also supports including datasets with joins and nesting when the intended application requires them.

It does not support abandoning question-based tests. If an application genuinely has a covered inventory of requests, robustness to alternative wording is a legitimate goal. The error lies in interpreting success on that goal as sufficient evidence for another. The authors’ recommendation is complementary reporting, with conclusions matched to what each condition actually tests.

What came after

The later works connected to this paper span dataset design, schema representation, conversational querying, and compositional generalization. Their titles establish those subjects, but citation alone does not show which recommendation each adopted or how strongly it shaped a method. The appropriate distinction is between the concerns they address and a detailed influence claim that would require their own experimental accounts.

The lasting question supplied by Improving Text-to-SQL Evaluation Methodology is useful across this range: what kind of unfamiliarity must a system handle to succeed? New wording, a new combination of operations, an unfamiliar schema, and a conversational dependency are different challenges. The later works make those distinctions relevant in different settings.

Broader datasets and cross-domain evaluation

Spider, from 2018, is explicitly a human-labeled resource for complex, cross-domain semantic parsing and text-to-SQL. Its stated scope connects to two concerns in the evaluation paper: structural richness and the need to specify the setting in which generalization is measured. Cross-domain evaluation adds a dimension beyond the within-domain query split studied here.

That relationship should not be overstated. The title establishes Spider’s intended coverage, not its precise overlap with these data-cleaning rules or its results under these splits. The useful connection is conceptual: collecting many examples and defining the novelty of the test are separate benchmark-design decisions.

DuSQL, from 2020, identifies a large-scale Chinese text-to-SQL dataset with a pragmatic focus. It places dataset construction in another language and application framing. The earlier paper’s questions still apply: which request structures are represented, how the language was elicited, and whether testing introduces unfamiliar targets or alternative expressions of familiar ones.

The title alone does not establish DuSQL’s collection details or numerical findings. It does show why the methodological issue is broader than a particular English dataset. A benchmark’s language, scale, and practical orientation do not remove the need to describe its structural coverage.

Schema structure and its connection to language

Representing Schema Structure with Graph Neural Networks for Text-to-SQL Parsing, from 2019, directly names schema representation as its subject. The evaluation paper helps explain why such representation matters to assessment: questions requiring several related tables exercise capabilities absent from isolated-table queries.

RAT-SQL, from 2020, names relation-aware schema encoding and linking as its focus. This addresses the interface between linguistic requests and database organization. Its connection to the earlier analysis lies in the need to distinguish recognizing relevant schema elements from composing the right query around them.

Structure-Grounded Pretraining for Text-to-SQL, from 2021, brings structural information into its stated pretraining objective. The methodological question remains whether an improvement is demonstrated on familiar target patterns, withheld query structures, or another generalization setting. Its title does not establish the answer, so no particular score or adopted split can be inferred.

These works occupy a technical direction that the evaluation study makes easier to judge. Better representations may help with tables, relationships, and grounding, but their practical meaning depends on the data’s structural demands and the evaluation’s novelty boundary.

Conversations and context-dependent requests

SParC, from 2019, explicitly concerns cross-domain semantic parsing in context. Context changes the unit of interpretation: a request may depend on material outside the current sentence. That makes the earlier insistence on defining the experimental unit especially relevant, even though the evaluation paper’s main experiments concern individual questions.

CoSQL, also from 2019, frames text-to-SQL as a conversational challenge aimed at cross-domain database interfaces. Its scope connects database querying with dialogue systems. A conversational benchmark must account for dependencies among requests as well as the structures of their SQL targets.

Editing-Based SQL Query Generation for Cross-Domain Context-Dependent Questions, from 2019, identifies editing as its generation approach and contextual dependence as part of its task. This makes reuse particularly interesting. Reusing an earlier query can be appropriate behavior in a conversation, whereas reusing a training template does not establish success on an unfamiliar structure. The evaluation must clarify which form of reuse the task requires.

PRACTIQ, from 2025, names ambiguous and unanswerable requests within a practical conversational dataset. That stated scope highlights another boundary of conventional query accuracy: an interface may need to determine that a request cannot yet be translated into a justified query. The title supports that task characterization, without establishing particular annotation procedures or outcomes.

Compositional generalization and training examples

Good-Enough Compositional Data Augmentation, from 2020, and Improving Compositional Generalization with Latent Structure and Data Augmentation, from 2022, both explicitly connect composition with augmentation. The earlier evaluation study supplies a reason to ask what augmentation changes: more expressions of known requests and more combinations of operations are not equivalent additions.

Span-based Semantic Parsing for Compositional Generalization, from 2021, places compositional generalization directly in its stated parsing objective. The SQL and logical-form comparison remains relevant here because target representation can affect which examples count as structurally distinct. A claim about composition needs both a method and a clear account of the test construction.

Diverse Demonstrations Improve In-context Compositional Generalization, from 2023, and Compositional Exemplars for In-context Learning, also from 2023, shift attention towards the examples available within a learning context. Their titles identify demonstrations and exemplars as central. The earlier paper’s distinction remains useful: exposure to a target structure and exposure only to components of that structure support different interpretations of success.

Evaluating the Text-to-SQL Capabilities of Large Language Models, from 2022, returns explicitly to capability assessment in text-to-SQL. The methodological connection is direct at the level of the research question. Whatever system is being tested, its score depends on query complexity, structural overlap, entity treatment, and the standard used to recognize a correct output.

Connections beyond database querying

The citation list also includes Learning Math Reasoning from Self-Sampled Correct and Partially-Correct Solutions, from 2022, and Draw Me a Flower, whose 2022 title concerns processing and grounding abstraction in language. Their inclusion shows that the paper is cited beyond the most direct SQL setting. The titles do not establish which experimental recommendation those works borrowed.

Improving Cross-lingual Transfer through Subtree-aware Word Reordering, from 2023, likewise concerns a different task family. Its structural emphasis makes the evaluation paper’s questions relevant, but a specific methodological dependency cannot be reconstructed from its title.

Across these connections, the reusable contribution is a way of reading evidence. Before interpreting a successful prediction as generalization, identify what was unfamiliar, what information was supplied, and what alternative strategy could also have succeeded. For text-to-SQL, the paper makes those questions concrete through repaired data, explicit query identity, a deliberately restricted baseline, and complementary evaluation conditions.

 Institutions

 Fields, topics and concepts

Cite

Cite as Catherine Finegan-Dollak, Jonathan K. Kummerfeld, Li Zhang, Karthik Ramanathan, Sesh Sadasivam, Rui Zhang and Dragomir Radev. 2018. Improving Text-to-SQL Evaluation Methodology. Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers).

The paper itself, not this page. BibTeX from the library's record of the work. DOI 10.18653/v1/p18-1033

@inproceedings{finegandollak2018improving,
  title = {{Improving Text-to-SQL Evaluation Methodology}},
  author = {Catherine Finegan-Dollak, Jonathan K. Kummerfeld, Li Zhang, Karthik Ramanathan, Sesh Sadasivam, Rui Zhang and Dragomir Radev},
  booktitle = {Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers)},
  year = {2018},
  doi = {10.18653/v1/p18-1033},
  url = {https://doi.org/10.18653/v1/p18-1033}
}

References

4 references, 2 of them with a card of ours. Each entry links to our card when we hold the work, else to OpenAlex and Google Scholar searches for it.

  1. population even though the associated dataset only has population figures for cities (not area or any other measure of size). Similarly in ATIS, the logical form will add (flight $0) if the question mentions flights explicitly, making these two queries different, even though they convey the same use… — Neural Machine Translation by Jointly Learning to Align and Translate
  2. By being closer to a syntactic representation, the queries end up being more compositional, which encourages the model to learn more compositionality than the SQL models do. OpenAlex ↗ · Scholar ↗
  3. Islam Beltagy, Katrin Erk, and Raymond Mooney. 2014. Semantic parsing using distributional semantics and probabilistic logic. Proceedings of the ACL 2014 Workshop on Semantic Parsing, pages 7–11. OpenAlex ↗ · Scholar ↗
  4. Jonathan Berant and Percy Liang. 2014. Semantic parsing via paraphrasing. In Proceedings of the 52nd Annual Meeting of the Association for Computational Linguistics, pages 1415–1425. \#\# Conclusion

↑ back to top

This page in Markdown https://md.research.elamur.ai/free/en/papers/dollak-2018-improving-text-sql-evaluation-methodology/