# Ontology

In computing, an ontology defines the kinds of things a system describes, the relationships between them and the consequences of its definitions. It can answer a question that a topic hierarchy alone cannot, such as which organization developed a particular release.

[Thomas R. Gruber · A Translation Approach to Portable Ontology Specifications](https://tomgruber.org/writing/ontolingua-kaj-1993.pdf)

## Start with a question

Ask what someone should be able to retrieve or infer. To answer which research lab released a model, define Organization, Model and Release. Decide whether the developer of a model and the publisher of a particular release can be different organizations. Those choices belong in the vocabulary and its documentation.

[Thomas R. Gruber · A Translation Approach to Portable Ontology Specifications](https://tomgruber.org/writing/ontolingua-kaj-1993.pdf) · [W3C · OWL 2 Primer, second edition](https://www.w3.org/TR/2012/REC-owl2-primer-20121211/)

## How inference works

A subclass relation applies to every member of the narrower class. Declaring that a ModelRelease is a Release lets a reasoner infer that each individual ModelRelease is also a Release. OWL also expresses properties between individuals, equivalent classes and disjoint classes. Add an axiom only when its consequences hold for every case it covers.

[W3C · OWL 2 Document Overview](https://www.w3.org/TR/2009/REC-owl2-overview-20091027/) · [W3C · OWL 2 Primer, second edition](https://www.w3.org/TR/2012/REC-owl2-primer-20121211/)

## Checking incoming data

OWL’s open-world semantics lets unknown facts remain unknown. A wiki might additionally require each submitted release record to contain a source URL. A SHACL shape can check that concrete requirement and report a missing value. Keep the source of each factual assertion available for inspection.

[W3C · Shapes Constraint Language](https://www.w3.org/TR/2017/REC-shacl-20170720/)

## Beginner

A person, an organization and an event are different kinds of entity. A person can participate in a release event and an organization can publish it.

[Thomas R. Gruber · A Translation Approach to Portable Ontology Specifications](https://tomgruber.org/writing/ontolingua-kaj-1993.pdf) · [W3C · OWL 2 Primer, second edition](https://www.w3.org/TR/2012/REC-owl2-primer-20121211/)

## Intermediate

If WikiLab is recorded as an Organization and releasedBy links release R to WikiLab, a query can return the publishing organization directly. Add a different property for the model’s training organization if those roles matter.

[W3C · OWL 2 Document Overview](https://www.w3.org/TR/2009/REC-owl2-overview-20091027/) · [W3C · OWL 2 Primer, second edition](https://www.w3.org/TR/2012/REC-owl2-primer-20121211/)

## Advanced

Test two fixtures against a release shape that requires at least one source URL. A release with a source should pass. A release with an empty source list should yield a validation result even though the open-world ontology remains consistent.

[W3C · Shapes Constraint Language](https://www.w3.org/TR/2017/REC-shacl-20170720/)

## Timeline

- 1993 — Gruber publishes an approach to sharing ontology definitions across systems [Thomas R. Gruber · A Translation Approach to Portable Ontology Specifications](https://tomgruber.org/writing/ontolingua-kaj-1993.pdf)

- 2004-02-10 — W3C issues its first OWL Web Ontology Language Recommendation [W3C · OWL Web Ontology Language Overview](https://www.w3.org/TR/2004/REC-owl-features-20040210/)

- 2009-10-27 — W3C publishes OWL 2 with defined semantics and reasoning profiles [W3C · OWL 2 Document Overview](https://www.w3.org/TR/2009/REC-owl2-overview-20091027/)

- 2017-07-20 — SHACL becomes a W3C Recommendation for validating RDF graphs [W3C · Shapes Constraint Language](https://www.w3.org/TR/2017/REC-shacl-20170720/)

## Related articles

[Taxonomy](/wiki/taxonomy/)

[Datalog](/wiki/datalog/)
