From a theorem to a database
froGQL started as a research prototype and grew into a working engine. We are transparent about where AI helped and where it did not.
The differentiator is a typechecker grounded in a gradual type system for GQL: it detects queries that cannot return results because of type mismatches, before they run.
-
1
Theory first research
The project grew out of our paper on a gradual type system for GQL: its formalization and soundness theorems. The central result is Emptiness — statically detecting queries guaranteed to return nothing because of type mismatches.
-
2
A hand-written prototype by hand, no AI
We implemented the typechecker and the runtime semantics of the formal model in Python, by hand. This is the reference everything else is checked against.
-
3
The question worth testing research
Does the typechecker earn its cost? Is typecheck + run worthwhile against blindly running a query only to find it returns nothing? Answering this needed performance Python could not give.
-
4
Port to Rust AI-assisted
We rewrote the engine in Rust with AI assistance, taking inspiration from SQLite's single-file storage architecture.
-
5
Worst-case-optimal joins AI + paper
Joins were slow. Colleagues in databases pointed us to the CompactLTJ paper and its C++ reference. We implemented Leapfrog Triejoin with generative AI, keeping the test suite green throughout.
-
6
LDBC and language growth careful by hand
To run the LDBC Social Network Benchmark we extended the language with more features, including our centerpiece, the typechecker — carefully, to avoid breaking the theorems we had proved formally.
-
7
Where AI stopped being enough design + research
The benchmarks were strong on some fronts and weak on others. Closing the gaps took design decisions and research that AI could not deliver alone: LTJ interacts poorly with GQL features like
UNION, and even with plainORDER BY. We grow the system slowly, testing several strategies before each feature lands.
Flexible and Expressive Typed Path Patterns for GQL
The gradual type system, its formalization, and the Emptiness theorem behind froGQL's typechecker.
Read on ACM →CompactLTJ
Arroyuelo et al., VLDB Journal 2025. The worst-case-optimal join froGQL uses for comma-joins and chains.
Read the PDF →Benchmark charts from the LDBC Social Network Benchmark are coming here as the numbers stabilize.
fro