Generate synthetic RDFS/OWL ontologies and RDF Knowledge Graphs at scale.
PyGraft-gen uses stochastic generation to produce ontologies and Knowledge Graphs with reliable structure while respecting OWL constraints, making it ideal for testing AI pipelines, benchmarking graph algorithms, and research scenarios where real data is sensitive or unavailable.
It also aims to advance the topic of generating realistic RDF Knowledge Graphs through parametric generation.
PyGraft-Gen is a major evolution of PyGraft, originally developed by Nicolas Hubert and awarded Best Resource Paper at ESWC 2024.
Typical workflows are:
- Generate a synthetic RDFS/OWL ontology from statistical parameters
- Generate an RDF Knowledge Graph from a synthetic ontology
- Generate an RDF Knowledge Graph from a user-provided ontology
Repository Structure:
.
├── evaluation/ # Subgraph matching research (experimental)
├── docs/ # Documentation source
└── src/ # PyGraft-gen library
The evaluation/ directory contains ongoing research on subgraph matching patterns and is separate from the main library.
Requirements: Python 3.10+, Java (optional, for reasoning)
pip:
pip install pygraft-genuv:
uv add pygraft-genpoetry:
poetry add pygraft-genVerify the installation:
pygraft --helpSee the installation documentation for setup details and the quickstart for complete examples.
See the official documentation for guides, API reference, and examples.
Contributions welcome! See CONTRIBUTING.md for guidelines.
Copyright (c) 2024-2025, Orange and Nicolas HUBERT. All rights reserved.
