<!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>
      <journal-title-group>
        <journal-title>DL</journal-title>
      </journal-title-group>
    </journal-meta>
    <article-meta>
      <title-group>
        <article-title>Rewriting Ontology-Mediated Navigational Queries into Cypher</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Nikola Dragovic</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Cem Okulmus</string-name>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Magdalena Ortiz</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>TU Wien</institution>
          ,
          <country country="AT">Austria</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>Umeå University</institution>
          ,
          <country country="SE">Sweden</country>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2023</year>
      </pub-date>
      <volume>36</volume>
      <fpage>2</fpage>
      <lpage>4</lpage>
      <abstract>
        <p>The ontology-based data access (OBDA) paradigm has successfully grown over the last decade as a powerful means to access data from possibly diverse and incomplete sources, using a domain ontology as a mediator. The ability to query generic graph-structured data is often highlighted as an advantage of OBDA, but in practice, existing solutions do not allow to access data in popular graph database management systems (DBMS) (e.g., Neo4j) that adopt the so-called 'property graph' data model and support dedicated query languages such as Cypher. Towards overcoming this major limitation, we propose a technique for ontology-mediated querying (OMQ) of property graphs. We tailor a suitable query language that supports path navigation in a form that can be naturally expressed in Cypher and other important graph query languages. It keeps the data complexity of query evaluation tractable even under trail semantics and is suficient for our motivating use case in the autonomous driving domain. We address the semantic gap between the traditional path semantics adopted by most works on graph databases, and the trail semantics used in Cypher, and identify cases where both semantics coincide. To our knowledge, OMQs with trail semantics had not been addressed before. We develop a rewriting algorithm for queries mediated by DL-Lite ontologies that enables query answering using plain Cypher. The experimental evaluation of our proof-of-concept prototype on a sample set of use case queries reveals that the approach is promising, and can be a stepping stone to making OBDA applicable to data stored in graph DBMS.</p>
      </abstract>
      <kwd-group>
        <kwd>eol&gt;Ontology-based data access</kwd>
        <kwd>Graph databases</kwd>
        <kwd>Property graphs</kwd>
        <kwd>Query rewriting</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>
        The ontology-based data access (OBDA) paradigm, also known as virtual knowledge graphs
(VKGs), has steadily grown over the last decade to establish itself as a powerful way to access
data from possibly diverse and incomplete sources. It has been successfully exploited in various
application domains [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ], and state-of-the-art systems such as Ontop [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ] continue to be developed
and improved. In OBDA, a domain ontology provides a high-level vocabulary for formulating
queries, and captures domain knowledge that can be used to infer implicit answers from
incomplete data. The central problem in OBDA is answering ontology-mediated queries (OMQs),
that is, computing the answers to a given query not just from the plain data, but taking into
account also the facts that can be inferred using the ontology.
      </p>
      <p>
        The ability to integrate heterogeneous sources and query generic graph data is often
