<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Generic Ontology Design Patterns at Work</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Bernd KRIEG-BRÜCKNER</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Till MOSSAKOWSKI</string-name>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Fabian NEUHAUS</string-name>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Collaborative Research Center EASE, Universität Bremen, Germany, and German Research Center for Artificial Intelligence (DFKI)</institution>
          ,
          <addr-line>Bremen</addr-line>
          ,
          <country country="DE">Germany</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>Institute for Intelligent Cooperating Systems, Faculty of Computer Science, Otto-von-Guericke-Universität Magdeburg</institution>
          ,
          <country country="DE">Germany</country>
        </aff>
      </contrib-group>
      <abstract>
        <p>Generic Ontology Design Patterns, GODPs, are defined in GENERIC DOL, an extension of the Distributed Ontology, Model and Specification Language, and implemented using the Heterogeneous Tool Set. Parameters such as classes, properties, individuals, or whole ontologies may be instantiated with arguments in a host ontology. The potential of GENERIC DOL is illustrated with GODPs for an example from the literature, namely Role. We will also discuss how larger GODPs may be composed by instantiating smaller GODPs.</p>
      </abstract>
      <kwd-group>
        <kwd />
        <kwd>ontology design patterns</kwd>
        <kwd>generic ontologies</kwd>
        <kwd>generic DOL</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>In ontology engineering we may distinguish (at least) three kinds of stakeholders:
ontology experts, domain experts and end-users. For each, the kind and level of expertise
is quite different: End-users should not be required to have ontology expertise and may
have little domain knowledge; domain experts often have little ontology expertise;
ontology experts have little specialised domain expertise.</p>
      <p>Since many ontology development projects are small and, frequently, not well
funded, many of them do not involve a dedicated ontology expert at all or get only very
limited input from an ontology expert during the design phase of the ontology. Thus, the
majority of the development of an ontology is typically entrusted to domain experts. This
may lead to poor design choices and avoidable errors. Furthermore, because of their lack
of experience, domain experts may not be able to identify opportunities to reuse existing
best practices and ontologies.</p>
      <p>
        Ontology Design Patterns (ODPs) have been proposed for some time as
methodology for ontology development, see the early work by [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ], the compilation in [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ], and the
review of the state of the art in [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ]. In theory, ODPs provide a solution for the lack of
ontology experts: ODPs enable domain ontologists to reuse existing best practices and
design decisions and, thus, benefit from the experience of ontology experts who
developed the ODPs and lead to a considerable increase in quality of ontologies. However, in
practice the adaptation of ODPs as tools for ontology engineers has been slow. In our
opinion this is caused by the fact that currently the utilisation of ODPs is cumbersome
for ontology developers.
      </p>
      <p>
        Let us assume an ontology developer intends to reuse a given ODP P for the
representation of some domain D during the development of an ontology O; then there are
basically two options. Following a reuse-by-import stategy, she may import P into O,
include the relevant terms for D and link these terms via subclass and subproperty
relationships to P [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ]. However, this approach clutters the resulting ontology O, because
O includes not just terms about D, but all of the generic terms of P. Moreover, an ODP
often does not fit into the context of a given ontology completely, but needs to be adapted
and some axioms need to be removed. Importation does not provide a means to change
P, either one imports it completely into O or not. Alternatively, the ontology developer
may follow a clone-and-modify approach, i.e. include an axiomatisation of the terms
about D that mirrors the axiomatisations of P structurally, and modify it locally. This
approach allows more flexibility for adaptions. For example, the XD plugin of the NeOn
toolkit [
        <xref ref-type="bibr" rid="ref23">23</xref>
        ] provides a GUI for following such an approach.1 However, manual redesign
is error-prone and time-intensive, and the goal of shielding the domain ontologist from
the complex design decisions during ontology development is not achieved. Moreover,
changes in the original pattern P will not be propagated to O, such that P and O exhibit
the typical problems known from code duplication.
      </p>
      <p>In this paper we propose an approach that follows the reuse-by-import approach,
but make it more flexible to gain some advantages of the clone-and-modify approach.
To this end, we use Generic Ontology Design Patterns, GODPs, as a methodology for
representing and instantiating ODPs in a way that is adaptable, and allows domain
experts (and other users) to safely use ODPs without cluttering their ontologies. The main
ideas behind GODPs (Sect. 2) are the following: ODPs are expressed in a dedicated
formal, parametrised pattern language that allows (a) the definition of ODPs, (b) specify
instantiations of ODPs, (c) extend, modify, and combine ODPs to larger ODPs, and (d)
describe the relationships between ODPs. GODPs embody dedicated development
operations. They are defined in an extension of the Distributed Ontology, Model and
Specification Language, DOL, and implemented using the Heterogeneous Tool Set, HETS
(Sect. 2).</p>
      <p>GODPs are patterns in the sense that they contain typed variables. The definition
of a GODP involves the specification of parameters that need to be provided for the
instantiation of a GODP. Possible parameters include symbols, lists of symbols, but also
whole ontologies. The latter enable to express powerful semantic constraints using
corresponding axioms; such requirements act like preconditions for instantiations,
guaranteeing more consistency and safety.</p>
      <p>In this paper we will introduce GODPs by first discussing a toy example in Sect. 2
and afterwards an in-depth discussion of the Role ODP from the literature in Sect. 3. As
we will show, there is a straight forward way to embed a ODP like Role in a GODP.
In comparison to the ‘classical’ ODP the corresponding GODP offers the benefit that it
is easier to reuse. Further, GODPs enable the nested use of ODPs, which reduces code
duplication. Since GODPS are written in an extension of DOL, GDOP developers may</p>
      <sec id="sec-1-1">
        <title>1Of course, it also allows reuse. Both approaches can be useful, see [20].</title>
        <p>utilise the other features of DOL, e.g., to explicitly state logical properties of GODPs,
