Installation#
Install PyGraft-gen using pip, uv or poetry.
Prerequisites
- Python 3.10 or higher
- Java (optional)
Installation#
This installs PyGraft-gen as a regular package in your current environment.
# From PyPI (recommended)
pip install pygraft-gen
# From GitHub (latest from main branch)
pip install git+https://github.com/Orange-OpenSource/pygraft-gen.git
# Verify installation
pygraft --version
# From PyPI (recommended)
uv add pygraft-gen
# From GitHub (latest from main branch)
uv pip install git+https://github.com/Orange-OpenSource/pygraft-gen.git
# Verify installation
pygraft --version
# From PyPI (recommended)
poetry add pygraft-gen
# From GitHub (latest from main branch)
poetry add git+https://github.com/Orange-OpenSource/pygraft-gen.git
# Verify installation
pygraft --version
Java (Optional)#
Java is required only for consistency checking, which uses the Owlready2 library to run the HermiT and Pellet reasoners. Enable this in your config with check_kg_consistency: true
Learn more
Install Java:
- Eclipse Temurin - Free and open-source OpenJDK (recommended)
- Oracle JDK - Free for development/personal use (commercial licensing applies for production)
Operating System
- Linux/macOS: Owlready2 automatically detects Java
- Windows: You may need to manually configure the Java path and add it to your system
PATH
Verify Java:
java --version
Next Steps#
- Background – Understand KGs and ontologies
- Quickstart – Generate your first KG in 5 minutes