Owlapy

Latest version: v1.4.0

Safety actively analyzes 710644 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 3

1.4.0

We are happy to share this new release with the community.

Installation/upgrade using PyPI:


pip install -U owlapy


Changes Summary:
- You will now find more literal types.
- A new feature to use CSV data for RDF KG construction is added as well as `RDFLibOntology` .
- Added new CLI command `owlapy-serve` to start owlapy API server.
- Optimization, bug fixing and more tests added to ensure the code reliability.

You can check the details below:

All Changes (+ PRs)
* New literals by alkidbaci in https://github.com/dice-group/owlapy/pull/109
* From CSV to RDF Knowledge Graph by Demirrr in https://github.com/dice-group/owlapy/pull/108
* A CSV file is mapped to an RDF KGs containing only literals by Demirrr in https://github.com/dice-group/owlapy/pull/110
* Refactoring by Demirrr in https://github.com/dice-group/owlapy/pull/111
* Complement of complement fix by LckyLke in https://github.com/dice-group/owlapy/pull/113
* Fix for 112 by Demirrr in https://github.com/dice-group/owlapy/pull/114
* RDFlib based ontology implemented by Demirrr in https://github.com/dice-group/owlapy/pull/116
* Olwapy serve by LckyLke in https://github.com/dice-group/owlapy/pull/117
* Added mapping for OWLObjectInverseOf by alkidbaci in https://github.com/dice-group/owlapy/pull/122
* owlapy_serve usage in examples folder by LckyLke in https://github.com/dice-group/owlapy/pull/121
* Bug fixing by alkidbaci in https://github.com/dice-group/owlapy/pull/127


**Full Changelog**: https://github.com/dice-group/owlapy/compare/1.3.3...1.4.0

1.3.3

In this new patch we have fixed some hashing-related bugs, made some refactoring for `SyncReasoner` and `StructuralReasoner` where we are planning to remove caching. A new function is also introduced which saves owl class expressions.

To install or upgrade:


pip install -U owlapy


What's Changed
* changing _values to frozenset to allow for hashing by LckyLke in https://github.com/dice-group/owlapy/pull/96
* save_owl_class_expressions and test included by Demirrr in https://github.com/dice-group/owlapy/pull/99
* Refactor structural reasoner by LckyLke in https://github.com/dice-group/owlapy/pull/100
* Test hashes by Demirrr in https://github.com/dice-group/owlapy/pull/102
* Refactoring sync reasoner by Demirrr in https://github.com/dice-group/owlapy/pull/105

New Contributors
* LckyLke made their first contribution in https://github.com/dice-group/owlapy/pull/96

**Full Changelog**: https://github.com/dice-group/owlapy/compare/1.3.2...1.3.3

1.3.2

We have a new early release this time where we have fixed/improved the DL and Manchester renderer and parser and made some fundamental refactoring to our oldest reasoners. Check the respective PRs for more details.

Install/Upgrade:


pip install -U owlapy


What's Changed
* Direct and Inverse Mappings Owlapy objects into DL syntax in string and Manchester syntax string by Demirrr in https://github.com/dice-group/owlapy/pull/90
* Refactoring on owl reasoners and some fixes/improvements by alkidbaci in https://github.com/dice-group/owlapy/pull/92


**Full Changelog**: https://github.com/dice-group/owlapy/compare/1.3.1...1.3.2

1.3.1

You can find more details in the PRs below.

Install/Upgrade:

pip install -U owlapy


What's Changed
* New terminal command by alkidbaci in https://github.com/dice-group/owlapy/pull/68
* Issues solving by alkidbaci in https://github.com/dice-group/owlapy/pull/72
* fixing issue with OWLNothing + new parameter for `OWLReasoner.instances` by alkidbaci in https://github.com/dice-group/owlapy/pull/73
* Removed unused jar files by alkidbaci in https://github.com/dice-group/owlapy/pull/76
* New methods for SyncOntology and SyncReasoner by alkidbaci in https://github.com/dice-group/owlapy/pull/77
* SPARQL query returning a confusion matrix by nkaralis in https://github.com/dice-group/owlapy/pull/83
* Confusion matrix query improvements by nkaralis in https://github.com/dice-group/owlapy/pull/85
* Owl sqarql refactoring by Demirrr in https://github.com/dice-group/owlapy/pull/84


**Full Changelog**: https://github.com/dice-group/owlapy/compare/1.3.0...1.3.1

1.3.0

Happy to share with you version 1.3.0 of owlapy. We present some new classes as well as some important changes. Feel free to read the highlights below.

As always you can upgrade using pip:


pip install -U owlapy