represent competency questions, and definitorial extensions. This is significant since it
enables quality control on the level of the GODPs as well as their instantiations.</p>
        <p>
          Thus, GODPs provide one tool to support the strategy of ontology reuse by
modularisation, which has been proposed by Katsumi and Grüninger [
          <xref ref-type="bibr" rid="ref11 ref12 ref7">7,12,11</xref>
          ]. GODPs shares
many objectives with Parameterised OTTR Templates with macro expansion by [
          <xref ref-type="bibr" rid="ref21">21</xref>
          ].
The differences in the approaches will be analysed in Sect. 4.
        </p>
        <p>
          The general framework that we use, an extension of DOL, has been developed
already in [
          <xref ref-type="bibr" rid="ref13 ref4">13,4</xref>
          ]. The main contribution of the present paper is the application of this
general framework for a specific pattern that has been discussed in the ODP community [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ].
Furthermore, we discuss two different strategies for designing and instantiating GODPs:
the subsumption and the parametrisation strategy.
        </p>
      </sec>
    </sec>
    <sec id="sec-2">
      <title>2. Generic Ontology Design Patterns in GENERIC DOL</title>
      <sec id="sec-2-1">
        <title>The Distributed Ontology, Model and Specification Language, DOL, an OMG standard</title>
        <p>
          [
          <xref ref-type="bibr" rid="ref15 ref16 ref19">19,16,15</xref>
          ], allows the structured definition of ontologies, using import, union, renaming,
module extraction, and many more. Thus, DOL is not “yet another ontology language”,
but a meta-language, which allows to define and manipulate ontologies and networks of
ontologies. DOL can be used on top of a variety of languages, in particular OWL 2.
        </p>
        <p>The left column in Fig. 1 contains a small DOL file. After a logic is declared,2 two
different ontologies are specified, namely Driving and DrivingExtended. Note that the
expressions in the ontology declaration are not in DOL, but in some ontology language,
in this case in OWL Manchester Syntax. (Other ontology languages are available, e.g.
FOL-based syntaxes.) DrivingExtended is specified as extension of Driving, which
contains an additional domain axiom. The phrase A then B in DOL indicates that all
definitions in A are visible in B, where A and B are ontologies in OWL (or some other ontology
language) or instantiations of GODPs. The semantics of and joining two instantiations
is union of the two ontologies (i.e. of the corresponding signatures and axioms), which
semantically leads to an intersection of their model classes.</p>
        <p>
          We developed GENERIC DOL [
          <xref ref-type="bibr" rid="ref13 ref4">13,4</xref>
          ], which extends DOL by a parameterisation
mechanism for ontologies. Generics in GENERIC DOL borrow their semantics from
CASL’s generic specification mechanism [
          <xref ref-type="bibr" rid="ref1 ref18 ref2">1,18,2</xref>
          ]. Generics, first introduced in ADA
[
          <xref ref-type="bibr" rid="ref10">10</xref>
          ], are not just macros. Their most important aspect is that all parameters are fully
typed, and argument types are checked against parameter types.
        </p>
        <p>The syntax for OWL in GENERIC DOL is presently Manchester Syntax, extended
by parameterised names. For example, SimpleRelationGODP in Fig. 1 is a very basic
pattern that is defined to utilise three symbols as parameters, namely p (of type object
property), D and R (both of type class); their declarations are separated by semicolon
“;”. The body of the ontology specification (on the right of the “=” symbol) contains an
ontology, where p, D and R occur.3 The GODP SimpleRelationGODP may be
instantiated by providing suitable arguments. In the definition of the ontology
DrivingPatternIn</p>
        <sec id="sec-2-1-1">
          <title>2In the following we will omit logic declarations such as logic OWL.</title>
          <p>3Strictly speaking, the body of SimpleRelationGODP is not a legal OWL ontology, since the symbols D
and R are not declared. However, they are introduced via the parameter ontologies.
1 logic OWL</p>
          <p>ontology Driving =
3 Class: Vehicle</p>
          <p>ObjectProperty: drives
5 Range: Vehicle
7 ontology DrivingExtended =</p>
          <p>Driving
9 then</p>
          <p>Class: Person
11 ObjectProperty: drives</p>
          <p>Domain: Person</p>
          <p>pattern SimpleRelationGODP
2 [ObjectProperty: p;</p>
          <p>Class: D; Class: R] =
4 ObjectProperty: p</p>
          <p>Domain: D Range: R
ontology DrivingPatternInstance =
2 SimpleRelationGODP</p>
          <p>[drives; Person; Vehicle]
1 Ontology: &lt;DrivingPatternInstance_Exp&gt;</p>
          <p>Class: Person
3 Class: Vehicle</p>
          <p>ObjectProperty: drives
5 Domain: Person Range: Vehicle
stance, the GODP SimpleRelationGODP is instantiated with drives, Person, and Vehicle
as arguments.</p>
          <p>
            The Heterogeneous Tool Set, HETS [
            <xref ref-type="bibr" rid="ref17">17</xref>
            ], is the implementation basis for DOL and
GENERIC DOL. HETS is able to compute ontologies that are specified in GENERIC DOL
with structuring operations like then, and, and generics. For this purpose HETS interprets
DOL terms and expands the instantiation of generics. This process is called flattening
of an ontology; the result is a proper OWL ontology. The flattening of the ontologies
DrivingExtended and DrivingPatternInstance results in the same ontology; it is shown
(in pure Manchester syntax) as DrivingPatternInstance_Exp at the end of Fig. 1.
          </p>
          <p>
            Parameters in GENERIC DOL are technically ontologies. However, single-symbol
