Generated artifacts
LinkML is the single source of truth.
lokf.yaml defines the
classes, slots, enumerations, and their mappings to external vocabularies.
Every other artifact is generated from it and MUST NOT be edited by hand.
flowchart TD
Y["lokf.yaml<br/><em>LinkML — edit this</em>"]
Y -- gen-jsonld-context --> C["lokf.context.jsonld<br/>JSON-LD @context"]
Y -- gen-json-schema --> J["lokf.schema.json<br/>JSON Schema"]
Y -- gen-shacl --> S["lokf.shacl.ttl<br/>SHACL shapes"]
Y -- gen-owl --> O["lokf.owl.ttl<br/>OWL ontology"]
C -- "attach to frontmatter" --> R[("RDF graph")]
J -- "validate documents" --> R
S -- "validate graph" --> R
O -- "reason & align" --> R
| Artifact | Generated by | Purpose |
|---|---|---|
lokf.context.jsonld |
gen-jsonld-context* |
Turns concept frontmatter into JSON-LD / RDF. |
lokf.schema.json |
gen-json-schema |
Validates concept frontmatter (JSON Schema). |
lokf.shacl.ttl |
gen-shacl |
Validates the resulting RDF graph (SHACL). |
lokf.owl.ttl |
gen-owl |
Class/property ontology for reasoning & alignment. |
* The published context additionally aliases OKF’s type field to the
JSON-LD @type keyword and id to @id, so that authoring in plain OKF
frontmatter is enough to produce correctly-typed Linked Data.
Because meaning lives in the model, adding a field or a type is a one-line
change in lokf.yaml; the context, schema, shapes, and ontology all
re-derive:
just build # or: uv run lokf-buildWhat the build does
Section titled “What the build does”The lokf-build console script chains four steps: generate the
artifacts above, assemble examples/acme-knowledge/ into a single
KnowledgeBundle document, validate it with linkml-validate, and project it
to N-Triples in examples/.