New
- Added new ontology manager: [SyncOntologyManager](https://dice-group.github.io/owlapy/autoapi/owlapy/owl_ontology_manager/index.html#owlapy.owl_ontology_manager.SyncOntologyManager).
- Added new ontology: [SyncOntology](https://dice-group.github.io/owlapy/autoapi/owlapy/owl_ontology/index.html#owlapy.owl_ontology.SyncOntology).
- Added new mappings in [OWLAPIMapper ](https://dice-group.github.io/owlapy/autoapi/owlapy/owlapi_mapper/index.html#owlapy.owlapi_mapper.OWLAPIMapper).
- Added new package [owlapy.abstracts](https://dice-group.github.io/owlapy/autoapi/owlapy/abstracts/index.html).
- Added _'Structural'_ reasoner as an new reasoner option for _SyncReasoner_.

Changes
- ***OWLAPIAdaptor is removed/disbanded***. Its methods are now moved directly to [SyncReasoner](https://dice-group.github.io/owlapy/autoapi/owlapy/owl_reasoner/index.html#owlapy.owl_reasoner.SyncReasoner).
- [OWLAPIMapper ](https://dice-group.github.io/owlapy/autoapi/owlapy/owlapi_mapper/index.html#owlapy.owlapi_mapper.OWLAPIMapper) is now initialized using `SyncOntology`.
- `SyncReasoner` and `SyncOntology` can now be initialized directly using the path of the ontology (instead of the IRI).
- Abstract classes [OWLReasoner](https://dice-group.github.io/owlapy/autoapi/owlapy/abstracts/abstract_owl_reasoner/index.html#owlapy.abstracts.abstract_owl_reasoner.OWLReasoner), [OWLReasonerEx](https://dice-group.github.io/owlapy/autoapi/owlapy/abstracts/abstract_owl_reasoner/index.html#owlapy.abstracts.abstract_owl_reasoner.OWLReasonerEx), [OWLOntology](https://dice-group.github.io/owlapy/autoapi/owlapy/abstracts/abstract_owl_ontology/index.html#owlapy.abstracts.abstract_owl_ontology.OWLOntology), [OWLOntologyManager](https://dice-group.github.io/owlapy/autoapi/owlapy/abstracts/abstract_owl_ontology_manager/index.html#owlapy.abstracts.abstract_owl_ontology_manager.OWLOntologyManager) and [OWLOntologyChange](https://dice-group.github.io/owlapy/autoapi/owlapy/abstracts/abstract_owl_ontology_manager/index.html#owlapy.abstracts.abstract_owl_ontology_manager.OWLOntologyChange) moved to subpackage [owlapy.abstracts](https://dice-group.github.io/owlapy/autoapi/owlapy/abstracts/index.html).
- 'add' and 'remove' axiom methods are moved from _OWLOntologyManager_ to _OWLOntology_. This comes with parameters changes. Check the docstrings.
- Signature changes on methods of OWLReasoner:
- The argument `only_named` is no longer a required argument of the abstract methods
- The argument `direct` is no longer required on the following methods: `data_property_values`, `object_property_values` and `all_data_property_values`.
- JPype start and stop functions moved to `owlapy/sync_functions.py`.

Docs
- Documentation updated in accordance.
- README updated in accordance.

PRs
62 64

**Full Changelog**: https://github.com/dice-group/owlapy/compare/1.2.1...1.3.0

1.2.1

OWL Reasoners for Type Inference and Ontology Enrichment

With OWLAPI integration, we can enjoy owlapi in python.
For instance, OWL Reasoners like 'HermiT' and 'Pellet' can be easily used to infer missing type information.

python
from owlapy.owl_ontology_manager import OntologyManager
from owlapy.owlapi_adaptor import OWLAPIAdaptor

ontology_path = "KGs/Family/family-benchmark_rich_background.owl"
Available OWL Reasoners: 'HermiT', 'Pellet', 'JFact', 'Openllet'
owlapi_adaptor = OWLAPIAdaptor(path=ontology_path, name_reasoner="Pellet")
onto = OntologyManager().load_ontology(ontology_path)
Iterate over defined owl Classes in the signature
for i in onto.classes_in_signature():
Performing type inference with Pellet
instances=owlapi_adaptor.instances(i,direct=False)
print(f"Class:{i}\t Num instances:{len(instances)}")
owlapi_adaptor.stopJVM()


What's Changed
* Merge to main v1.1.1 by alkidbaci in https://github.com/dice-group/owlapy/pull/50
* infer_save() implemented to infer different types of axioms by Demirrr in https://github.com/dice-group/owlapy/pull/52
* Owlapi adaptor changes and SyncReasoner update by alkidbaci in https://github.com/dice-group/owlapy/pull/53
* Owl to sentence by Demirrr in https://github.com/dice-group/owlapy/pull/56
* Added logo, bandages and more by alkidbaci in https://github.com/dice-group/owlapy/pull/57
* Owlapy mapper extension and infer methods of adapter by alkidbaci in https://github.com/dice-group/owlapy/pull/58
* Refactoring and Readme Update by Demirrr in https://github.com/dice-group/owlapy/pull/59
* New Release 1.2.1 by Demirrr in https://github.com/dice-group/owlapy/pull/61


**Full Changelog**: https://github.com/dice-group/owlapy/compare/1.1.1...1.2.1

Page 1 of 3

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.