parameters are recognised as such; in effect, parameter kinds for single-symbol
parameters in OWL are Class, Individual, ObjectProperty, etc. (see [
            <xref ref-type="bibr" rid="ref4">4</xref>
            ]). In general, a parameter
may be a complex ontology, which contains axioms that specify specific abstract
properties. An argument ontology must conform to such a parameter ontology, i.e. the required
properties must be satisfied. HETS will take care of generating an appropriate proof
obligation, if this cannot be deduced automatically. This concept makes GENERIC DOL, and
GODPs, extremely powerful to capture semantic preconditions for instantiations (see
examples in [
            <xref ref-type="bibr" rid="ref13 ref4">13,4</xref>
            ]).
          </p>
          <p>Since ontologies DrivingExtended, DrivingPatternInstance and
DrivingPatternInstance_Exp are just different representations of the same axioms (namely, declaration
of drives, its range, and its domain), what is the benefit of using GENERIC DOL? After
all, one can just write the OWL ontology DrivingPatternInstance_Exp directly without
the additional complexity. Following the reuse-by-import approach, one benefit of both
structuring mechanisms and GODPs is an increased modularity, which enables
reusability and avoids code duplication. For example, by dividing the axioms into two modules,
it is possible to reuse the axioms in Driving independently from the additional axioms
in DrivingExtended. Similarly, it is possible to instantiate SimpleRelationGODP with
different parameters to declare a different object property, its domain and range. If at a
latter time one needs to change the axioms of Driving or SimpleRelationGODP, these
changes are propagated to all ontologies that are based on them. An additional benefit
of a GODP is the fact that it hides the internal complexity of its axiomatisation. For the
instantiation of a pattern, the user does not need to understand the internal structure of
the GODP, he just needs to provide the appropriate parameters.</p>
          <p>These benefits are minuscule in the case of a simple ontology like
DrivingPatternInstance_Exp in Fig. 1. To illustrate the power of structuring mechanisms and GODPs in
GENERIC DOL, we will discuss an ontology design pattern from the literature below,
namely the Role Pattern, see Sect. 3.</p>
        </sec>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>3. Role Pattern</title>
      <sec id="sec-3-1">
        <title>3.1. The Original Ontology Design Pattern for Role</title>
        <p>
          In [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ], the ontology design pattern for Role is introduced, see Fig. 2 for an overview and
Fig. 3 for its axiomatisation (which we have converted to OWL 2 Manchester syntax).
To summarise, in [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ] a role is an entity that has some temporal extent; it is provided
by at most one entity and it is performed by at most one entity; and a provider and/or a
performer do exist.4
        </p>
        <p>
          In [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ] ODPs are instantiated by subsumption. For example, for an instantiation of
Role for Agent the axioms in Figure 4 are added to the axioms in Figure 3 (modulo
translation into Manchester Syntax). The additional axioms in Figure 4 introduce Agent
4For brevity, we have omitted two range declarations that are redundant because the correponding inverse
roles have domain declarations.
as class and AgentRole as a subclass of Role that is performed by agents. Lastly, it is
asserted roles that are performed by agents are agent roles.
1 Class: Agent
        </p>
        <p>Class: AgentRole SubClassOf: Role, rolePerformedBy only Agent
3 Class: RolePerformedBySomeAgent</p>
        <p>EquivalentTo: rolePerformedBy some Agent
5 SubClassOf: AgentRole</p>
        <p>
          Note that Agent may be considered as a new ODP, as done in [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ]. However, it is an
instantiation of the Role pattern in the sense that Figure 4 serves as illustration how Role
is to be instantiated not just for Agent, but also in other circumstances. For example, if we
would want to instantiate Role for Patient (or some other thematic role), we presumably
intend to use similar axioms. Thus, from our perspective the ODP Role does not just
consist of the axioms in Figure 3, but also includes the instructions on how to instantiate
it in a given context. This instruction is given here by the Agent example.
        </p>
        <p>Illustrating how an ODP is supposed to be instantiated by providing an example is
useful, but the technique has some signifiant drawbacks. Firstly, this methodology
requires the user to understand the ODP in detail. For example, without familiarity of Role,
the necessity for adding the last two axioms in Figure 4 is not apparent. Secondly, the
example may not cover important aspects. For example, in the case of Role the example
does not cover, how one is supposed to instantiate the ODP for roles that depend on
institutions. Hence without detailed understanding of Role, a user will not be able to use Role
in order to, for example, represent that Bernd is a professor at the University of Bremen.
Given that there are no explicit rules on how to do so, different users may use different
approaches to represent institutional roles as instantiations of Role. Thus, if our goal is to
enable a team of ontology developers with a moderate level of ontology expertise to use
ODPs in a way that is consistent across a large ontology, we need a better methodology
than illustration by example.</p>
      </sec>
      <sec id="sec-3-2">
        <title>3.2. Generic Ontology Design Pattern for Role via Subsumption</title>
        <p>
          GODPs uses GENERIC DOL in order to explicitly encode how a pattern is supposed to