highlighted as an advantage of the OBDA paradigm, and while it can be successfully deployed to
query RDF graphs, no solutions so far allow directly querying data stored in popular graph
DBMS (GDBMS) that adopt the so-called property graph data model. This is a major limitation
since such graph databases have gained huge popularity this century in scores of domains
and they are widely deployed in practice. GDBMS support dedicated query languages for
graph-structured data. For example, Neo4j is one of the most popular GDBMS nowadays, and
its query language is Cypher [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. There are dozens of GDBMS in the market, some of them
supporting query languages related to Cypher. The standardisation of a query language for
graphs called GQL, intended to serve as the basis and reference point for all query languages
for GDBMS, is an ongoing project at the International Organisation for Standardisation (ISO),
and the publication of the standard is expected soon [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ]. Cypher, as the most widely adopted
language for GDBMS, is included and fully supported by GQL and is likely to remain a dominant
dialect of GQL for many years.
      </p>
      <p>
        The fundamental feature of all query languages for GDBMS is the presence of navigational
features for traversing paths flexibly [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ], which allows for expressing, for example, reachability
queries. This is not present in the query languages supported in current OBDA systems, which
commonly target relational data. Even if the data is modelled as a graph, these systems cannot
navigate graph structures and their evaluation is not tuned for graph data.
      </p>
      <p>
        Typically, OBDA systems take as input a so-called conjunctive query (CQ), which is essentially
the most widely used select-project-join fragment of relational algebra; in its logical form, it is
written as a positive existential conjunction of atoms that may share join variables [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ]. The
language of choice for writing the ontology is OWL 2 QL, the profile of the Web Ontology
Language OWL standard tailored for eficient query answering [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ], and the preferred approach
for OMQ answering is query rewriting. Here a query mediated by an OWL 2 QL ontology
is transformed using the ontology axioms into a new query in a standard query language,
with no mediating ontology, that provides the same answers when evaluated over the original
data sources [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ]. Given a CQ and an OWL 2 QL ontology as an input, the rewriting produces
a union (or disjunction) of CQs, that is, a UCQ. UCQs can be naturally expressed in simple
fragments of SQL [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ] and of SPARQL [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ], the query language for RDF [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ], which enables the
evaluation of OMQs using of-the-shelf DBMS and SPARQL end-points. State-of-the-art OBDA
systems implement this standard setting, supporting ontology-mediated CQs over data stored
in relational and RDF data sources.
      </p>
      <p>
        The main goal of this paper is to provide such a rewriting approach for OMQs with OWL 2
QL ontologies, but using a graph query language that is supported by GDBMs, such as Cypher,
as both source query language, and as target for the rewriting. Navigational features have
been considered in the OMQ literature, where algorithms for rewriting navigational queries
in the presence of ontologies and tight complexity bounds for their evaluation are known
[11, 12], but the existing theory results have never made it to practice. These works consider
conjunctive 2-way regular path queries (C2RPQ), the generalisation of CQs with path navigation,
the language of choice for theoretical works on accessing graph databases. However, it is
well-known that practical graph GDBMS do not always support C2RPQs, and sometimes adopt
a diferent semantics. In particular, unlike C2RPQs, Cypher uses a trail semantics where no
edge of the graph can occur twice on a path, and imposes restrictions on the bidirectional
navigation of paths [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. This gap has hindered the application of the results for C2RPQs to
enable querying GDBMS in OBDA, and until now, only impracticable algorithms intended for
showing theoretical results had been devised [11, 12].
      </p>
      <p>The main contributions of this paper can be summarised as follows:
1. We propose a class of queries that allows for path navigation in property graphs which is
suficient for our motivating use case. Our query language is closely related to C2RPQs,
but tailored to be expressible in Cypher, to support succinct query rewritings, and to have
tractable data complexity even under trail semantics.
2. We consider both the traditional path semantics of C2RPQs and the trail semantics of
Cypher; to our knowledge, OMQs with trail semantics had not been considered until now.</p>
      <p>We show that for our query language, query answers under both semantics coincide.
3. We present a rewriting algorithm for our query language in the presence of OWL 2
QL ontologies. We provide conditions that guarantee that the queries rewritten by the
algorithm can be expressed in Cypher, and evaluated directly over GDBMS.
4. We implemented a simple prototype of the approach and evaluated it on real-world
use-case data. In particular, we considered queries designed for scenario-based safety
assessment for autonomous vehicles and evaluated them over an industrial dataset. We
obtained promising results that suggest that our work may be a stepping stone towards
practicable OBDA over GDBMS.</p>
    </sec>
    <sec id="sec-2">
      <title>2. Preliminaries</title>
      <p>In this section we recall the property graph data model. We also introduce DL-LiteR, which is
the language of OWL 2 QL defined as a description logic [13].</p>
      <p>We consider a vocabulary consisting of countably infinite and pairwise disjoint sets NI of
individual names, NC of concept names and NR of role names, NE of relationship names and K
of property keys. Moreover, we assume a fixed set of data type domains D1, . . . , D; each D
consists of a value domain  and a fixed set of binary predicates representing binary relations
over . In our examples, we typically use integers and strings as data types. For integers, we
use the usual comparison predicates ≤ , ≥ , ̸=, =, and for the strings datatype we use the binary
relations equal (1, 2), substring (1, 2), and prefix(1, 2).</p>
      <p>
        Property Graphs
Our definition of property graphs follows the one given in [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ]. A labelled multigraph is a
tuple ⟨, , src, tgt, , ⟩, where  is the set of nodes and  is the set of edges;  ̸= ∅ and
 ∩  = ∅. The functions src :  ↦→  and tgt :  ↦→  assign each edge its source and target
node, respectively. We have two total labelling functions:  :  ↦→ NR assigns to each edge a
role name, and  :  ↦→ 2NC assigns to each node a set of concept names. A property graph
 = ⟨, , src, tgt, , ,  ⟩
extends a labelled multigraph with a partial function  : ( ∪ ) × K → ⋃︀1≤ ≤   that maps
pairs (, ) with  a node or edge of  and  a property key, to a value in a datatype value
domain .
      </p>
      <p>Let  = ⟨, , src, tgt, , ,  ⟩ and ′ = ⟨ ′, ′, src′, tgt′, ′, ′,  ′⟩ be property graphs.</p>
      <sec id="sec-2-1">
        <title>A homomorphism from  to ′ is a function ℎ that maps each  ∈  to some ℎ() ∈  ′ and</title>
        <p>each  ∈  to some ℎ() ∈ ′ so that
1. for every  ∈  , () ⊆ ′(ℎ()) and if  (, ) is defined for some , then  (, ) =
 ′(ℎ(), ); and
2. for every  ∈ , () = ′(ℎ()), src() = src′(ℎ()), tgt() = tgt′(ℎ()), and if
 (, ) is defined for some , then  ′(ℎ(), ) =  (, ).</p>
      </sec>
      <sec id="sec-2-2">
        <title>We call  a subgraph of ′ if  ⊆  ′,  ⊆ ′, and the identity on  ∪  is a homomorphism from  to ′.</title>
        <sec id="sec-2-2-1">
          <title>2.1. Ontologies</title>
          <p>
            An ontology is a set of axioms that encapsulates terminological knowledge of our domain.
Here we write ontologies in the description logic called DL-LiteR [
            <xref ref-type="bibr" rid="ref8">8</xref>
            ]. We define the set of roles
N±R = NR ∪ {− |  ∈ NR}. If  = − for  ∈  ± , then − denotes . For all roles , we call role
− the inverse of , and vice-versa. Concepts in DL-LiteR take the form  or ∃, where  ∈ NC
and  ∈ N±R . We use possibly subindexed  and  to denote roles and concepts, respectively.
Axioms take one of four forms:
          </p>
          <p>1 ⊑ 2, 1 ⊑ ¬2, 1 ⊑ 2, 1 ⊑ ¬2.</p>
        </sec>
      </sec>
      <sec id="sec-2-3">
        <title>A set of axioms  is called an ontology or a TBox. In this paper datasets (called ABoxes in DL jargon) are given in the form of a property graph ⟨, , src, tgt, , ,  ⟩ where  ⊆ NI and  ⊆ NE, and both sets are finite.</title>
      </sec>
      <sec id="sec-2-4">
        <title>Paired with a TBox  , a dataset  is associated to a set of models, which intuitively are</title>
        <p>property graphs that may extend  and satisfy the axioms in  .</p>
      </sec>
      <sec id="sec-2-5">
        <title>Formally, in this paper we define an interpretation ℐ as a property graph</title>
        <p>⟨Δℐ , Δℐ, src, tgt, , ,  ⟩
where Δℐ ̸= ∅ and Δℐ ̸= ∅. We say that ℐ is a model of dataset  if it contains  as a subgraph.
Note that we are thus making the standard name assumption.</p>
      </sec>
      <sec id="sec-2-6">
        <title>The interpretation function · ℐ for concept and role names is determined by the labelling functions  and . Note that for a role name , we let ℐ ⊆ Δℐ × Δℐ , as usually done in description logic interpretations where Δℐ is not present. For each concept name  ∈ NC and each role name  ∈ NR, we define</title>
        <p>ℐ ={ ∈ Δℐ |  ∈ ()}
ℐ ={(, ) | ∃ ∈ Δℐ : src() = , tgt() = , () = }
Then the interpretation of all concepts and roles is defined as usual:
(¬)ℐ = Δℐ ∖ ℐ
(∃)ℐ = { | ∃ ∈ Δℐ : (, ) ∈ ℐ }
(− )ℐ = {(, ) | (, ) ∈ ℐ }
(¬)ℐ = (Δℐ × Δℐ ) ∖ ℐ</p>
      </sec>
      <sec id="sec-2-7">
        <title>An interpretation ℐ satisfies an axiom  ⊑  if  ℐ ⊆  ℐ , and we call ℐ a model of a TBox  if ℐ satisfies every axiom in  . A dataset  is consistent with a TBox  if a model of  and  exists.</title>
        <p>Canonical model When TBoxes are written in DL-LiteR, every consistent dataset can be
extended into a model in a canonical way using a technique called the chase; this also applies in
our setting. As usual, we start form  and add nodes, edges and labels to satisfy all the positive
axioms of  , i.e., those that do not have ¬ on the right-hand-side.</p>
      </sec>
      <sec id="sec-2-8">
        <title>The canonical model ℐ , of a DL-LiteR TBox  and a dataset  is built inductively as follows.</title>
        <p>First we set ℐ0 = . Then the following rules are exhaustively applied:
• If  ⊑  ∈  with  ∈ NC,  ∈ ℐ and  ̸∈ ℐ , then ℐ+1 is obtained from ℐ by
setting () := () ∪ {}.
• If  ⊑ ∃ ∈  ,  ∈ ℐ and  ̸∈ (∃)ℐ , then ℐ+1 is obtained from ℐ by adding a
fresh  to Δℐ and a fresh  to Δℐ . In case  ∈ NR, we set src() := , tgt() :=  and
() =  for ℐ+1. Otherwise, we set src() := , tgt() :=  and () = − .
• If 1 ⊑  ∈  with  ∈ N±R , (, ) ∈ ℐ and (, ) ̸∈ ℐ , then ℐ+1 is obtained from ℐ
1
by adding a fresh element  to Δℐ . In case  ∈ NR, we set src() := , tgt() :=  and
() =  for ℐ+1. Otherwise, we set src() := , tgt() :=  and () = − .
We assume fairness in the application of the rules i.e., every applicable rule is eventually applied.</p>
      </sec>
      <sec id="sec-2-9">
        <title>The canonical model ℐ , is defined as the limit of the sequence ℐ0, ℐ1, . . . , ℐ. Note that in</title>
        <p>general, the canonical model can be infinite. The following result is proved in the standard way.
Lemma 1. Let  be a DL-LiteR TBox and  a dataset consistent with  . Then ℐ , is a model of
 and  , and every model of  and  can be homomorphically embedded into ℐ ,.</p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>3. Navigational Queries for Property Graphs</title>
      <p>We now introduce our query language for property graphs, which allows for path navigation in
the style of C2RPQs. For a detailed definition C2RPQs, we refer to [ 12]. C2RPQs are conjunctions
of unary atoms of the form () and binary atoms of the form  (, ), where  is a concept
name and  a regular expression over the alphabet of (possibly inverse) roles. Cypher also
supports regular paths, but when we restrict it to the fragment that can be written in logic as a
conjunction of atoms analogous to C2RPQs, we find some important diferences. In particular,
Cypher imposes directionality constraints when matching paths that efectively mean that a
regular path that uses the Kleene star can contain either only role names, or only inverse role
names. For example, a query such as () ← [1 ∪ 2− ]* (, ) can not be syntactically expressed
in Cypher. Also, Cypher does not allow more than one ‘step’ in the scope of the Kleene star,
thus a query such as () ← [1 · 2]* (, ) can not be syntactically expressed in Cypher.</p>
      <p>Our query language restricts regular paths so that they are naturally expressible in Cypher.
We also add some useful features to CQs that are typically not present in C2RPQs, but which
are easy to support in Cypher. We extend unary atoms to take a disjunction of concepts rather
than a single concept. As we will see below, this allows for rewritings that are exponentially
more succinct in some cases. Additionally, our query language allows querying property
values by means of test atoms. Recall that each datatype has a fixed set of binary predicates
representing binary relations over the data domain. For example, the integers may come with
the usual comparison predicates ≤ , ≥ , ̸=, =, and the strings datatype with binary relations
equal, substring, prefix, etc. Property keys and data predicates are used in Boolean tests:
x_position ≥ 450 ∨ (x_position ≥ 300 ∧ movingDirection = ‘right′).
where we check that an object has a horizontal position of at least 450, or the position is at least
300 and the object is moving in the direction right.</p>
      <p>Definition 1 (Navigational property-graph queries (NPGQs)). Let  be a value in a datatype
domain D, let ⊙ be a binary predicate in D, and let  ∈ K. The expression  ⊙  is called an
atomic data test, and a Boolean combination of atomic data tests (built using ∧, ∨, and ¬) is called
a data test. We define a navigational property-graph query (NPGQ) as an expression of the form
(⃗) = ∃.(⃗, ⃗) where  is a conjunction of atoms of the forms:
 ()
 (, )
(1 ∪ · · · ∪
)()
(1 ∪ · · · ∪
)(, )
(1 ∪ · · · ∪
)* (, )
where each  is a concept name in NC, each  a role name in N±R ,  is a data test, and ,  ∈
(⃗ ∪ ⃗ ∪ NI). The atoms of the first two forms are called test atoms, and the remaining atoms
are relational atoms. We call an atom of the last form a star atom, and say that it is pure if
it contains only role names, or only inverse role names, that is, if either {1, . . . , } ⊆  or
{1− , . . . , − } ⊆ . An NPGQ  is called pure if all its star atoms are pure.</p>
      <sec id="sec-3-1">
        <title>3.1. Path and trail semantics</title>
        <p>To define the semantics of NPGQs, we first define paths and trails.</p>
        <p>Definition 2. Consider a property graph  = ⟨, , src, tgt, , ,  ⟩. We let ± =  ∪
{− |  ∈ }, and for every  in ± , we let src(− ) = tgt(), tgt(− ) = src() and
(− ) is the inverse role of (). A path from a node  to a node  in a property graph
 is a sequence 12 . . .  of edges  ∈ ± , where src(1) = , tgt() =  and for each
1 ≤  &lt; ,tgt() = src(+1). We use  to denote the empty path, that is, the path with
 = 0 from a node  to itself. A trail from  to  is a path 12 . . .  from  to  where for
each  ̸= , we have that  ̸∈ { , − } i.e., no edge occurs more than once. For  of the form
(1 ∪ · · · ∪ )* or (1 ∪ · · · ∪ ), we use ( ) to denote the set of paths 12 . . .  such that
{1, . . . , } ⊆ { 1 ∪ · · · ∪ }, where  = (). Note that  ∈ ( ) for every  .</p>
        <p>Note that every trail is a path, but not every path is a trail. Now we can define path and trail
matches for NPGQs.</p>
        <p>Definition 3. [Path and trail matches] Consider a property graph  = ⟨, , src, tgt, , ,  ⟩.
Let  ∈  ∪ . A test  ⊙  is said to be true at  if  (, ) is defined and belongs to the same
data domain D as , and the relation denoted by ⊙ holds between  (, ) and . The truth of
data tests  is interpreted as expected, and we write  ∈ J K if  is true at  in graph ; we may
omit the graph  if it is clear from the context.</p>
        <p>Let (⃗) be a query and  a mapping from the individuals and variables occurring in  to nodes
of . We call  a path match for  in  if  contains all individuals occurring as terms in  and:
1.  () =  for each  ∈ NI;
2. for each atom (1 ∪ · · · ∪ )() in , {1, . . . , } ∩ ( ()) ̸= ∅;
3. for each atom  () in ,  () ∈ J K;
4. for each atom (1 ∪ · · · ∪ )(, ) or (1 ∪ · · · ∪ )* (, ), there exists a path  ∈ ( )
from  () to  (), where  = 1 ∪ · · · ∪  or  = (1 ∪ · · · ∪ )* , respectively; and
5. for each atom  (, ), there exists  ∈  with  ∈ J K, () =  (), () =  ().
If additionally the path  in item 4 is a trail, we call  a trail match. A tuple ⃗ ⊆  is a (trail)
answer to a query (⃗) = ∃.(, ) in  if there exists a (trail) match  for ⃗ such that  (⃗) = ⃗.</p>
        <p>
          Since all trails are paths, the trail answers are a subset of the path answers. For C2RPQs and
many related languages, this containment is strict [
          <xref ref-type="bibr" rid="ref4">4</xref>
          ]. However, the regular paths in NGPQs
are restricted in such a way that every path answer is also a trail answer, and hence trail and
path answers coincide.
        </p>
        <p>Proposition 1. Let  be a property graph and  an NPGQ. The answers to  over  under trail
semantics are also path answers.</p>
        <p>Proof (sketch). We show that every path match is also a trail match. Consider an arbitrary path
match  for  in . To show that  is also a trail match, we argue that for every star atom
(1 ∪ 2 ∪ · · · ∪ )* (, ), there is a trail ′ witnessing item 4 in Definition 3, that is, ′ is a trail
from  () to  () and ′ ∈ ( ), where  = (1 ∪ 2 ∪ · · · ∪ )* . We know that such a path
 = 1 . . .  exists, as  is a path match, and if  is not a trail then we can drop any repeated
sequences in it to obtain a trail ′. Since ′ only uses edges from {1, . . . , }, it follows from
 = ( ) that ′ = ( ) also holds.</p>
        <p>Answering C2RPQs under path semantics is in NL in data complexity [14], so by Proposition 1
we have:
Proposition 2. The query answering problem for NPGQs is NL complete in data complexity, under
both path and trail semantics.</p>
        <p>This is good news, since under trail semantics C2RPQs are intractable in general [15]. We
note that Proposition 2 can also be inferred (without Proposition 1) from the trichotomy in [15].</p>
        <sec id="sec-3-1-1">
          <title>NPGQs and Cypher Cypher cannot express some NPGQs such as [1 ∪ 2− ]* (, ), but pure</title>
          <p>NPGQs inherit Cypher’s restrictions on directional navigation and they can be easily expressed.
Due to space constraints, the Cypher translation is to be found in the full version of this paper.</p>
        </sec>
      </sec>
      <sec id="sec-3-2">
        <title>3.2. Semantics of Ontology-Mediated NPGQs</title>
        <p>As is usually done for OMQs, we adopt the certain answer semantics.</p>
        <p>Definition 4 (Certain answer). Let  be a dataset,  a TBox, and (⃗) an NPGQ. A tuple ⃗ ⊆ 
is a (certain) answer to ((⃗),  ) over  if it is an answer in each model ℐ of  and  .</p>
        <p>Note that previous works on OMQs had only considered path answers, which admit a natural
certain answer semantics. We can adopt certain answers for the trail semantics thanks to
Proposition 1, but this does not extend to other navigational query languages.</p>
        <sec id="sec-3-2-1">
          <title>The certain answers coincide with the answers in the canonical model ℐ ,. This follows</title>
          <p>from Lemma 1, the preservation of path matches under homomorphisms, and Proposition 1.
Lemma 2. Let  be a dataset,  a TBox, and (⃗) an NPGQ. A tuple ⃗ ⊆  is a (certain) answer
to ((⃗),  ) over  if it is an answer in in the canonical model ℐ ,.</p>
        </sec>
      </sec>
    </sec>
    <sec id="sec-4">
      <title>4. Query Rewriting Algorithm</title>
      <p>In this section, we a present a sound and complete rewriting algorithm for NPGQs. It transforms
an NPGQ  mediated by a DL-LiteR ontology  into a plain NPGQ  that can be evaluated
over the data alone and that gives exactly the same set of answers.</p>
      <sec id="sec-4-1">
        <title>The algorithm is not very diferent to the classical PerfectRef [8]: it applies axioms of  in a</title>
        <p>right-to-left fashion to take into account every way in which a query atom could be implied.
Since NPGQs allow for unions of concepts in unary atoms, we can avoid one of the most
common causes for exponential growth of the rewritten queries in PerfectRef. For instance,
in the presence of a TBox that contains 1 ⊑ 2, 1 ⊑ 2 a query that contains the atoms
2(), 2() can be rewritten replacing them with (1 ∪ 2)(), (1 ∪ 2)(), rather than
considering all combinations of (),  ().</p>
        <p>For the treatment of the regular expressions, we exploit the fact that the query only needs
to navigate in the anonymous part of the canonical model in one direction. That is, for every
atom  (, ) in  and every match  , we can safely assume that  is a trail and no node in
the canonical model is visited more than once. This ‘unidirectionality’ of paths spares us from
needing the sophisticated techniques for treating 2-way paths that are usual for navigational
queries in the presence of ontologies (e.g., the so-called loop computation [12]). Instead, we only
introduce three novel rewriting rules, which allow us to reason about the way in which the
paths witnessing star atoms may overlap, and whose application can be a prerequisite to the
application of the usual rewriting rules to the star atoms.</p>
        <p>Let  be an atom. If it is of the form (1 ∪ 2 ∪ . . . )(), we denote by concepts( ) the set
of all concept names {1, . . . , } that occur in it, and if it is of the form (1 ∪ 2 ∪ . . . )(, ),
then roles( ) ⊆  ± denote the roles occurring in it. For a union of roles  = 1 ∪ · · · ∪ ,
we define  − = 1− ∪ · · · ∪ − . We view queries as sets of atoms and, for convenience, we use
 ∈  to mean that either  ∈ , or  =  (, ) and  − (, ) ∈ . Recall that a query variable
is unbound if it occurs exactly once in the query and it is not an answer variable. As usual, we
denote unbound variables by ‘_’, but each occurrence is a fresh variable, and must be denoted
by a unique name if it becomes bound.</p>
      </sec>
      <sec id="sec-4-2">
        <title>The algorithm ensures that atoms are closed under the concept and role name inclusions of  .</title>
        <p>For a TBox  , we call  ⊆  ±  -saturated if 1 ∈  whenever 2 ∈  and either 1 ⊑ 2 ∈ 
or 1− ⊑ 2− ∈  . The  -saturation of , sat  (), is the smallest  -saturated set containing .
Similarly, a set  of concept names  -saturated if  ∈  and ′ ⊑  ∈  imply ′ ∈  , and
the  -saturation of  , denoted sat  ( ), is the smallest  -saturated set containing  . We
call an atom   -saturated if concepts ( ) or roles ( ) (for unary or binary  , respectively) is
 -saturated. If it is clear from the context, we may omit  and just talk about saturated atoms.</p>
        <p>Our novel query rewriting algorithm, applies exhaustively the following transformations.
Definition 5. Consider a DL-LiteR TBox  and an NPGQ . We define the following rules:
1. Saturation: saturate (,  ) denotes the result of replacing each atom in  by its  -saturation.
2. Axiom application: By apply (,  ) we denote the result of applying an axiom  to  using
the rules in Table 1. Note that this may add an unbound variable to the query.
3. Reduction: reduce(,  1,  2) is the result of applying the most general unifier of  1 and  2.
4. Concatenation: Let  1 ∈  and  2 ∈  be atoms such that roles ( 2) ⊆ roles ( 1),  1 is a star
atom, and  1,  2 share a common term. Then we obtain concatenate(,  1,  2) as follows: If  1
has terms (, ) and  2 has terms (, ), then the terms of  1 in  are replaced by (, ). This
amounts to placing the atom  2 right before  1. If  1 has terms (, ) and  2 has terms (, ),
then the terms of  1 in  are replaced by (, ). This amounts to placing the atom  2 right after  1.
5. Merging: Let  1 ∈  and  2 ∈  be atoms with roles ( 1) ∩ roles ( 2) ̸= ∅ and such that both
atoms have terms (, ) (in that order). Then merge(,  1,  2) is obtained by replacing in  both
atoms by
• [roles ( 1) ∩ roles ( 2)* ](, ) if both  1 and  2 are star atoms, and
• [roles ( 1) ∩ roles ( 2)](, ) otherwise.
6. Dropping: Let  ∈  be of the form (1 ∪ · · · ∪ )* (, _) or (1 ∪ · · · ∪ )* (_, ) and such
that  occurs in another atom in case it is an answer variable. Then drop(,  ) =  ∖  .
We use Rewrite (,  ) to describe the set of queries that are produced by applying all of the above
rules exhaustively, and accumulating all transformed new queries.</p>
        <p>Example 1. Suppose we are given a TBox  = {∃− ⊑ ∃} and also a query 1, defined as
1() ← ( ∪  ∪ )* (, ), (, ), − (, ). To illustrate the query transformations, we state
three example queries, produced via successive application of these transformations.
2() ←
3() ←
4() ←
( ∪  ∪ )* (, ), − (, ), − (, )
( ∪  ∪ )* (, ), (, ), − (, )
(, ), (, )
from apply (1, ∃− ⊑ ∃)
from concatenate(2, ( ∪  ∪ )* (, ), (, ))
from merge(3, (, ), ( ∪  ∪ )* (, ))
Note that in the creation of 3 we make use of the fact that (, ) ∈ 2, which follows from
− (, ) ∈ 2, and analogously we have that (, ) ∈ 3, which follows from − (, ) ∈ 3.</p>
        <p>Note that the rewriting focuses on the atoms without data tests. Since DL-LiteR ontologies
cannot assert property key values for existentially quantified objects, atoms with data tests can
only be matched in the canonical model to nodes and edges that exist already in the input dataset.
Hence these atoms remain untouched in the rewritten query, except for possible applications of
the reduce step, which could bind variables shared with test atoms.</p>
        <p>The rewriting algorithm we have presented is sound and complete.</p>
        <p>Theorem 1. Let  be an NPGQ,  a DL-LiteR TBox and  a property graph. Then ⃗ is a certain
answer to  over ( , ) if ⃗ is an answer to ′ in  for some ′ ∈ Rewrite(,  ).</p>
        <p>The pseudo-code of the query rewriting algorithm will be in the full version of this paper.
Termination and Complexity The query rewriting procedure terminates. In a nutshell, all
transformations make the query smaller except for the axiom application, which can introduce
fresh variables, but a bound on the latter can be shown using essentially the same arguments as
for the standard PerfectRef. The rewriting does not depend on the data and hence it only needs
constant time for any given  and . From this and Proposition 2, we get:
Theorem 2. The query answering problem for NPGQs mediated by DL-LiteR ontologies is NL
complete in data complexity, under both path and trail semantics.</p>
        <p>Evaluating OMQs in Cypher Even if the original input query is pure, the rewriting can
add (non)-inverse roles to star atoms and result in a NPGQ that is not pure. We introduce a
suficient condition for the purity to be preserved during the rewriting, which guarantees that
we can evaluate ontology-mediated NPGQs using Cypher.</p>
        <p>Definition 6 (NPGQ compliance). Let  be an NPGQ. A TBox  is -compliant if there is no star
atom whose saturation contains both role names and inverse role names. That is, for every atom of
the form * (, ′) ∈ , either sat  () ⊆ , or {− |  ∈ sat  ()} ⊆ .</p>
        <p>Proposition 3. If  is a pure NPGQ and it is  -compliant, then every ′ ∈ Rewrite(,  ) is a
pure NPGQ.</p>
      </sec>
    </sec>
    <sec id="sec-5">
      <title>5. NPGQ Rewriting in a Use Case</title>
      <p>This work was largely motivated by a use case from the automated driving industry, specifically
scenario-based safety assessment models for autonomous vehicles, where driving scenarios for
safety testing are retrieved from real-world data. There are two large open datasets used for
such purposes: the nuScenes [16] and Lyft [17] datasets. A company in the autonomous driving
industry stores both datasets in the same Neo4j graph database. The data is organized in scenes,
which contain a number of samples that are temporally ordered, and the state of objects in a
scene can change within an unknown time frame. Hence, we need to navigate the temporal
graph of a scene to answer queries about objects that change in time. The two datasets are
similar, but use diferent vocabularies. For example, one dataset labels instances with Bus, while
the other labels them either RigidBus or BendyBus. We used a DL-LiteR ontology to define a
unified vocabulary for querying. It contains, for example, axioms such as BendyBus ⊑ Bus and</p>
      <sec id="sec-5-1">
        <title>RigidBus ⊑ Bus. In collaboration with a company expert, we developed by hand a test set of</title>
        <p>ifve representative queries. All but one of them needed navigation along paths of unbounded
length, but could be easily expressed as NPGQs. The navigation used only temporal relations in
the data such as NEXT, and the compliance between queries and TBox was trivial. The queries
vary from a simple query with only one atom (Q1) to queries which contain binary atoms with
Kleene star (Q2-Q4). As an example, we provide one of the queries, Q5, here in full:
5() ← pedestrian(), OF(, ), HAS(, ), pedestrian_stationary(), NEXT(, ),</p>
        <p>NEXT* (, ), HAS(, ), pedestrian_moving()</p>
        <p>We developed a prototype implementation of our rewriting technique and tested it on a
sample dataset provided by the mentioned company, as a Neo4j database with metadata of the
nuScenes and Lyft datasets. The source code for our implementation has been made publicly
available1. The dataset consists of 91,891 nodes and 254,555 distinct relations. In order to test
the potential feasibility of our approach, we rewrote the five queries and evaluated them over
the data as Cypher queries. The results of the evaluation are seen in Table 2, on the right.</p>
        <p>We were also curious about the impact of atoms with concept unions (such as [ ∪ ]())
for handling the subclass hierarchy. We compared our rewriting, which uses this union, with a
naive version that just extends the classical PerfectRef with the additional rules for navigational
atoms (called PerfectRef* in the table). The sizes of the rewritings produced by both approaches
and their evaluation time are shown in Table 2. The very significant improvements suggest that
some features of Cypher may be useful for query rewriting even for plain CQs, and they could
be leveraged for more eficient OMQ evaluation with less optimisation efort.</p>
      </sec>
    </sec>
    <sec id="sec-6">
      <title>6. Conclusion</title>
      <p>Ontologies are useful for querying incomplete data. We have extended the ontology-mediated
querying paradigm to property graphs, using as both input query language and as target of
the rewritings a navigational query language which is expressible in Cypher. For answering
queries, we have developed a novel rewriting algorithm based on PerfectRef. Finally, we have
demonstrated the usefulness of exploiting Cypher for compact rewritings on a concrete use
case. We plan to continue working on rewriting techniques for more expressive graph query
languages, helping pave the way to enabling OBDA to support real graph databases.</p>
    </sec>
    <sec id="sec-7">
      <title>Acknowledgments</title>
      <p>This work was partially supported by the Wallenberg AI, Autonomous Systems and Software
Program (WASP) funded by the Knut and Alice Wallenberg Foundation. It was also partially
supported by the Austrian Science Fund (FWF) project P30360 and P30873.
[11] M. Bienvenu, D. Calvanese, M. Ortiz, M. Simkus, Nested regular path queries in description
logics, in: KR, AAAI Press, 2014.
[12] M. Bienvenu, M. Ortiz, M. Simkus, Regular path queries in lightweight description logics:</p>
      <p>Complexity and algorithms, J. Artif. Intell. Res. 53 (2015) 315–374.
[13] F. Baader, I. Horrocks, C. Lutz, U. Sattler, An Introduction to Description Logic, Cambridge</p>
      <p>University Press, 2017.
[14] M. P. Consens, A. O. Mendelzon, Graphlog: a visual formalism for real life recursion, in:</p>
      <p>PODS, ACM Press, 1990, pp. 404–416.
[15] W. Martens, M. Niewerth, T. Trautner, A Trichotomy for Regular Trail Queries, in: C. Paul,
M. Bläser (Eds.), 37th International Symposium on Theoretical Aspects of Computer
Science, STACS 2020, March 10-13, 2020, Montpellier, France, volume 154 of LIPIcs, Schloss
Dagstuhl - Leibniz-Zentrum für Informatik, 2020, pp. 7:1–7:16. URL: https://doi.org/10.
4230/LIPIcs.STACS.2020.7. doi:10.4230/LIPIcs.STACS.2020.7.
[16] H. Caesar, V. Bankiti, A. H. Lang, S. Vora, V. E. Liong, Q. Xu, A. Krishnan, Y. Pan,
G. Baldan, O. Beijbom, nuscenes: A multimodal dataset for autonomous driving, in:
2020 IEEE/CVF Conference on Computer Vision and Pattern Recognition, CVPR 2020,
Seattle, WA, USA, June 13-19, 2020, Computer Vision Foundation / IEEE, 2020, pp.
11618–11628. URL: https://openaccess.thecvf.com/content_CVPR_2020/html/Caesar_
nuScenes_A_Multimodal_Dataset_for_Autonomous_Driving_CVPR_2020_paper.html.
doi:10.1109/CVPR42600.2020.01164.
[17] J. Houston, G. Zuidhof, L. Bergamini, Y. Ye, L. Chen, A. Jain, S. Omari, V. Iglovikov,
P. Ondruska, One thousand and one hours: Self-driving motion prediction dataset, in:
J. Kober, F. Ramos, C. J. Tomlin (Eds.), 4th Conference on Robot Learning, CoRL 2020,
16-18 November 2020, Virtual Event / Cambridge, MA, USA, volume 155 of Proceedings of
Machine Learning Research, PMLR, 2020, pp. 409–418. URL: https://proceedings.mlr.press/
v155/houston21a.html.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>G.</given-names>
            <surname>Xiao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Calvanese</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Kontchakov</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Lembo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Poggi</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Rosati</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Zakharyaschev</surname>
          </string-name>
          ,
          <article-title>Ontology-based data access: A survey, in: IJCAI, ijcai</article-title>
          .org,
          <year>2018</year>
          , pp.
          <fpage>5511</fpage>
          -
          <lpage>5519</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>G.</given-names>
            <surname>Xiao</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Lanti</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Kontchakov</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Komla-Ebri</surname>
          </string-name>
          ,
          <string-name>
            <given-names>E. G.</given-names>
            <surname>Kalayci</surname>
          </string-name>
          ,
          <string-name>
            <given-names>L.</given-names>
            <surname>Ding</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Corman</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Cogrel</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Calvanese</surname>
          </string-name>
          ,
          <string-name>
            <surname>E. Botoeva,</surname>
          </string-name>
          <article-title>The virtual knowledge graph system ontop</article-title>
          , in: J.
          <string-name>
            <given-names>Z.</given-names>
            <surname>Pan</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V. A. M.</given-names>
            <surname>Tamma</surname>
          </string-name>
          , C. d'Amato,
          <string-name>
            <given-names>K.</given-names>
            <surname>Janowicz</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Fu</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Polleres</surname>
          </string-name>
          ,
          <string-name>
            <given-names>O.</given-names>
            <surname>Seneviratne</surname>
          </string-name>
          , L. Kagal (Eds.),
          <source>The Semantic Web - ISWC 2020 - 19th International Semantic Web Conference</source>
          , Athens, Greece, November 2-
          <issue>6</issue>
          ,
          <year>2020</year>
          , Proceedings,
          <string-name>
            <surname>Part</surname>
            <given-names>II</given-names>
          </string-name>
          , volume
          <volume>12507</volume>
          of Lecture Notes in Computer Science, Springer,
          <year>2020</year>
          , pp.
          <fpage>259</fpage>
          -
          <lpage>277</lpage>
          . URL: https://doi.org/10.1007/978-3-
          <fpage>030</fpage>
          -62466-8_
          <fpage>17</fpage>
          . doi:
          <volume>10</volume>
          .1007/978-3-
          <fpage>030</fpage>
          -62466-8\_
          <fpage>17</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>N.</given-names>
            <surname>Francis</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Green</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Guagliardo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>L.</given-names>
            <surname>Libkin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.</given-names>
            <surname>Lindaaker</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Marsault</surname>
          </string-name>
          ,
          <string-name>
            <given-names>S.</given-names>
            <surname>Plantikow</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Rydberg</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Selmer</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Taylor</surname>
          </string-name>
          , Cypher:
          <article-title>An evolving query language for property graphs</article-title>
          , in: G.
          <string-name>
            <surname>Das</surname>
          </string-name>
          ,
          <string-name>
            <surname>C. M. Jermaine</surname>
            ,
            <given-names>P. A.</given-names>
          </string-name>
          <string-name>
            <surname>Bernstein</surname>
          </string-name>
          (Eds.),
          <source>Proceedings of the 2018 International Conference on Management of Data, SIGMOD Conference</source>
          <year>2018</year>
          , Houston, TX, USA, June 10-15,
          <year>2018</year>
          , ACM,
          <year>2018</year>
          , pp.
          <fpage>1433</fpage>
          -
          <lpage>1445</lpage>
          . URL: https://doi.org/10.1145/3183713.3190657. doi:
          <volume>10</volume>
          .1145/3183713.3190657.
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>N.</given-names>
            <surname>Francis</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Gheerbrant</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Guagliardo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>L.</given-names>
            <surname>Libkin</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Marsault</surname>
          </string-name>
          ,
          <string-name>
            <given-names>W.</given-names>
            <surname>Martens</surname>
          </string-name>
          ,
          <string-name>
            <given-names>F.</given-names>
            <surname>Murlak</surname>
          </string-name>
          ,
          <string-name>
            <given-names>L.</given-names>
            <surname>Peterfreund</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Rogova</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Vrgoc</surname>
          </string-name>
          ,
          <article-title>A researcher's digest of GQL (invited talk)</article-title>
          ,
          <source>in: ICDT</source>
          , volume
          <volume>255</volume>
          of LIPIcs,
          <source>Schloss Dagstuhl - Leibniz-Zentrum für Informatik</source>
          ,
          <year>2023</year>
          , pp.
          <volume>1</volume>
          :
          <fpage>1</fpage>
          -
          <lpage>1</lpage>
          :
          <fpage>22</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>R.</given-names>
            <surname>Angles</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Arenas</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Barceló</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Hogan</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J. L.</given-names>
            <surname>Reutter</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Vrgoc</surname>
          </string-name>
          ,
          <article-title>Foundations of modern query languages for graph databases</article-title>
          ,
          <source>ACM Comput. Surv</source>
          .
          <volume>50</volume>
          (
          <year>2017</year>
          )
          <volume>68</volume>
          :
          <fpage>1</fpage>
          -
          <lpage>68</lpage>
          :
          <fpage>40</fpage>
          . URL: https://doi.org/10.1145/3104031. doi:
          <volume>10</volume>
          .1145/3104031.
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>S.</given-names>
            <surname>Abiteboul</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Hull</surname>
          </string-name>
          ,
          <string-name>
            <given-names>V.</given-names>
            <surname>Vianu</surname>
          </string-name>
          , Foundations of Databases, Addison-Wesley,
          <year>1995</year>
          . URL: http://webdam.inria.fr/Alice/.
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <given-names>D.</given-names>
            <surname>Calvanese</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Carroll</surname>
          </string-name>
          ,
          <string-name>
            <given-names>G. D.</given-names>
            <surname>Giacomo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Hendler</surname>
          </string-name>
          ,
          <string-name>
            <given-names>I.</given-names>
            <surname>Herman</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            <surname>Parsia</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P. F.</given-names>
            <surname>Patel-Schneider</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Ruttenberg</surname>
          </string-name>
          ,
          <string-name>
            <given-names>U.</given-names>
            <surname>Sattler</surname>
          </string-name>
          ,
          <string-name>
            <surname>M.</surname>
          </string-name>
          <article-title>Schneider, OWL 2 Web Ontology Language Profiles</article-title>
          ,
          <source>World Wide Web Consortium (W3C)</source>
          ,
          <year>2009</year>
          . URL: https://www.w3.org/TR/owl2-profiles/.
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [8]
          <string-name>
            <given-names>D.</given-names>
            <surname>Calvanese</surname>
          </string-name>
          ,
          <string-name>
            <given-names>G. D.</given-names>
            <surname>Giacomo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>D.</given-names>
            <surname>Lembo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            <surname>Lenzerini</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            <surname>Rosati</surname>
          </string-name>
          ,
          <article-title>Tractable reasoning and eficient query answering in description logics: The DL-Lite family</article-title>
          ,
          <source>J. Autom. Reason</source>
          .
          <volume>39</volume>
          (
          <year>2007</year>
          )
          <fpage>385</fpage>
          -
          <lpage>429</lpage>
          . URL: https://doi.org/10.1007/s10817-007-9078-x. doi:
          <volume>10</volume>
          .1007/ s10817-007-9078-x.
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [9]
          <string-name>
            <given-names>World</given-names>
            <surname>Wide Web Consortium</surname>
          </string-name>
          ,
          <source>Sparql</source>
          <volume>1</volume>
          .1 query language,
          <year>2013</year>
          . URL: https://www.w3.org/ TR/sparql11-query/.
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          <source>[10] World Wide Web Consortium, RDF 1.1 Primer, World Wide Web Consortium (W3C)</source>
          ,
          <year>2014</year>
          . URL: https://www.w3.org/TR/rdf11-primer/.
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>