Text2GraphQuery-Bench: A Text to Graph Query Benchmark

Songlin Lyu, Lujie Ban, Zihang Wu, Tianqi Luo, Jirong Liu +10 more
2/12/2026
cs.AI
benchmark-dataset

No confident code implementation found for this paper.

Abstract

Graph models are fundamental to data analysis in domains rich with complex relationships. Unlike SQL, which benefits from a rel- atively unified standard and widespread familiarity, graph query languages are diverse (e.g., Cypher, GQL, SQL/PGQ) and far less fa- miliar to most users, making them significantly harder to learn and use.

Show full abstract

Text-to-Graph-Query systems address this barrier by trans- lating natural language into executable graph queries, enabling LLMs to serve as interfaces for Graph Database Management Systems (GDBMS). Existing benchmarks are limited in language coverage, rely on rigid synthesis, and lack comprehensive evaluation. We present Text2GraphQuery-Bench, the first benchmark covering all mainstream declarative property graph query languages (Cypher, GQL, and SQL/PGQ). It contains 267,276 (Question, Graph Query) pairs across 34 databases and 13 domains. Its construction supports adaptation from heterogeneous resources and domain-aware synthesis, while its Graph-IR-based design enables rapid extension to new languages. The evaluation protocol reports Grammar, GLEU, Similarity, and EX under graph-native difficulty, question abstraction, and schema aliasing. Experiments on 8 LLMs reveal: (i) a significant language gap exists - zero-shot GQL and SQL/PGQ Grammar is far below Cypher, yet few-shot prompting largely recovers it; (ii) fine-tuning an 8B model reaches or exceeds zero-shot large models, indicating unfamiliarity - rather than model capacity - is the primary barrier; (iii) as supervision increases, syntax errors recede, shifting bottlenecks to aggregation logic in GQL and schema linking in SQL/PGQ; (iv) higher question abstraction degrades EX due to intent-to-schema grounding issues, while schema aliasing has minimal impact; (v) EX consistently degrades from Easy to Extra Hard, with Extra Hard remaining a persistent bottleneck. *(Due to arXiv constraints, this abstract is shortened. See PDF for the full version.)*

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{lyu2026textgraphquerybench,
  title  = {Text2GraphQuery-Bench: A Text to Graph Query Benchmark},
  author = {Songlin Lyu and Lujie Ban and Zihang Wu and Tianqi Luo and Jirong Liu and Ayoub Moussaid and Oskar van Rest and Heng Lin and Chenhao Ma and Nan Tang and Shipeng Qi and Yongchao Liu and Zhan Qiu and Juelu Zhang and Jiajun Zheng},
  year   = {2026},
  eprint = {2602.11745},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2602.11745v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2602.11745.svg)](https://codeofpaper.com/paper/2602.11745)

Discussion