be instantiated. Within the reuse-by-import approach, there are two different strategies
for the instantiation of a pattern, namely subsumption and parametrisation.5 Since [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ]
uses a subsumption strategy, we consider it first. RoleGODPSubsumption in Figure 5
provides an axiomatisation that follows faithfully the Agent example in Figure 4.
However, instead of AgentRole and Agent, the GODP uses two parameters, namely RoleKind
and Performer. As we discussed in Sect. 2, a GODP may be instantiated by providing
appropriate arguments. In ontology ThematicRoles the GODP RoleGODPSubsumption
is instantiated for three different thematic roles. Its definition of Agent and AgentRole
is equivalent to Agent as defined in Figure 4. As this example illustrates, one benefit
of defining GODPs in GENERIC DOL is the convenience of being able to instantiate a
5In programming language contexts, these are called subtype polymorphism and parametric polymorphism,
resp.
        </p>
        <p>GODP without needing to repeatedly write axioms as in Figure 4. Indeed one is able to
instantiate a GODP without considering the details of its axiomatisation. Furthermore,
it is guaranteed that a GODP is always instantiated in the same way and no axioms are
forgotten.
1 pattern RoleGODPSubsumption [Class: RoleKind; Class: Performer] =</p>
        <p>Role_Original then
3 Class: RoleKind SubClassOf: Role, rolePerformedBy only Performer</p>
        <p>Class: RolePerformedBySome[Performer] SubClassOf: RoleKind
5 EquivalentTo: rolePerformedBy some Performer
7 ontology ThematicRoles =</p>
        <p>RoleGODPSubsumption[AgentRole;Agent]
9 and RoleGODPSubsumption[PatientRole;Patient]
and RoleGODPSubsumption[InstrumentRole;Instrument]</p>
        <p>Figure 5 illustrates an important feature of GENERIC DOL, namely parametrised
names like RolePerformedBySome[Performer]. Brackets “[” and “]” are used around
constituent names. Such a bracketed construct in a name appears at its end, and may
contain several constituents, separated by comma “,” As a result of substituting
parameters by arguments in the expansion of an instantiation, the constituent names are
substituted by the corresponding argument names, e.g. RolePerformedBySome[Agent], where
Agent is the respective Performer. At the end of this flattening process, parameterised
names can be stratified: all occurrences of “[” or “,” are turned into “_”, and
(trailing) occurrences of “]” are dropped. Thus, the stratified version of ThematicRoles
contains three different classes, namely RolePerformedBySome_Agent,
RolePerformedBySome_Patient, and RolePerformedBySome_Instrument.</p>
        <p>If we had substituted the parametrised name RolePerformedBySome[Performer]
by a ‘normal’ class name, e.g., RolePerformedBySomePerformer, then ThematicRoles
would only contain that class. In this case it would follow that RolePerformedBy some
Agent is equivalent with rolePerformedBy some Patient. Hence, provided the other
axioms, Agent(a) and performsRole(a; r) would entail that Patient(a)6 – which is clearly
not intended. This example illustrates how the use of parametrised names enables the use
of several separate and different instantiations of one GODP within a larger ontology.</p>
        <p>
          Parametrised names are a seemingly innocuous feature, but it considerably reduces
parameter lists and simplifies instantiations and re-use, since every instantiation
automatically generates a new set of (stratified) names, cf. [
          <xref ref-type="bibr" rid="ref13 ref4">13,4</xref>
          ].
        </p>
      </sec>
      <sec id="sec-3-3">
        <title>3.3. Generic Ontology Design Pattern for Role via Parametrisation</title>
        <p>As we have seen, instantiation of ODPs via subsumption follows the following strategy:
one imports the pattern ontology and extends it by adding subclass axioms. As a result
the pattern ontology is included in the final result, and all instantiations of the pattern are
6If we additionally assume that every agent and every patient performs some agent role or patient role,
respectively, then the axioms would even entail that classes Agent and Patient are equivalent.
linked within the subsumption hierarchy. For example, in the ontology ThematicRoles
in Figure 5 the classes AgentRole, PatientRole, and InstrumentRole would all be
subclasses of Role. In this particular case this might be desirable, but this is not always the
case.</p>
        <p>
          For example, the Role ODP as axiomatised in [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ] (see Figure 3) includes a
recurrent pattern itself. The axioms for providesRole and performsRole are structurally
identical: they are partial functions with inverses and their range is restricted to some class.
Thus, we may want to identify this pattern as its own GODP, let us call it
ScopedPartialFunctionWithInverse7. If we would instantiate this GODP with help of the subsumption
strategy, the resulting ontology would include an object property
ScopedPartialFunctionWithInverse and axioms that establish providesRole and performsRole as
subproperties of it. While these axioms are not false, it seems rather undesirable – at least to the
authors – to be forced to include these kind of axioms into ones ontology. This is because
it clutters the ontology with symbols and axioms that are just technically motivated and
are not specific to its domain. We will return to this example below, but for now we just
conclude that under some circumstances the subsumption strategy is not ideal, because
it requires the importation of the ODP into the final product.
        </p>
        <p>The wholesale importation of the ODP is even more problematic, if the ODP
contains some parts that are regarded as optional and are not necessarily useful for every
user of the ODP.</p>
        <p>pattern RoleGODPParametrisation
2 [Class: Role; Class: Performer; ? Class: Provider] =</p>
        <p>Class: Role
4 SubClassOf: roleProvidedBy[Provider] max 1 Provider,</p>
        <p>rolePerformedBy[Performer] max 1 Performer,
6 hasTemporalExtent some TemporalExtent,</p>
        <p>hasTemporalExtent only TemporalExtent
8 SubClassOf: roleProvidedBy[Provider] some Provider</p>
        <p>or rolePerformedBy[Performer] some Performer
10 Class: TemporalExtent</p>
        <p>ObjectProperty: hasTemporalExtent
12 ObjectProperty: provides[Role] Range: Role</p>
        <p>ObjectProperty: roleProvidedBy[Provider] InverseOf: provides[Role]
