EMMC-ASBL / tripper

Triplestore wrapper package for Python.
https://EMMC-ASBL.github.io/tripper
MIT License
7 stars 2 forks source link

Tripper

Triplestore wrapper for Python providing a simple and consistent interface to a range of triplestore backends.

PyPI Documentation CI tests DOI

Getting started

Basic concepts

Tripper provides a simple and consistent interface to a range of triplestore backends. It strives for simplicity and is modelled after rdflib (with a few simplifications).

In Tripper:

To make it easy to work with IRIs, provide Tripper a set of pre-defined namespaces, like XSD.float. New namespaces can be defined with the tripper.Namespace class.

A triplestore wrapper is created with the tripper.Triplestore class.

Advanced features

The submodules mappings and convert provide additional functionality beyond interfacing triplestore backends:

Available backends

The following backends are currently available, either in Tripper or other packages.

Backend name Provided by Requirements Comment
rdflib tripper rdflib In-memory rdflib triplestore supporting all features.
ontopy tripper EMMOntoPy Backend for EMMOntoPy. In-memory.
sparqlwrapper tripper sparqlwrapper Generic backend for all triplestores supported by sparqlwrapper.
collection tripper DLite-Python Backend to a DLite collection.
fuseki PyBackTrip sparqlwrapper Backend to fuseki.
stardog PyBackTrip sparqlwrapper,pystardog Backend to StarDog.
graphdb PyBackTrip sparqlwrapper Backend to GraphDB.

Installation

Tripper has by itself no dependencies outside the standard library, but the triplestore backends may have specific dependencies.

The package can be installed from PyPI using pip:

pip install tripper

In addition you would need to install the requirements for one or more of the backends listed in the table above. For mappings you would also need to install Pint. For example:

pip install rdflib pint

License and copyright

All files in this repository are licensed under the MIT license. If not stated otherwise in the top of the files, they have copyright © 2022 SINTEF.

Acknowledgements

We gratefully acknowledge the following projects for supporting the development of Tripper: