Generate a LinkML schema, an Obsidian-ready Markdown vault and MkDocs from an OWL ontology.
- On Ubuntu LTS with a managed Python, avoid system-wide
pip(PEP 668). Use a venv:sudo apt-get install -y python3-venv python3-pippython3 -m venv .venvsource .venv/bin/activatepip install -e .- Run
owl2vault ...while the venv is active (or use.venv/bin/owl2vault).
- Generate Docsify output and serve it locally:
owl2vault -i path/to/schema.owl --docsify output/docsifycd output/docsify && python -m http.server 8000- Site serves at http://127.0.0.1:8000 (change port by replacing
8000).
- Generate Hugo output and serve it locally (requires Hugo installed):
owl2vault -i path/to/schema.owl --hugo output/hugocd output/hugo && hugo server- Site serves at http://127.0.0.1:1313 by default (change port with
hugo server -p 9000).
-i / --input: path to the OWL file to load.--url: URL to download an OWL file to use as input.--linkml: path to write the generated LinkML YAML.--vault: directory to write the Obsidian vault (createsClasses/,Enums/,Object_Properties/,Data_Properties/,Annotation_Properties/,00-Index/).--mkdocs: directory to write a MkDocs project (mkdocs.yml+docs/with markdown).--docsify: directory to write a Docsify project (index.html+docs/with markdown).--hugo: directory to write a Hugo project (config.toml+content/with markdown).--log-level:ERROR|WARNING|INFO|DEBUG(default:INFO).
- Generate LinkML YAML only:
owl2vault -i path/to/schema.owl --linkml output/schema.yaml
- Generate an Obsidian vault only:
owl2vault -i path/to/schema.owl --vault output/vault
- Generate MkDocs docs only:
owl2vault -i path/to/schema.owl --mkdocs output/mkdocs
- Generate Docsify docs only:
owl2vault -i path/to/schema.owl --docsify output/docsify
- Generate a Hugo site only:
owl2vault -i path/to/schema.owl --hugo output/hugo
- Generate both MkDocs and Docsify in one run:
owl2vault -i path/to/schema.owl --mkdocs output/mkdocs --docsify output/docsify
- Generate MkDocs, Docsify, and Hugo together:
owl2vault -i path/to/schema.owl --mkdocs output/mkdocs --docsify output/docsify --hugo output/hugo
- Pull OWL from a URL then generate everything:
owl2vault --url https://ekgf.github.io/dprod/dprod.ttl --linkml output/schema.yaml --vault output/vault --mkdocs output/mkdocs
- Build and serve MkDocs docs after generation:
cd output/mkdocs && mkdocs build && mkdocs serve(serve at http://127.0.0.1:8000 by default)
- MkDocs dependencies for theming/graphs:
pip install mkdocs-materialpip install "mkdocs-material[imaging]"pip install mkdocs-network-graph-plugin
- Do both with verbose logging:
owl2vault -i path/to/schema.owl --linkml output/schema.yaml --vault output/vault --log-level DEBUG
- Generate LinkML YAML, then build markdown docs with linkml’s generator:
owl2vault -i path/to/schema.owl --linkml output/schema.yamlgen-doc --format markdown --output docs/ output/schema.yaml
- LinkML: YAML schema with classes, slots, enums, and properties.
- Obsidian vault: per-entity markdown notes under
Classes/,Enums/,Object_Properties/,Data_Properties/,Annotation_Properties/,Datatypes/,Individuals/, plus00-Index/Index.mdlinking everything. Notes use stable IRI-derived IDs and headings use labels when available (IRI fallback). Class sections list “Properties” (not “Slots”), and annotation predicates/IRI-valued annotations display resolved labels where available. - MkDocs:
mkdocs.yml(uses thematerialtheme withgraph,search, andoptimizeplugins) plusdocs/with markdown grouped intoclasses/,enums/,object_properties/,data_properties/,annotation_properties/,datatypes/,individuals/, and anindex.mdlinking everything. Usemkdocs buildto generate a site. Annotation predicates/IRI-valued annotations are rendered with their labels when present. - Docsify:
index.htmlplusdocs/with markdown grouped intoclasses/,enums/,object_properties/,data_properties/,annotation_properties/,datatypes/,individuals/, and aREADME.mdhome page._sidebar.mdis generated from the same nav structure. - Hugo:
config.tomlpluscontent/with markdown grouped intoclasses/,enums/,object_properties/,data_properties/,annotation_properties/,datatypes/,individuals/, and a_index.mdhome page.
- Current version: 0.1.8