14 ObjectProperty: performs[Role] Range: Role</p>
        <p>ObjectProperty: rolePerformedBy[Performer] InverseOf: performs[Role]
16 DisjointClasses: Role, TemporalExtent</p>
        <p>
          The parametrisation strategy for the instantiation of ODPs solves both of these
issues. As we have seen in Sect. 2 the application of a parametrised ontology to some
arguments leads to a new ontology, in which the parameters are substituted by their
arguments. Hence, the generic terms in the GODP are no longer occurring in the resulting
ontology. Furthermore, GENERIC DOL supports optional parameters [
          <xref ref-type="bibr" rid="ref4">4</xref>
          ], which may be
used to include optional parts of an ontology design pattern.
        </p>
        <p>7The function is scoped in the sense that it does not apply to the whole domain of quantification, but restricted
to instances of some class, e.g., Role.</p>
        <p>Class: ProfRole
2 SubClassOf: roleProvidedBy_University max 1 University,</p>
        <p>rolePerformedBy_Professor max 1 Professor,
4 hasTemporalExtent some TemporalExtent,</p>
        <p>hasTemporalExtent only TemporalExtent
6 SubClassOf: roleProvidedBy_University some University</p>
        <p>or rolePerformedBy_Professor some Professor
To see how both of these aspects of GENERIC DOL are utilised, let us return to the
Role example from Figure 2. However, let us assume that the left hand side of the
diagram (e.g., the role provider) is optional. In this case, we may define the Role GODP
as in Figure 6. This GODP has three parameters, namely Role, Performer, and Provider,
the latter is marked as optional with a question mark. Because we need to distinguish
between the performers and providers, the occurrences of owl:Thing in Role_Original
in Figure 3 have been replaced by the appropriate classes. For the sake of illustrating
different aspects of GENERIC DOL, we consider a variant of the role pattern where
different instantiations of the pattern do not use the general object properties roleProvidedBy,
rolePerformedBy and their inverses, but rather generate specific instantiations of these:
we use parametrised names in the object properties (cf. example in Sect. 3.2).</p>
        <p>If we apply RoleGODPParametrisation to the arguments ProfRole, Professor and
University, the flattened ontology does not contain either of the terms Role, Performer,
or Provider because they are substituted (see Figure 7)8. Hence, the resulting ontology is
more compact than the ontology that would have been as the result of the subsumption
strategy. Furthermore, some of the symbols of the GODP have been replaced by instance
specific variants (e.g., roleProvidedBy_University) while others are unchanged (e.g.,
hasTemporalExtent).</p>
        <p>In case an optional argument is omitted, all corresponding axioms are deleted.
Figure 8 shows the result of applying RoleGODPParametrisation to the arguments
MotherRole and Mother with no third argument; thus lines 2 and 6-7 from Figure 7 have no
counterpart in Figure 8.</p>
        <p>This example illustrates that sometimes care needs to be taken with optional
arguments. Some people would expect the axiom Class: MotherRole SubClassOf:
rolePerformedBy some Mother to be included among the axioms in Figure 8. However, since
missing optional arguments lead to the deletion of axioms, the whole axiom is removed.
Removing only the first disjunct would strengthen the axiom. Hence, it is the user’s
decision whether this strengthening is useful or not.</p>
        <sec id="sec-3-3-1">
          <title>8For the sake of brevity we include only the first axioms.</title>
          <p>pattern ScopedPartialFunctionWithInverse
2 [ObjectProperty: f; Class: D; Class: R; ObjectProperty: finv] =</p>
          <p>ObjectProperty: f Domain: D Range: R
4 ObjectProperty: finv InverseOf: f</p>
          <p>Class: D SubClassOf: f max 1 R</p>
        </sec>
      </sec>
      <sec id="sec-3-4">
        <title>3.4. Patterns Within Patterns</title>
        <p>The presentation of the Role ODP in the diagram in Fig. 2 consists of three parts, namely:
1) the relation of Role to the provider of the role, 2) the relation of Role to the performer
of the role, and 3) the relation of Role to TemporalExtent. However, this three-part
structure is lost in the axiomatisation of Role in Fig. 3.</p>
        <p>An axiomatisation that reflects the modular structure of the Role ODP has several
benefits. Firstly, subdividing the axioms into meaningful modules may improve the
readability of the ODP. Secondly, it enables the reuse of these modules as ODPs on their
own. For example, the axiomatisation of TemporalExtent seems not particular to Role.
Thus, it seems sensible to provide this part of the axiomatisation as its own
independent GODP that may be reused in other contexts. Finally, the decomposition of Role into
smaller GODPs helps to avoid code duplication. As we discussed in Sect. 3.3, the
axioms about the provider and the performer are structurally identical, since both introduce
partial functions that are restricted to some class as well their inverse. By introducing a
GODP called ScopedPartialFunctionWithInverse we avoid maintaining the axioms for
this kind of concept twice.</p>
        <p>
          Let us start with the ScopedPartialFunctionWithInverse GODP (see Figure 9). The
name of the GODP concisely expresses the involved mathematical properties: a relation
with inverse that is a partial function, not necessarily on the whole of owl:Thing, but on
a class D (and, thus, scoped). In [
          <xref ref-type="bibr" rid="ref14">14</xref>
          ] the ranges of rolePerformedBy and roleProvidedBy
are not restricted, see owl:Thing (in Figure 2). Since we intend to enable a distinction
between the providers and performers of roles, we include also a range argument R for
ScopedPartialFunctionWithInverse.
        </p>
        <p>The GODP hasTemporalExtent asserts that the instances of a given class C have
