Templates as ontologies

latest update: 2019-11--09    


In this topic the role of templates as ontologies is discussed.

Definitions of Ontology

The following two definitions seem applicable here:

Definition #1
In the context of computer and information sciences, an ontology defines a set of representational primitives with which to model a domain of knowledge or discourse. The representational primitives are typically classes (or sets), attributes (or properties), and relationships (or relations among class members). The definitions of the representational primitives include information about their meaning and constraints on their logically consistent application. In the context of database systems, ontology can be viewed as a level of abstraction of data models, analogous to hierarchical and relational models, but intended for modeling knowledge about individuals, their attributes, and their relationships to other individuals. Ontologies are typically specified in languages that allow abstraction away from data structures and implementation strategies; in practice, the languages of ontologies are closer in expressive power to first-order logic than languages used to model databases. [Gruber, 2007]

Definition #2
An ontology is a formal description of knowledge as a set of concepts within a domain and the relationships that hold between them. To enable such a description, we need to formally specify components such as individuals (instances of objects), classes, attributes and relations as well as restrictions, rules and axioms. As a result, ontologies do not only introduce a sharable and reusable knowledge representation but can also add new knowledge about the domain. [Ontotext USA, Web Home Page, Sept, 2019]

Application of definitions

Definition #1
The Upper Ontology of ISO 15926-2 actually defines that "
set of representational primitives" used to model the domain of discourse of a template. Furthermore the language of the "lifted" templates is indeed first-order logic. The link between that abstraction of the " lifted" templates and the implementation strategy of using "lowered" templates is implemented by defining a "signature" for each lowered template in which only the variables are listed, whilst maintaining the link to that abstraction.

Definition #2
In the Template Specifications and the OWL representation of the "lowered templates" those "
individuals (instances of objects), classes, attributes and relations as well as restrictions, rules and axioms" are formally specified for each template.


ISO 15926-7  templates are about ISO 15926-2 Classes and about PossibleIndividual's, where the formers are metaclasses and the latters actually are classes that have real world individuals as members (see here for a further explanation).

An instance of a template has an instance of its signature with declared instances of the (rdf:)objects listed there. For example the template IndividualHasPropertyWithValue:

The graph, built from above "set of representational primitives", is:

This template has a FOL listing that builds on the entity types of ISO 15926-2 to define the semantics of this template/ontology:
IndividualHasPropertyWithValue(x1, x2, x3, x4) <->
PossibleIndividual(x1) Ʌ
ClassOfProperty(x2) Ʌ
ExpressReal(x3) Ʌ
Scale(x4) Ʌ
exists u1 exists u2 exists u3 exists u4 exists u5 exists u6(
PossibleIndividual(u1) Ʌ
TemporalWholePartTemplate(u1, x1) Ʌ
Property(u2) Ʌ
ClassificationTemplate(u2, u1) Ʌ
ClassificationTemplate(u2, x2) Ʌ
PropertyQuantificationTriple(u3, u2, u4) Ʌ
ClassificationTemplate(u3, x4) Ʌ
RealNumber(u4) Ʌ
ClassOfIdentificationTemplate(x3, u4) Ʌ
PointInTime(u5) Ʌ
BeginningTemplate(u5, u1) Ʌ
ClassOfIdentificationTemplate(u6, u5) Ʌ
RepresentationOfGregorianDateAndUtcTime(u6)) .
and of the signature of its " lowered" template:

or in RDF:

          rdf:type owl:Class ;
          rdfs:subClassOf tpl:
TemplateForPropertyAndStatusOfIndividual ;
          tpl:hasPropertyPossessor dm:PossibleIndividual ;
          tpl:hasPropertyType dm:ClassOfProperty ;
          tpl:valPropertyValue dm:ExpressReal ;
          tpl:hasScale dm:Scale

An instance of this template could have the following semantics, as indicated in above graph: "[VESSEL] [V-101] has a [WEIGHT] of 30.57 [METRIC TON]".

This requires the following instances of the template type and its Role Object Types:

:9c88e964-f7ac-4056-ac16-c4dc68b80212 rdf:type tpl:IndividualHasPropertyWithValue ;
          rdfs:label "[VESSEL] [V-101] has a [WEIGHT] of 30.57 [METRIC TON]" ;
          tpl:hasPropertyPossessor :e8802675-6153-4e0e-9584-4fa2060efe05 ; # UUID of vessel V-101
          tpl:hasPropertyType rdl:RDS7285420 ; # WEIGHT as listed in the Reference Data Library
          tpl:valPropertyValue "30.57"^^xsd:decimal ;
          tpl:hasScale dm:Scale rdl:RDS2229868 . # METRIC TON as listed in the Reference Data Library

The contents then are being validated with SHACL, to see whether these Role Objects are indeed instances of the Role Object Types of the template signature.

Note that this information can be, from a technical point of view, total nonsense. This is because of the following statement in ISO 15926-2 subclause 4.1 applies:

"To enable integration of life-cycle process plant information the model excludes all information constraints that are appropriate only to particular applications within the scope."

This means that the source applications, from which data elements are being mapped to ISO 15926-7/8 templates, are assumed to deliver semantically and technically correct information.


Templates, with their signatures, are still cryptic for most users. To alleviate this Specialized Templates, called TIPs (Template of Information Pattern), have been designed. In these TIPs one or more Role Object Types are being instantiated pre-emptively, in certain cases by means of a selection from a pick-list of applicable/allowable class instances.

