Skip to content

Commit

Permalink
Merge pull request #18 from INCATools/sssom-mappings
Browse files Browse the repository at this point in the history
Adding aggregayor interface
  • Loading branch information
cmungall authored Apr 15, 2022
2 parents 55508da + efd8a49 commit 53b4b94
Show file tree
Hide file tree
Showing 36 changed files with 18,321 additions and 65 deletions.
16 changes: 16 additions & 0 deletions docs/implementations/aggregator.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
Aggregator Implementation
==================

.. warning ::
Highly incomplete!
This wraps any number of other implementations, multiplexing queries and aggregating results, treating
as if it were a single unified endpoints

Code
----

.. currentmodule:: oaklib.implementations.aggregator.aggregator_implementation

.. autoclass:: AggregatorImplementation
1 change: 0 additions & 1 deletion docs/implementations/bioportal.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ Code
.. currentmodule:: oaklib.implementations.bioportal.bioportal_implementation

.. autoclass:: BioportalImplementation
:members: create
3 changes: 3 additions & 0 deletions docs/implementations/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ The most mature implementations are:
obofiles
sqldb
robot
funowl
skos
ols
bioportal
Expand All @@ -30,4 +31,6 @@ The most mature implementations are:
ontobee
ols
bioportal
kgx
aggregator

1 change: 0 additions & 1 deletion docs/implementations/obofiles.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,3 @@ Code
.. currentmodule:: oaklib.implementations.pronto.pronto_implementation

.. autoclass:: ProntoImplementation
:members: create
5 changes: 2 additions & 3 deletions docs/implementations/ols.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@ Ontology Lookup Service (OLS) Endpoint

.. warning ::
not yet implemented!
very partially implemented!
When implemented this will also provide implementation of the mapping interface via OxO
Also provides interface to OxO

Code
----

.. currentmodule:: oaklib.implementations.ols.ols_implementation

.. autoclass:: OlsImplementation
:members: create
1 change: 0 additions & 1 deletion docs/implementations/ontobee.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,3 @@ Code
.. currentmodule:: oaklib.implementations.ontobee.ontobee_implementation

.. autoclass:: OntobeeImplementation
:members: create
1 change: 0 additions & 1 deletion docs/implementations/owlery.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,3 @@ Code
.. currentmodule:: oaklib.implementations.owlery.owlery_implementation

.. autoclass:: OwleryImplementation
:members: create
2 changes: 1 addition & 1 deletion docs/implementations/sparql.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ Sparql Endpoint
.. currentmodule:: oaklib.implementations.sparql.sparql_implementation

.. autoclass:: SparqlImplementation
:members: create

1 change: 0 additions & 1 deletion docs/implementations/ubergraph.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ Code
.. currentmodule:: oaklib.implementations.ubergraph.ubergraph_implementation

.. autoclass:: UbergraphImplementation
:members: create

.. autoclass:: RelationGraphEnum

Expand Down
2 changes: 2 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,12 @@ Ontology Access Kit (OAK) Documentation
:caption: Contents:

introduction
intro/index
architecture
interfaces/index
implementations/index
cli
selectors
datamodels/index
utilities
notebooks
Expand Down
7 changes: 7 additions & 0 deletions docs/interfaces/mapping-provider.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Mapping Provider
==============

.. currentmodule:: oaklib.interfaces.mapping_provider_interface

.. autoclass:: MappingProviderInterface
:members:
121 changes: 121 additions & 0 deletions docs/selectors.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
.. _selectors:

Ontology Implementation Selectors
=================

In the command line interface and in Python code, *descriptors* can be used as a shorthand way to refer to either a local or remote ontology, plus
a method for parsing/querying it. The OntologyResource that is returned can be used
to instantiate an implementation. The descriptors can also be used in the :ref:`cli`

Syntax
-----

A descriptor is EITHER:

- prefixed with a *scheme* OR
- is a *path (in which case the scheme is inferred)
Examples
-----

Examples of scheme-less descriptors, implicit implementation:

- :code:`tests/input/go-nucleus.obo` - local obo format file loaded with pronto
- :code:`tests/input/go-nucleus.json` - local obojson format file loaded with pronto
- :code:`tests/input/go-nucleus.owl` - local OWL rdf/xml format file (loaded with pronto at the moment may change)
- :code:`tests/input/go-nucleus.db` - local sqlite3 db loaded with SqlImplementation
- :code:`http://purl.obolibrary.org/obo/pato.obo` - NOT IMPLEMENTED; download locally for now
- :code:`http://purl.obolibrary.org/obo/pato.owl` - NOT IMPLEMENTED; download locally for now

Examples of explicit schemes:

- :code:`pronto:tests/input/go-nucleus.obo` - local obo format file loaded with pronto
- :code:`pronto:tests/input/go-nucleus.json` - local obojson format file loaded with pronto
- :code:`pronto:tests/input/go-nucleus.owl` - local OWL rdf/xml format file (loaded with pronto at the moment may change)
- :code:`pronto:tests/input/go-nucleus.db` - local sqlite3 db loaded with SqlImplementation
- :code:`prontolib:pato.obo` - remote obo format file loaded from OBO Library with pronto
- :code:`prontolib:pato.owl` - remote owl format file loaded from OBO Library with pronto
- :code:`bioportal:` all of bioportal
- :code:`bioportal:pato` pato in bioportal (NOT IMPLEMENTED)
- :code:`ontobee:` all of ontobee
- :code:`ontobee:pato` pato in ontobee (NOT IMPLEMENTED)
- :code:`ols:` all of OLS
- :code:`ols:pato` pato in OLS (NOT IMPLEMENTED)
- :code:`ubergraph:` all of OLS
- :code:`ubergraph:pato` pato in ubergraph (NOT IMPLEMENTED)

See :ref:`cli` for more examples

Schemes
-------

pronto
^^^^

Implementation: :ref:`ProntoImplementation`

The slug is a path to a file on disk. Must be in obo or owl or json

prontolib
^^^^

Implementation: :ref:`ProntoImplementation`

The slug is the name of the resource on obo, e.g. pato.obo, cl.owl

sqlite
^^^^

Implementation: :ref:`SqlImplementation`

The slug is the path to the sqlite .db file on local disk

obosqlite
^^^^

Implementation: :ref:`SqlImplementation`

The slug is the name of the ontology, e.g 'hp', 'uberon'

TODO: download from s3

ontobee
^^^^

Implementation: :ref:`OntobeeImplementation`

Currently the slug is ignored

ols
^^^^

Implementation: :ref:`OlsImplementation`

Currently the slug is ignored

bioportal
^^^^

Implementation: :ref:`BioportalImplementation`

Currently the slug is ignored

funowl
^^^^

Implementation: :ref:`OwlImplementation`

NOT IMPLEMENTED YET

owlery
^^^^

Implementation: :ref:`OwleryImplementation`

NOT IMPLEMENTED YET

Functions
----

.. automodule:: oaklib.selector
:members:
7 changes: 6 additions & 1 deletion docs/utilities.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,15 @@ Where possible, this library uses simple standalone python functions organized i
Note: some of these may involve iterated calls on a remote backend, these are candidates for
being turned into :ref:`interfaces`.

.. currentmodule:: oaklib
:toctree: src

selector

.. currentmodule:: oaklib.utilities

.. autosummary::
:toctree: DIRNAME
:toctree: src

obograph_utils
graph.relationship_walker
Expand Down
3 changes: 3 additions & 0 deletions src/oaklib/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,6 @@
"""
__version__ = '0.1.0'

from oaklib.interfaces import BasicOntologyInterface

Loading

0 comments on commit 53b4b94

Please sign in to comment.