some temporal extent, and that C is disjoint with TemporalExtent. In our running
example these axioms are asserted about Role, but they hold for a wide range of classes and,
thus, may be reused in other contexts.</p>
        <p>With these two building blocks we may now restructure RoleGODPParametrisation
along the lines of the diagram in Figure 2. Figure 10 shows the resulting GODP
RoleGODPDecomposed. It uses the same parameters as RoleGODPParametrisation.
However, its body is significantly shorter, since most axioms have been replaced by
applications of GODPs. In line 3 it is asserted that the instances of the class that is provided as
argument for the parameter Role have temporal extent. Lines 4-5 assert that the variant of
rolePerformedBy that is generated depending on the argument for Performer is a scoped
partial function (and has an appropriate inverse). Lines 6-7 assert the same for
roleProvidedBy. These three applications of GODPs correspond the three parts of the diagram
in Figure 2. The last axiom is both about Provider and Performer. Hence, it is not part of
either sub-GOPD of RoleGODPDecomposed, but the axiom is added in order to connect
the different parts of the GODP.</p>
      </sec>
    </sec>
    <sec id="sec-4">
      <title>4. Conclusion, Related and Future Work</title>
      <p>In this paper we have illustrated an approach to ontology design patterns that follows the
reuse-by-import paradigm, while adding extra flexibility that usually is only available
through the clone-and-modify paradigm. We hope that the approach presented here will
contribute to the general adoption of ontology design patterns.</p>
      <p>
        As our running example illustrates, our approach is complementary to existing work
on ODPs. We started with the axiomatisation of a role pattern from the literature [
        <xref ref-type="bibr" rid="ref14">14</xref>
        ]
and showed two different strategies for representing it as generic ontology design pattern
(GODP). Compared to [
        <xref ref-type="bibr" rid="ref14">14</xref>
        ] (and other work on ODPs), the representation of a design
pattern as a GODP has the advantage that the rules for the instantiation of a GODP are
explicitly encoded within the GODP in GENERIC DOL. Thus, the instantiation of a GODP
may be automatically computed by tools like Hets, which implement the GENERIC DOL
semantics. We have shown that, through the use of GODPs, one can avoid code
duplication.
      </p>
      <p>The main difference between the aforementioned different strategies of developing
GODPs is the way they are instantiated, namely by subsumption or by parametrisation.
As we have illustrated in Sect. 3 with the help of the role pattern, either strategy works.
The subsumption strategy is more conservative in the sense that it reuses an existing
ODP without any renaming and just adds the necessary information required for
automating the instantiation. The parametrised approach is more flexible and powerful, since it
utilises the full power of GENERIC DOL a very flexible variant of reuse-by-import. Both
approaches support the nesting of patterns. Further, the strategies are compatible in the
sense that a GODP may use a mix of subsumption and parametrisation for its
instantiation.</p>
      <p>
        The OTTR approach of Parameterised Templates with macro expansion [
        <xref ref-type="bibr" rid="ref21 ref22">21,22</xref>
        ] is in
many respects very similar to the GODP approach. Apart from ontologies as parameters
(cf. [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ]), the major contribution of the GENERIC DOL approach described in this paper
is parametrisation supplemented by parameterised names. This is crucial for avoiding
unintended name clashes; moreover, reuse in distinct contexts is better supported. An
extra benefit are the other structuring operations of DOL and the smooth integration with
heterogeneous modelling. In particular, this means that GODPs can be used with other
ontology languages.
      </p>
      <p>In this paper, we have concentrated on one example from the literature. We expect
that salient and well-known patterns in the existing repositories like ontologydesignpatterns.
org, primarily conceptual or “knowledge” ODPs, will soon be cast into the GODP (or
OTTR) framework to make reuse more practical.</p>
      <p>All ontologies in this paper can be found online in the Ontohub repository http:
//www.ontohub.org/godp, available both through git and through a web interface.</p>
    </sec>
    <sec id="sec-5">
      <title>Acknowledgements</title>
      <p>We are very grateful to Serge Autexier, Mihai Codescu, Jens Pelzetter, and Martin Rink
