LinkML schema
Linked Open Knowledge Format (LOKF)
LOKF is a semantic, ontology-grounded profile of the Google Open Knowledge Format (OKF v0.2). It preserves OKF's authoring model — a directory of markdown files, each with a small YAML frontmatter block describing one concept — but binds every concept, field, and relationship to established web vocabularies (schema.org, W3C DCAT, and W3C PROV-O). Because the frontmatter keys are LinkML slots mapped to IRIs, a LOKF concept file, once a LinkML-generated JSON-LD @context is attached, is simultaneously human-readable markdown AND valid JSON-LD that expands losslessly to RDF triples. The entire format is defined in this single LinkML schema, from which the JSON-LD context, JSON Schema, SHACL shapes, and an OWL ontology are generated.
This repository holds no LinkML schema of its own, so the site shows the one its knowledge bundle is written in, LOKF 0.10.0.
Schema file: lokf.yaml, from the lokf 0.10.0 package the sidecar installs
URI: https://w3id.org/lokf/schema
Name: lokf
Diagram#
erDiagram
Agent {
uriorcurie id
string name
string email
string type
}
Audience {
string audienceType
integer suggestedMaxAge
integer suggestedMinAge
}
Citation {
string description
string title
uriorcurie url
}
Concept {
uriorcurie id
string description
string additionalType
string body
datetime created
string educationalLevel
DiataxisMode genre
uriorcurie license
uriorcurie resource
datetime stale_after
ConceptStatus status
stringList tags
datetime timestamp
string title
string type
string typicalAgeRange
string version
}
Exclusion {
string by
string reason
string resource
}
Generation {
datetime at
string by
string revision
}
KnowledgeBundle {
string description
uri base_iri
uri context
uriorcurie license
string lokf_version
string okf_version
string title
}
Refutation {
datetime at
string by
string reason
string revision
}
Relation {
RelationType predicate
string relation_label
}
Revision {
datetime at
string by
string revision
}
Source {
string id
string author
string excerpt
datetime last_modified
string resource
string title
integer usage_count
}
UsageWindow {
datetime from
datetime to
}
Verification {
datetime at
string by
string revision
}
Concept ||--|o Audience : "audience"
Concept ||--|o Generation : "generated"
Concept ||--|o Revision : "revised"
Concept ||--|o UsageWindow : "usage_window"
Concept ||--}o Agent : "author"
Concept ||--}o Citation : "citations"
Concept ||--}o Concept : "about, definedBy, dependsOn, derivedFrom, hasPart, isPartOf, isReplacedBy, references, relatedTo, sameAs, source"
Concept ||--}o Exclusion : "exclusions"
Concept ||--}o Refutation : "refuted"
Concept ||--}o Relation : "relations"
Concept ||--}o Source : "sources"
Concept ||--}o Verification : "verified"
KnowledgeBundle ||--|o Agent : "publisher"
KnowledgeBundle ||--}o Concept : "concepts"
Relation ||--|| Concept : "target"
Source ||--|o UsageWindow : "usage_window"Classes#
| Class | Description |
|---|---|
| Agent | A person or organization responsible for a concept |
| Organization | An organization, team, or group |
| Person | An individual person |
| Attester | The deterministic, non-LLM check for an Attested Computation (OKF v0 |
| Audience | The readers a concept is written for, as schema |
| Checksum | A digest of a distribution’s bytes, which a consumer recomputes before trusti… |
| Citation | A reference to an external source supporting a claim in a concept’s body |
| Concept | A single unit of knowledge within a bundle, represented as one markdown docum… |
| AttestedComputation | A sanctioned, immutable recipe for computing a value (OKF v0 |
| Dataset | A collection of data, published or curated for access and reuse |
| Table | A structured, tabular dataset (e |
| Document | A general knowledge document that does not fit a more specific type |
| Explanation | An understanding-oriented, discursive treatment of a topic that permits refle… |
| GlossaryTerm | A defined term in a controlled vocabulary or glossary |
| Metric | A precisely defined, measurable quantity — the canonical definition of a busi… |
| Playbook | A procedure or runbook — an ordered set of steps to accomplish a task or resp… |
| Policy | A governance, compliance, or operational policy document |
| Reference | A concept that mirrors an external source (a page, paper, or document) as a f… |
| Role | A role an agent holds within an organization over a period of time — a job, a… |
| Service | A callable service or API endpoint |
| Tutorial | A learning-oriented lesson: a guided, end-to-end practical activity through w… |
| Distribution | A specific accessible form of a Dataset (a file, feed, or endpoint) |
| Exclusion | A material the concept’s author looked at and left out on purpose, with the r… |
| Executor | How an Attested Computation is run (OKF v0 |
| Field | A single column / property within a Table or Dataset schema |
| Generation | How and when the current content was produced (OKF v0 |
| KnowledgeBundle | A self-contained, hierarchical collection of concept documents — the unit of … |
| Parameter | A typed, named hole in an Attested Computation that the agent may fill (OKF v… |
| Refutation | One refutation event: an actor found the content wrong against its sources or… |
| Relation | A typed, reified relationship from the containing concept to a target, used w… |
| Revision | The latest in-place edit of the content, for a producer that keeps `generated… |
| Source | A material a concept derives from (OKF v0 |
| UsageWindow | The { from, to } date range framing every usage_count signal (OKF v0 |
| Verification | One verification event (OKF v0 |
Slots#
| Slot | Description |
|---|---|
| abbreviation | A short form or acronym for a term |
| about | The subject matter this concept is about |
| access_url | A URL that gives access to a distribution |
| additionalType | The producer’s own type string when it names no LOKF class |
| algorithm | The algorithm that computed a checksum |
| at | ISO 8601 datetime at which the event completed |
| attester | The deterministic, non-LLM verdict check over a receipt |
| audience | The readers this concept is written for, such as readers aged 13 to 18, as an… |
| audienceType | The kind of reader, in words, such as students or dyslexic readers |
| author | The agent(s) responsible for authoring the concept |
| base_iri | The base IRI against which Concept IDs are resolved to produce each concept’s… |
| body | The markdown body of the concept document (everything after the frontmatter) |
| by | The actor that performed the event, as a plain OKF §7 actor string (`<produce… |
| byte_size | The size of the distribution in bytes |
| checksum | A digest of the distribution’s bytes, for checking a download |
| checksum_value | The checksum as lowercase hexadecimal digits, as many as the algorithm’s dige… |
| citations | External sources supporting claims in the body |
| computation | Optional path to a file holding the computation; absent means the body’s `# C… |
| concepts | The concepts contained in a bundle |
| constraints | Free-text or expression describing constraints on a field |
| context | The URL of the JSON-LD @context to attach to this bundle’s concepts to interp… |
| created | ISO 8601 datetime the concept was created |
| datatype | The data type of a field |
| definedBy | A resource that formally defines this concept |
| definition | The formal definition of a term |
| dependsOn | A concept this concept depends on |
| derivedFrom | An entity this concept was derived from (provenance) |
| description | A single-sentence summary of the concept |
| distribution | Accessible forms of the dataset |
| documentation | A link to the service’s documentation |
| educationalLevel | The level of education the concept is written for, in words or as the IRI of … |
| Contact email address | |
| endDate | The date the role ended; omit for a role still held |
| endpoint | The base URL or invocation endpoint of a service |
| excerpt | A verbatim copy of the passage in resource that the concept relies on, take… |
| exclusions | The materials this concept’s author considered and left out on purpose, each … |
| executor | How the computation is run and what evidence a run must return |
| fields | The columns / properties that make up a dataset’s schema |
| formula | The calculation or definition expression for a metric |
| from | Start (inclusive) of a usage window, an ISO 8601 datetime |
| generated | How and when the current content was produced: by (REQUIRED actor) and at… |
| genre | The Diátaxis documentation mode of the concept’s markdown body (tutorial, how… |
| hasPart | A concept that is a part of this concept |
| holder | The agent (typically a Person) who holds the role |
| http_method | The HTTP method used to invoke the service, if applicable |
| id | The concept’s stable IRI |
| is_key | Whether the field is (part of) the primary key |
| isPartOf | The target concept that this concept is a part of |
| isReplacedBy | A concept that supersedes this one, without asserting equivalence |
| last_modified | When the SOURCE itself last changed, an ISO 8601 datetime (a bare YYYY-MM-DD … |
| license | The license under which the concept or bundle is offered |
| lokf_version | The LOKF version the bundle targets (e |
| measures | What the metric measures (a concept IRI or description) |
| media_type | The media (MIME) type of a distribution |
| memberOf | The organization within which the role is held |
| name | A name |
| okf_version | The OKF version the bundle remains compatible with (e |
| parameters | The typed, named holes the agent may fill — the ONLY surface the agent may bi… |
| predicate | The relationship type |
| publisher | The agent responsible for making the bundle available |
| reason | The grounds for a decision, in a sentence a reviewer can check: why a materia… |
| receipt | The field names a run must return (e |
| references | A concept or resource this concept refers to |
| refuted | Refutation events: an actor found the content wrong against its sources or re… |
| relatedTo | A generic association to another concept |
| relation_label | An optional human-readable label for the relationship |
| relations | Typed relationships whose predicate is not covered by a named relation slot |
| required | Whether a value for the parameter must be supplied |
| resource | A URI that uniquely identifies the underlying real-world asset the concept de… |
| revised | The latest in-place edit of the content, as {by, at}, kept apart from `gene… |
| revision | The state of the resource this event refers to: a commit id, an ETag or versi… |
| roleName | The name/title of the role held (e |
| runtime | REQUIRED on an Attested Computation |
| sameAs | An IRI asserting this concept is the same entity as another |
| source | A resource from which this concept is derived or sourced |
| sources | The materials this concept derives from, each carrying objective credibility … |
| stale_after | The absolute instant on or after which the concept is stale (OKF §5 |
| startDate | The date the role began (ISO 8601 date or year) |
| status | Lifecycle status of the concept: draft |
| suggestedMaxAge | The oldest age, in years, the concept is written for |
| suggestedMinAge | The youngest age, in years, the concept is written for |
| tags | Short cross-cutting keywords for categorization |
| target | The IRI (or Concept ID) of the relationship’s object |
| timestamp | ISO 8601 datetime of the last meaningful change |
| title | Human-readable display name |
| to | End (inclusive) of a usage window, an ISO 8601 datetime |
| type | The concept’s type - OKF’s single required field |
| typicalAgeRange | The typical age range of the concept’s readers, as schema |
| unit | The unit of measurement (e |
| url | A URL |
| usage_count | How often the source’s resource was exercised (views, executions, reads) over… |
| usage_window | The { from, to } date range framing every usage_count |
| verified | Verification events confirming the content against its sources or resource |
| version | A version string for the concept’s content |
Enumerations#
| Enumeration | Description |
|---|---|
| ChecksumAlgorithm | Digest algorithms for a Checksum, each mapped to its SPDX individual |
| ConceptStatus | Lifecycle status of a concept (OKF v0 |
| DiataxisMode | The Diátaxis documentation mode of a concept’s body - an orthogonal facet des… |
| FieldType | Datatypes for dataset/table fields, each mapped to its XSD (or RDF) type |
| HttpMethod | The IANA HTTP request method registry, restricted to the methods a LOKF Servi… |
| ParameterType | Datatypes for Attested Computation parameters |
| RelationType | The recommended controlled vocabulary of relationship predicates for reified … |
Types#
| Type | Description |
|---|---|
| Boolean | A binary (true or false) value |
| Curie | a compact URI |
| Date | a date (year, month and day) in an idealized calendar |
| DateOrDatetime | Either a date or a datetime |
| Datetime | The combination of a date and time |
| Decimal | A real number with arbitrary precision that conforms to the xsd:decimal speci… |
| Double | A real number that conforms to the xsd:double specification |
| Float | A real number that conforms to the xsd:float specification |
| HexBinary | Binary data written as hexadecimal digits; maps to xsd:hexBinary |
| Integer | An integer |
| Jsonpath | A string encoding a JSON Path |
| Jsonpointer | A string encoding a JSON Pointer |
| Ncname | Prefix part of CURIE |
| Nodeidentifier | A URI, CURIE or BNODE that represents a node in a model |
| NonNegativeInteger | A whole number, 0 or more; maps to xsd:nonNegativeInteger |
| Objectidentifier | A URI or CURIE that represents an object in the model |
| Sparqlpath | A string encoding a SPARQL Property Path |
| String | A character string |
| Time | A time object represents a (local) time of day, independent of any particular… |
| Uri | a complete URI |
| Uriorcurie | a URI or a CURIE |
Subsets#
| Subset | Description |
|---|---|
| lokf_semantic | Extensions LOKF layers on top of OKF to achieve JSON-LD / RDF grounding, type… |
| okf_core | Fields and structural rules that already exist in OKF v0 |
| okf_v02 | Fields and structural rules introduced by OKF v0 |