Datasets:

Modalities:
Text
Formats:
csv
Libraries:
Datasets
pandas
Text2SPARQL-Clean / README.md
GoloMarcos's picture
Update README.md
dac812f verified
|
Raw
History Blame Contribute Delete
3.56 kB

Dataset Card for Text2Sparql-Clean

๐Ÿงพ Dataset Summary

Text2Sparql-Clean is a clean, standardized, and multilingual dataset for the task of translating natural language questions into SPARQL queries over the DBpedia knowledge graph. It aggregates and harmonizes four widely-used benchmarks in the text-to-SPARQL research field:

  • QALD (versions 1โ€“9)
  • LC-QuAD 1.0
  • Orange/paraqa-sparqltotext
  • julioc-p/Question-Sparql

The dataset includes questions in English and Spanish, making it a valuable resource for both monolingual and cross-lingual question answering over knowledge graphs.

This is the second official version of the dataset.


๐Ÿ› ๏ธ Key Features and Improvements

This dataset goes beyond simple aggregation. It includes several important improvements over the original datasets:

  • โœ… Standardized SPARQL queries: All queries were revised to include the necessary PREFIX declarations, ensuring compatibility with DBpediaโ€™s SPARQL endpoint.
  • โœ… Syntactic and semantic validation: Every SPARQL query was checked for syntactic correctness and semantic executability. Faulty or malformed queries were either fixed or removed.
  • โœ… Clean, high-quality corpus: The result is a clean dataset where all queries are both executable and meaningful, enabling reliable model training and evaluation.

โœ… Supported Tasks

  • Text-to-SPARQL generation โ†’ Given a natural language question, generate the corresponding SPARQL query over DBpedia.

๐ŸŒ Languages

  • English (en)
  • Spanish (es)

๐Ÿ“ Dataset Format

Each data instance contains:

  • question: The question in natural language (English or Spanish)
  • query: The corresponding SPARQL query
  • dataset-id: Original dataset source (e.g., QALD-X, LCQUAD, Orange, JULIOC)

๐Ÿ”ง Dataset Creation Process

This dataset is the result of a comprehensive curation pipeline:

  1. Aggregation of four public datasets into a unified structure.
  2. Normalization of query formats and syntax, resulting in all queries with PREFIX.
  3. Insertion of missing PREFIX declarations to ensure compliance with DBpedia standards.
  4. Execution validation: All queries were tested against a DBpedia SPARQL endpoint. Queries that failed were either corrected (if trivial) or removed.
  5. Language consistency checks for both English and Spanish questions.

๐Ÿ’ก Use Cases

  • Training and evaluating text-to-SPARQL models
  • Developing multilingual semantic parsers
  • Enabling cross-lingual question answering over structured knowledge graphs
  • Fine-tuning large language models on knowledge-graph-to-text tasks

๐Ÿ“š Citation

If you use this dataset in your research, please cite:

@misc{text2sparql-clean,
  author = {Marcos Gรดlo, Paulo do Carmo, Edgard Marx, Ricardo Marcacini},
  title = {text2sparql-clean: Natural Language Text to SPARQL for DBpedia Cleaned Dataset},
  year = {2025},
  howpublished = {\url{https://huggingface.co/datasets/aksw/Text2Sparql-Clean}},
}

๐Ÿชช Licensing

license: apache-2.0

Check each datasetโ€™s original repository for full licensing terms.