for their suggestions and contributions.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>Egidio</given-names>
            <surname>Astesiano</surname>
          </string-name>
          , Michel Bidoit, Bernd Krieg-Brückner, Hélène Kirchner,
          <string-name>
            <surname>Peter D. Mosses</surname>
            , Don Sannella, and
            <given-names>Andrzej</given-names>
          </string-name>
          <string-name>
            <surname>Tarlecki</surname>
          </string-name>
          .
          <article-title>CASL - the Common Algebraic Specification Language</article-title>
          .
          <source>Theoretical Computer Science</source>
          ,
          <volume>286</volume>
          :
          <fpage>153</fpage>
          -
          <lpage>196</lpage>
          ,
          <year>2002</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>Michel</given-names>
            <surname>Bidoit and Peter D</surname>
          </string-name>
          . Mosses, editors.
          <source>CASL User Manual</source>
          , volume
          <volume>2900</volume>
          <source>of LNCS</source>
          . Springer, Berlin, Heidelberg,
          <year>2004</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>Eva</given-names>
            <surname>Blomqvist</surname>
          </string-name>
          , Oscar Corcho, Matthew Horridge, Rinke Hoekstra, and David Carral, editors.
          <source>8th Workshop on Ontology Design Patterns - WOP</source>
          <year>2017</year>
          ,
          <year>2017</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>Mihai</given-names>
            <surname>Codescu</surname>
          </string-name>
          , Bernd Krieg-Brückner, and
          <string-name>
            <given-names>Till</given-names>
            <surname>Mossakowski</surname>
          </string-name>
          .
          <article-title>Extensions of Generic DOL for Generic Ontology Design Patterns</article-title>
          . In Adrien Barton, Sejla Seppälä, and Daniele Porello, editors,
          <source>Proceedings of the Joint Ontology Workshops 2017 Episode V: The Styrian Autumn of Ontology, September</source>
          <volume>23</volume>
          -25, Graz, Austria,
          <source>CEUR Workshop Proceedings. CEUR-WS.org</source>
          ,
          <year>2019</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>Aldo</given-names>
            <surname>Gangemi</surname>
          </string-name>
          .
          <article-title>Ontology design patterns for semantic web content</article-title>
          . In Yolanda Gil,
          <string-name>
            <given-names>Enrico</given-names>
            <surname>Motta</surname>
          </string-name>
          , V. Richard Benjamins, and Mark A. Musen, editors,
          <source>ISWC</source>
          <year>2005</year>
          , volume
          <volume>3729</volume>
          <source>of LNCS</source>
          , pages
          <fpage>262</fpage>
          -
          <lpage>276</lpage>
          . Springer,
          <year>2005</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>Aldo</given-names>
            <surname>Gangemi</surname>
          </string-name>
          and
          <string-name>
            <given-names>Valentina</given-names>
            <surname>Presutti</surname>
          </string-name>
          .
          <article-title>Ontology design patterns</article-title>
          .
          <source>In Handbook on ontologies</source>
          , pages
          <fpage>221</fpage>
          -
          <lpage>243</lpage>
          . Springer,
          <year>2009</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <given-names>Michael</given-names>
            <surname>Gruninger</surname>
          </string-name>
          , Carmen Chui, and
          <string-name>
            <given-names>Megan</given-names>
            <surname>Katsumi</surname>
          </string-name>
          .
          <article-title>Upper Ontologies in COLORE</article-title>
          .
          <source>In Proceedings of the Joint Ontology Workshops 2017 Episode</source>
          <volume>3</volume>
          : The Tyrolean Autumn of Ontology, Bozen-Bolzano,
          <year>September 2017</year>
          .
          <article-title>CEUR-WS</article-title>
          . http://ceur-ws.
          <source>org/</source>
          Vol-2050/FOUST\_paper\_2.pdf.
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [8]
          <string-name>
            <given-names>Pascal</given-names>
            <surname>Hitzler</surname>
          </string-name>
          , Aldo Gangemi, Krzysztof Janowicz, Adila Krisnadhi, and Valentina Presutti, editors.
          <source>Ontology Engineering with Ontology Design Patterns - Foundations and Applications</source>
          , volume
          <volume>25</volume>
          of
          <article-title>Studies on the Semantic Web</article-title>
          . IOS Press,
          <year>2016</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [9]
          <string-name>
            <given-names>Pascal</given-names>
            <surname>Hitzler</surname>
          </string-name>
          , Aldo Gangemi, Krzysztof Janowicz, Adila A.
          <string-name>
            <surname>Krisnadhi</surname>
            , and
            <given-names>Valentina</given-names>
          </string-name>
          <string-name>
            <surname>Presutti</surname>
          </string-name>
          .
          <article-title>Towards a Simple but Useful Ontology Design Pattern Representation Language</article-title>
          . In Blomqvist et al. [
          <volume>3</volume>
          ].
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          [10]
          <string-name>
            <given-names>J.D.</given-names>
            <surname>Ichbiah</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Krieg-Brückner</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Wichmann</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.F.</given-names>
            <surname>Ledgard</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.-C.</given-names>
            <surname>Heliard</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.R.</given-names>
            <surname>Abrial</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.P.G.</given-names>
            <surname>Barnes</surname>
          </string-name>
          , and
          <string-name>
            <given-names>O.</given-names>
            <surname>Roubine</surname>
          </string-name>
          .
          <article-title>Preliminary Ada Reference Manual</article-title>
          .
          <source>ACM SIGPLAN Notices</source>
          ,
          <volume>14</volume>
          (
          <issue>6 Part A</issue>
          ),
          <year>1979</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          [11]
          <string-name>
            <given-names>Megan</given-names>
            <surname>Katsumi</surname>
          </string-name>
          and
          <string-name>
            <given-names>Michael</given-names>
            <surname>Grüninger</surname>
          </string-name>
          .
          <source>Choosing Ontologies for Reuse. Applied Ontology</source>
          ,
          <volume>12</volume>
          (
          <issue>3- 4</issue>
          ):
          <fpage>195</fpage>
          -
          <lpage>221</lpage>
          ,
          <year>2017</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          [12]
          <string-name>
            <given-names>Megan</given-names>
            <surname>Katsumi</surname>
          </string-name>
          and
          <string-name>
            <given-names>Michael</given-names>
            <surname>Grüninger</surname>
          </string-name>
          .
          <source>The Metatheory of Ontology Reuse. Applied Ontology</source>
          ,
          <volume>13</volume>
          (
          <issue>3</issue>
          ):
          <fpage>225</fpage>
          -
          <lpage>254</lpage>
          ,
          <year>2018</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          [13]
          <string-name>
            <given-names>Bernd</given-names>
            <surname>Krieg-Brückner</surname>
          </string-name>
          and
          <string-name>
            <given-names>Till</given-names>
            <surname>Mossakowski</surname>
          </string-name>
          .
          <article-title>Generic Ontologies and Generic Ontology Design Patterns</article-title>
          . In Blomqvist et al. [
          <volume>3</volume>
          ].
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          [14]
          <string-name>
            <given-names>Adila</given-names>
            <surname>Krisnadhi</surname>
          </string-name>
          .
          <article-title>The Role Patterns</article-title>
          .
          <source>In Hitzler et al. [8]</source>
          , pages
          <fpage>313</fpage>
          -
          <lpage>319</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          [15]
          <string-name>
            <surname>Till</surname>
            <given-names>Mossakowski</given-names>
          </string-name>
          , Mihai Codescu, Fabian Neuhaus, and
          <string-name>
            <given-names>Oliver</given-names>
            <surname>Kutz</surname>
          </string-name>
          .
          <article-title>The Distributed Ontology, Modeling and Specification Language - DOL. In A. Koslow and A</article-title>
          . Buchsbaum, editors,
          <source>The Road to Universal Logic</source>
          , volume I, pages
          <fpage>489</fpage>
          -
          <lpage>520</lpage>
          . Birkhäuser,
          <year>2015</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>
          [16]
          <string-name>
            <surname>Till</surname>
            <given-names>Mossakowski</given-names>
          </string-name>
          , Oliver Kutz, Mihai Codescu, and
          <string-name>
            <given-names>Christoph</given-names>
            <surname>Lange</surname>
          </string-name>
          .
          <article-title>The Distributed Ontology, Modeling and Specification Language</article-title>
          . In C. Del
          <string-name>
            <surname>Vescovo</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          <string-name>
            <surname>Hahmann</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          <string-name>
            <surname>Pearce</surname>
          </string-name>
          , and D. Walther, editors,
          <source>WoMo</source>
          <year>2013</year>
          , volume
          <volume>1081</volume>
          <source>of CEUR-WS online proceedings</source>
          ,
          <year>2013</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          [17]
          <string-name>
            <surname>Till</surname>
            <given-names>Mossakowski</given-names>
          </string-name>
          ,
          <string-name>
            <given-names>Christian</given-names>
            <surname>Maeder</surname>
          </string-name>
          , and
          <string-name>
            <given-names>Klaus</given-names>
            <surname>Lüttich</surname>
          </string-name>
          .
          <article-title>The Heterogeneous Tool Set, Hets</article-title>
          . In Orna Grumberg and Michael Huth, editors,
          <source>TACAS</source>
          <year>2007</year>
          , volume
          <volume>4424</volume>
          <source>of LNCS</source>
          , pages
          <fpage>519</fpage>
          -
          <lpage>522</lpage>
          . Springer,
          <year>2007</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref18">
        <mixed-citation>
          [18]
          <string-name>
            <surname>Peter D. Mosses</surname>
          </string-name>
          , editor.
          <source>CASL Reference Manual</source>
          , volume
          <volume>2960</volume>
          <source>of LNCS</source>
          . Springer, Berlin, Heidelberg,
          <year>2004</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref19">
        <mixed-citation>
          [19]
          <string-name>
            <surname>Object</surname>
            <given-names>Management</given-names>
          </string-name>
          <string-name>
            <surname>Group. The Distributed</surname>
            <given-names>Ontology</given-names>
          </string-name>
          , Modeling, and
          <source>Specification Language (DOL)</source>
          ,
          <year>2016</year>
          .
          <article-title>OMG standard available at omg</article-title>
          .org/spec/DOL. See also dol-omg.org.
        </mixed-citation>
      </ref>
      <ref id="ref20">
        <mixed-citation>
          [20]
          <string-name>
            <surname>Valentina</surname>
            <given-names>Presutti</given-names>
          </string-name>
          , Eva Blomqvist, Enrico Daga, and
          <string-name>
            <given-names>Aldo</given-names>
            <surname>Gangemi</surname>
          </string-name>
          .
          <article-title>Pattern-based ontology design</article-title>
          .
          <source>In Suárez-Figueroa et al. [23]</source>
          , pages
          <fpage>35</fpage>
          -
          <lpage>64</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref21">
        <mixed-citation>
          [21]
          <string-name>
            <surname>Martin</surname>
            <given-names>G.</given-names>
          </string-name>
          <string-name>
            <surname>Skjaeveland</surname>
            , Henrik Forssell, Johan W. Klüwer, Daniel Lupp, Evgenij Thorstensen, and
            <given-names>Arild</given-names>
          </string-name>
          <string-name>
            <surname>Waaler</surname>
          </string-name>
          .
          <article-title>Pattern-Based Ontology Design and Instantiation with Reasonable Ontology Templates</article-title>
          . In Blomqvist et al. [
          <volume>3</volume>
          ].
        </mixed-citation>
      </ref>
      <ref id="ref22">
        <mixed-citation>
          [22]
          <string-name>
            <surname>Martin</surname>
            <given-names>G</given-names>
          </string-name>
          . Skjaeveland, Daniel P. Lupp, Leif Harald Karlsen, and
          <string-name>
            <given-names>Henrik</given-names>
            <surname>Forssell</surname>
          </string-name>
          .
          <article-title>Practical Ontology Pattern Instantiation, Discovery, and Maintenance with Reasonable Ontology Templates</article-title>
          . In Denny Vrandecic et al., editors,
          <source>ISWC</source>
          <year>2018</year>
          , volume
          <volume>11136</volume>
          of Lecture Notes in Computer Science, pages
          <fpage>477</fpage>
          -
          <lpage>494</lpage>
          . Springer,
          <year>2018</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref23">
        <mixed-citation>
          [23]
          <string-name>
            <given-names>Mari</given-names>
            <surname>Carmen</surname>
          </string-name>
          Suárez-Figueroa, Asunción Gómez-Pérez,
          <string-name>
            <given-names>Enrico</given-names>
            <surname>Motta</surname>
          </string-name>
          , and Aldo Gangemi, editors.
          <source>Ontology Engineering in a Networked World</source>
          . Springer,
          <year>2012</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>