Instruct-to-SPARQL: A text-to-SPARQL dataset for training SPARQL Agents
The rapid adoption of Large Language Models (LLMs) for search engines and fact-checking platforms necessitates enhancing their output accuracy.Retrieval Augmented Generation (RAG) mitigates hallucinations but requires semantically rich repositories like Wikidata.However, there is a lack of high-quality data to fine-tune LLMs for querying such knowledge bases.To address this gap, we propose a curated dataset with 2,771 unique queries for fine-tuning LLMs to generate accurate and syntactically valid SPARQL queries from natural language instructions.This dataset, customized for interaction with Wikidata, also serves as a robust benchmark for text-to-SPARQL task evaluation.Key findings show that models generally perform better on queries with lower complexity.
Authors
- Michael Granitzer
- Mehdi Ben Amor (ORCID: https://orcid.org/0000-0002-1785-8367)
- Jelena Mitrović (ORCID: https://orcid.org/0000-0003-3220-8749)
- Elöd Egyed‐Zsigmond (ORCID: https://orcid.org/0000-0002-1218-8026)
- Alexis Strappazzon
Institutions
- University of Passau (DE)
- Laboratoire d'Informatique en Images et Systèmes d'Information (FR)
- Institut National des Sciences Appliquées de Lyon (FR)
Publication Details
- Published
- 2025-03-24
- DOI
- https://doi.org/10.1145/3698204.3716476
- Citations
- 2
- Primary Topic
- Natural Language Processing Techniques
- Type
- article
- Field-Weighted Citation Impact
- 4.96
Funders
- Bundesministerium für Bildung und Forschung
- Bundesministerium für Ernährung und Landwirtschaft