Skip to content

owlapy 1.2.0

Compare
Choose a tag to compare
@alkidbaci alkidbaci released this 06 Aug 13:52
· 209 commits to develop since this release

New release is out: owlapy 1.2.0

pip install -U owlapy

What's Changed

Owlapi Adaptor extended: #52 #53

  • Added infer_and_save method which you can use to generate inferred class assertion axioms from the given ontology and saves them to a file.
  • You can now use all the methods of the abstract class OWLReasoner from OWLAPIAdaptor or from an instance of SyncReasoner.

SyncReasoner updated: #53

  • SyncReasoner is no longer depended on owlready2 but now syncs directly to an owlapi reasoner like HermiT, etc.
  • Every implemented method of OWLReasoner now is forwarded to the synced reasoner.

2 new short form providers added for DLSyntaxObjectRenderer: #56

  • Added translating_short_form_provider. This is used for local ontologies mainly. Uses a reasoner to get the label value.

  • Added translating_short_form_endpoint. This is used for triplestores . Given an endpoint and a set of rules it will provide the desired behavior using SPARQL queries.

  • This providers enables the user to set rules for the representation value that will be used in a DL string after rendering.

    Initialize using partial from functools:

    from functools import partial
    
    partial_provider = partial(translating_short_form_endpoint, endpoint="https://some_endpoint.com/sparql", rules={})
    renderer = DLSyntaxObjectRenderer(short_form_provider=partial_provider)

    Check the docstrings for more details.

Full Changelog: 1.1.1...1.2.0