Ontodocs
Ontodocs is a Python command line application aimed at facilitating the creation of documentation for ontologies encoded in RDF/OWL.
Links
Examples
- Schema.org documentation.
- FOAF documentation.
That's the kind of documentation OntoDocs can generate out-of-the-box. For even more examples, take a look at this page.
Installation
pip install ontodocs -U
Description
Ontodocs allows to generate documentation for an RDF vocabulary, using visualization algorithms that create simple HTML pages, Markdown files, or more complex javascript interactive charts based on D3.js.
> Ontodocs -h
Usage: ontodocs [OPTIONS] [SOURCE]...
Ontodocs allows to create documentation for ontologies encoded in
RDF/OWL.
E.g.:
> ontodocs http://www.w3.org/2008/05/skos# --theme random -o
~/Desktop/skos
==> generates html docs for the SKOS ontology and save it to your desktop
Options:
-o, --outputpath TEXT Output path (default: home folder).
-t, --title TEXT Title for the visualization (default=graph uri).
--theme TEXT CSS Theme for the html-complex visualization
(random=use a random theme).
--showthemes Show the available CSS theme choices.
-v, --verbose Verbose mode.
-h, --help Show this message and exit.
The library is not really meant to be used programmatically, but I'm sure there are a few constructs in there which can be reused.
In a nutshell, all visualizations inherit from a VizFactory class that abstracts away the most common operations involved in rendering a dataviz.
This is how you would invoke a visualization from a script:
import ontospy
from ontodocs.viz.viz_html_single import *
g = ontospy.Ontospy("http://cohere.open.ac.uk/ontology/cohere.owl#")
v = HTMLVisualizer(g) # => instantiate the visualization object
v.build() # => render visualization. You can pass an 'output_path' parameter too
v.preview() # => open in browser
Dependencies
Ontodocs relies on the OntoSpy library, which itself relies on Rdflib.
note: the functionalities of Ontodocs used to be part of OntoSpy until v1.8.
Metadata
Release files for ontodocs 1.2.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ontodocs-1.2.2.tar.gz | 3.6 MB | Without provenance | Details for ontodocs-1.2.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ontodocs-1.2.2-py2.py3-none-any.whl | Python 2, Python 3 | none | any | Details for ontodocs-1.2.2-py2.py3-none-any.whl |
Total release size: 7.4 MB
Release files / ontodocs-1.2.2.tar.gz
| Download URL | ontodocs-1.2.2.tar.gz |
|---|---|
| Size | 3.6 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1c1518c9caf38ca17de2b4c61dda24fe261530847d854cb1c25f9e1f4767b6f9
|
|
BLAKE2b-256 checksum How to use checksums |
9a9c5b5085512f39738ee1b0e4cfc4c3ee07e7a47088cb9e2fea5c602e4abc44
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.0
|
Release files / ontodocs-1.2.2-py2.py3-none-any.whl
| Download URL | ontodocs-1.2.2-py2.py3-none-any.whl |
|---|---|
| Size | 3.8 MB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
3f0c92d4e982e09c261c0845248314935ed81fcb45ff0245c4ceb6ee92b3adcf
|
|
BLAKE2b-256 checksum How to use checksums |
243e3083c4dfd921cec05a5ffa33c457d9cd72d91cf2591bb3bb7f00e72dc393
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.0
|
Security for ontodocs 1.2.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.