fastdata
Benchmark report · 7 November 2026 · fastdata 0.3.2

60 questions. Three real databases.
54 answers with the right data.

fastdata-bench is an open text-to-SQL benchmark on three public PostgreSQL databases, from an 8-table airline to a 31-table hospital. It scores the data each answer returned, compared cell by cell with a gold result. It does not score the SQL text.

90%right data
54 of 60, extra columns allowed
58%exact match
35 of 60, exactly the asked columns
22.8 sper question
average, start to final answer
$0.058per question
$3.46 for all 60
The databases

Three domains, three schema sizes

The tiers are set by the number of tables the agent has to understand, not by row count. All three databases are public, pinned to a version and checksum-verified, so anyone can rebuild the exact setup.

S

Airlines

Aviation

Flights, bookings, tickets and boarding passes from the Postgres Pro demo database.

Tables
8
Rows
2.29 M
Right data
20 / 20
Exact
13 / 20
M

Pagila

Retail

A DVD rental business with films, actors, stores, customers, rentals and payments.

Tables
16
Rows
122 k
Right data
17 / 20
Exact
16 / 20
L

MIMIC-IV demo

Healthcare

Hospital admissions, ICU stays, lab events, diagnoses and prescriptions for 100 patients.

Tables
31
Rows
1.40 M
Right data
17 / 20
Exact
6 / 20
Results

Most misses were extra columns

Every database has 10 queries, each asked in two wordings, so each bar is 20 or so answers. Teal answers had the right rows and values, plus a column nobody asked for, such as a flight count next to an average delay.

Exact match Right data, extra columns Wrong data
By database
S · Airlines
137
20 / 20
M · Pagila
1613
17 / 20
L · MIMIC-IV
6113
17 / 20
By difficulty
Easy
164
20 / 20
Medium
985
17 / 22
Hard
1071
17 / 18

The number on the right of each bar is right data / all answers. Hard questions did better than medium ones: 17 of 18 had the right data.

Show the numbers as a table
GroupExact matchRight data, extra columnsWrong dataRight data / all
S · Airlines137020 / 20
M · Pagila161317 / 20
L · MIMIC-IV611317 / 20
Easy164020 / 20
Medium98517 / 22
Hard107117 / 18
All3519654 / 60
Sample questions

What the agent was asked

Nine of the 30 questions, three per difficulty level and one from each database (a few are shortened here). The agent saw only the question, connected as a read-only role, and wrote its own SQL.

EasyLookups and single aggregates

Airlines

Which cities are served by more than one airport? Return each city with its number of airports, sorted by the number of airports in descending order.

Exact in both wordings
Pagila

Which 10 countries have the most customers? Show the country and its number of customers, highest first; break ties alphabetically by country.

Exact in both wordings
MIMIC-IV

How many hospital admissions are there for each admission type? Show the admission type and the count, most frequent first.

Exact in both wordings

MediumJoins, anti-joins and rates

Pagila

Which films have no copies in any store's inventory? List their titles alphabetically.

Exact in both wordings
MIMIC-IV

What is the in-hospital mortality rate for each insurance type? Show the insurance, the number of admissions, the number of admissions where the patient died in hospital and the mortality percentage rounded to 2 decimals, highest rate first.

Exact in both wordings
Airlines

Considering only flights with status 'Arrived', which 5 departure airports have the highest average departure delay? Show the airport code, airport name and the average delay in minutes, rounded to 2 decimal places.

Right data, added a flight count

HardWindow functions, ties and cohorts

Airlines

For every day in July 2017, show the number of bookings made that day and the 7-day moving average of daily bookings (that day plus the six preceding days, which may fall in June), rounded to 2 decimals.

Exact in both wordings
Pagila

For each film category, which film was rented the most times? If several films tie for the top spot in a category, include all of them.

Exact in both wordings
MIMIC-IV

Out of all hospital admissions, how many were followed by the same patient's next admission starting within 30 days after discharge? Return the totals and the readmission rate as a percentage.

Right data, added data-quality counts
Two wordings, one answer

Each query is asked twice, worded differently, and both wordings must return the same result. The tie question above, asked the second way:

“Find the most frequently rented movie within every category, keeping all films that share the highest rental count in their category. Return category name, title and rental count, sorted by category and title.”

fastdata got 23 of the 30 queries to the same verdict in both wordings.

How it is scored

Scored by the data, not the SQL

A system may write any query it likes. What counts is whether the result it showed its user matches the gold result.

1

Cell by cell

Column names, column order and row order are ignored. Numbers are compared at the gold answer's precision, and dates and time zones are normalized.

2

Two scores

The output score checks what the system returned. The SQL score re-runs its final query read-only. Both came out the same in this run: 35 exact, 54 lenient.

3

Strict and lenient

Strict requires exactly the gold columns. Lenient also accepts extra columns, as long as every gold column is there with the right values.

Unambiguous questionsEvery "top N" was checked for ties at the cutoff. Questions name the output columns, rounding and edge cases.
Same conditionsPostgreSQL 18.6, UTC, a read-only role. Claude Opus 5.5 at medium effort, up to 30 turns per question.
Knowledge from learnEach knowledge base was drafted by fastdata learn from the schema alone. It never saw the gold queries.
What the misses tell us

25 answers missed the exact match. Here is why.

19

Right data, extra columns

The agent added context nobody asked for: an aircraft code next to the model name, the number of measurements behind an average heart rate, or a count of admissions with no discharge time. The lenient score accepts these.

5

Fetched extra rows to check ties

On "top N" questions the agent fetched N + 2 rows so it could check for a tie at the cutoff. Its written answer listed exactly the top N, but the query it returned had the extra rows, so the result does not match.

1

A different reading

Asked which drugs went to at least 80 patients, it followed the knowledge base and left out base solutions such as saline bags. It named the two entries it excluded in the answer.

The largest schema, the 31-table hospital database, scored lowest on exact matches but still had the right data in 17 of 20 answers. That is what we are working on next: keeping the returned result to the columns and rows the question asked for.

Join the discussion

Let's talk about it on Product Hunt

We published the benchmark so others can check our numbers and run their own systems on it. Come tell us what you think:

  • Which databases or domains should the next tier cover?
  • Which other text-to-SQL tools should we run on the same 60 questions?
  • Should extra columns count as right or wrong?
  • Where did fastdata get your own data wrong?
fastdata on Product Hunt Questions, critiques and benchmark ideas are all welcome. Join the discussion
Reproduce it

Four commands, about a minute of setup

One command downloads and loads all three databases into PostgreSQL in Docker. The harness has an adapter interface, so you can plug in another system and compare.

fastdata-bench
$ git clone https://github.com/reegosoftware/fastdata-bench.git && cd fastdata-bench
$ make setup       # PostgreSQL 18 in Docker + the 3 databases
$ make verify      # table and row counts match the snapshots
$ make check       # the gold queries reproduce the committed answers
$ make benchmark   # ask all 60 questions, write the report