A TIP signature is being populated with label values because those are recognized by the users, and the mapping software sees to it that in cases where the labeled object has already been declared a duplication is avoided. If not declared, the software allows for automatic declaration or user-controlled declaration (the latter is safer).

TIP Signature

TIP software works with TIP signatures where the Role Object Types are instantiated with their label.
The TIP signature of above template is:
tip:IND-has-Property-with-Value-signature rdf:type dm:MultidimensionalObject ;
        :element1 :IND-has-Mass
-in-metric-ton_var_Label-1 ;
        :element2 :
IND-has-Mass-in-metric-ton_var_Label-2 ;
        :element3 :IND-has-Mass-in-metric-ton_var_Value-1 ;
:IND-has-Mass-in-metric-ton_var_Label-3 ;
        :element5 :
IND-has-Mass-in-metric-ton_var_LifecycleActivity ;
        :element6 :
IND-has-Mass-in-metric-ton_var_EffectiveDate .

which can be completed by replacing the labels and values (literals) applicable for one data element, e.g.:

:9c88e964-f7ac-4056-ac16-c4dc68b80212 rdf:type tip:IND-has-Property-with-Value ;
"V-101" ;
"30.57" ;
        :element4 "METRIC TON"
"VESSEL ENGINEERING" ; (selected from a pick-list of life-cycle activities)
        :element6 "2019-10-03T15:38:00Z" .

which is roughly what may be expected in a source document or table, and can be mapped from there with, in most cases, simple ETL
(Extract, Transform and Load) tool, resulting in an instance of the base template:

:9c88e964-f7ac-4056-ac16-c4dc68b80212 rdf:type tpl:IndividualHasPropertyWithValue ;
          rdfs:label "[VESSEL] [V-101] has a [WEIGHT] of 30.57 [METRIC TON]" ;
          tpl:hasPropertyPossessor ::e8802675-6153-4e0e-9584-4fa2060efe05 ; # UUID of vessel V-101
          tpl:hasPropertyType rdl:RDS7285420 ; # WEIGHT
          tpl:valPropertyValue "30.57"^^xsd:decimal ;
          tpl:hasScale rdl:RDS2229868 . # METRIC TON
          meta:hasLifecycleActivity rdl:RDS2223141 ; # VESSEL ENGINEERING
          meta:valEffectiveDate "2019-10-03T15:38:00Z"^^xsd:dateTime .

Note that two meta data have been added:
  1. meta:hasLifecycleActivity - the activity creating the template
  2. meta:hasEffectiveDate - the dateTime at which the information, represented by the template, has become effective, i.e.has been created.

Specialized TIPs

TIPs can, and in most cases do, represent specialized templates, where one or more of the values are already filled out

For example, the signature for an IND-has-Weight-in-metric-ton is:
tip:IND-has-Weight-in-metric-ton-signature rdf:type dm:MultidimensionalObject ;
        :element1 :IND-has-
Weight-in-metric-ton_var_Label-1 ;
        :element3 :I
ND-has-Weight-in-metric-ton_var_Value-1 ;
        :element4 "METRIC TON"
        :element5 :
IND-has-Weight-in-metric-ton_var_LifecycleActivity ;
        :element6 :
IND-has-Weight-in-metric-ton_var_EffectiveDate .

which is easier to understand than the generic name of the base template IND-has-Property-with-Value.

Using the base template for the end result, however, is done because the TIP information is dependent on the TIP software, but there are, or will be, other ways to instantiate a template and using the base template for the end result guarantees a code that can be understood globally.


After conversion to N triples, this code is uploaded to a triple store of (in this example) the XYZ Corp.Project P1234 as:

<http://www.p1234.xyz-corp.com/9c88e964-f7ac-4056-ac16-c4dc68b80212> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://data.15826.org/tpl/IndividualHasPropertyWithValue> .
<http://www.p1234.xyz-corp.com/9c88e964-f7ac-4056-ac16-c4dc68b80212> <http://data.15826.org/tpl/hasPropertyPossessor>       <http://www.p1234.xyz-corp.com/e8802675-6153-4e0e-9584-4fa2060efe05> .
<http://www.p1234.xyz-corp.com/9c88e964-f7ac-4056-ac16-c4dc68b80212> <http://data.15826.org/tpl/hasPropertyType>               <http://data.15826.org/rdl/RDS7285420> .
<http://www.p1234.xyz-corp.com/9c88e964-f7ac-4056-ac16-c4dc68b80212> <http://data.15826.org/tpl/valPropertyValue>               "30.57"^^<http://www.w3.org/2001/XMLSchema#decimal> .
<http://www.p1234.xyz-corp.com/9c88e964-f7ac-4056-ac16-c4dc68b80212> <http://data.15826.org/tpl/hasScale>                             <http://data.15826.org/rdl/RDS2229868> .
<http://www.p1234.xyz-corp.com/9c88e964-f7ac-4056-ac16-c4dc68b80212> <http://data.15826.org/meta/hasLifecycleActivity>      <http://data.15826.org/rdl/RDS2223141> .
<http://www.p1234.xyz-corp.com/9c88e964-f7ac-4056-ac16-c4dc68b80212> <http://data.15826.org/meta/valEffectiveDate>            "2019-10-03T15:38:00+00:00"^^<http://www.w3.org/2001/XMLSchema#dateTime> .


Once such a mapping has been defined for an application and coded in an adapter for that application, it will keep uploading templates following the rules for releasing and uploading as defined by the custodian of that application.
Read further about the concept of that adapter here.