You are on page 1of 43

Introduction

Preliminaries
HOCQA
Conclusions

A set-theoretic approach to ABox


reasoning services

Domenico Cantone Marianna Nicolosi-Asmundo


Daniele Francesco Santamaria

Department of Mathematics and Computer Science, University of Catania

Rule ML+RR 2017 - London, July 13, 2017

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 1 / 43
Introduction
Preliminaries
HOCQA
Conclusions

Contents

1 Introduction DL4,×
D
Outline of the talk 3 HOCQA
4,×
Computable set theory for HOCQA for DLD
knowledge representation HOCQA for 4LQS R
4,×
Previous and current Procedure HOCQA-DLD
results 4 Conclusions
2 Preliminaries Conclusions
4LQS Future Work
4LQS R References

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 2 / 43
Introduction
Outline of the talk
Preliminaries
Computable set theory for knowledge representation
HOCQA
Previous and current results
Conclusions

Outline of the talk

Computable set theory for knowledge representation.


The set-theoretic fragment 4LQS R .
DL4,× R
D : a description logic representable in 4LQS .
The Higher Order Conjunctive Query Answering (HOCQA)
problem for DL4,×
D and its decidability.
A KE-Tableau based procedure for the HOCQA problem for
DL4,×
D .
Conclusions.
Hints of future work.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 3 / 43
Introduction
Outline of the talk
Preliminaries
Computable set theory for knowledge representation
HOCQA
Previous and current results
Conclusions

Computable set theory for knowledge representation

Computable set theory studies the decision problem for fragments


of set theory (Cantone, Omodeo, Policriti 2001):
Implementation in ÆtnaNova/Referee;
theoretic interest.
Recently, results from Computable Set Theory have been applied in
the ambit of knowledge representation for the semantic web

Set-theoretic fragments −→ To represent description logics and


rule languages ,

Decision procedures −→ To solve reasoning tasks .

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 4 / 43
Introduction
Outline of the talk
Preliminaries
Computable set theory for knowledge representation
HOCQA
Previous and current results
Conclusions

Some results

MLSS×
2,m , (Cantone, Longo, Nicolosi-Asmundo 2010),
DLhMLSS×
2,m i , (Cantone, Longo, Pisasale 2010),
DLh∀π0,2 i , (Cantone, Longo, Nicolosi-Asmundo 2011),
DLh∀π0,2 i + metamodelling, (Cantone, Longo 2014),
DL4D , (Cantone, Longo, Nicolosi-Asmundo, Santamaria
2015).
DL4,×
D and the CQA problem (Cantone, Nicolosi-Asmundo,
Santamaria 2016).
DL4,×
D and the HOCQA problem (Cantone,
Nicolosi-Asmundo, Santamaria 2017).
Reasoner for DL4,×
D (work in progress).

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 5 / 43
Introduction
Outline of the talk
Preliminaries
Computable set theory for knowledge representation
HOCQA
Previous and current results
Conclusions

Some DL4,×
D Features

Focused on TBox and RBox,


Principal reasoning services: subsumption, satisfiability, CQA,
HOCQA.
Decidability results: via reduction to the satisfiability problem
for set-theoretic fragments.
Supports:
datatypes,
concept constructs (i.e., concept domain and range),
role constructs (i.e., union, complement, role chains).
Representable in the decidable four-level stratified syllogistic
4LQS R (Cantone, Nicolosi-Asmundo 2013).
The consistency problem for DL4D -knowledge bases is
decidable (reduction to the satisfiability problem for
4LQS R -formulae).
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 6 / 43
Introduction
Outline of the talk
Preliminaries
Computable set theory for knowledge representation
HOCQA
Previous and current results
Conclusions

This work

Decidability of the problem of Higher Order Conjunctive


Query Answering for DL4,× D through a decision procedure for
the satisfiability problem of 4LQS R .
Design of a KE-tableau based procedure for the HOCQA
problem.
Analysis of the computational complexity of the procedure.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 7 / 43
Introduction
Outline of the talk
Preliminaries
Computable set theory for knowledge representation
HOCQA
Previous and current results
Conclusions

This work - relevant features

Reasoning services for knowledge bases involving ABoxes.


The HOCQA task is a powerful way to query ABoxes (instance
checking, concept retrieval, etc.), relevant for description
logics and real world applications based on semantic web
technologies.
A KE-tableau based procedure for the HOCQA problem for
DL4,×
D
Efficient variant of the tableau system avoiding the
proliferation of redundant branches,
Suitable for implementation (D’Agostino, 1999).
Treated equivalence axioms.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 8 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Syntax of 4LQS

(i) variables of sort 0: x, y , z, . . .


(ii) variables of sort 1: X 1 , Y 1 , Z 1 , . . .
(iii) variables of sort 2: X 2 , Y 2 , Z 2 , . . .
(iv) variables of sort 3: X 3 , Y 3 , Z 3 , . . .

Predicate symbols = and ∈


Pairing operator h·, ·i
4LQS quantifier-free atomic formulae
level 0: x = y, x ∈ X 1, hx, y i = X 2 , hx, y i ∈ X 3 ,
level 1: X 1 = Y 1, X 1 ∈ X 2,
level 2: X 2 = Y 2, X 2 ∈ X 3.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 9 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Syntax of 4LQS

4LQS purely universal formulae


level 1: (∀z1 ) . . . (∀zn )ϕ0 , ϕ0 propositional combination of
level 0 quantifier-free atomic formulae;
level 2: (∀Z11 ) . . . (∀Zm1 )ϕ1 , ϕ1 propositional combination of
quantifier-free atomic formulae of levels 0 and 1 and
of purely universal formulae of level 1;
level 3: (∀Z12 ) . . . (∀Zp2 )ϕ2 , ϕ2 propositional combination of
quantifier-free atomic formulae of any level and of
purely universal formulae of levels 1 and 2.
4LQS-Formulae
Propositional combinations of quantifier-free atomic formulae of
levels 0, 1, 2, and of purely universal formulae of levels 1, 2, 3.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 10 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Semantics of 4LQS

A 4LQS-interpretation is a pair M = (D, M), where


Mx ∈ D
MX 1 ∈ pow(D)
MX 2 ∈ pow(pow(D))
MX 3 ∈ pow(pow(pow(D)))
We put Mhx, y i = {{Mx}, {Mx, My }}

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 11 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Semantics of 4LQS

Formulae are interpreted in a standard way. In particular


M |= (∀z1 ) . . . (∀zn )ϕ0 iff M[z1 /u1 , . . . , zn /un ] |= ϕ0 , for
all u1 , . . . , un ∈ D
M |= (∀Z11 ) . . . (∀Zm1 )ϕ1 iff M[Z11 /U11 , . . . , Zm1 /Um
1 ] |= ϕ ,
1
1 1
for all U1 , . . . , Um ∈ pow(D)
M |= (∀Z12 ) . . . (∀Zp2 )ϕ2 iff M[Z12 /U12 , . . . , Zp2 /Up2 ] |= ϕ2 , for
all U12 , . . . , Up2 ∈ pow(pow(D))

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 12 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Characterizing 4LQS R

4LQS R is the subcollection of the formulae of 4LQS such that


Restriction I
Nestings of quantifiers over variables of sort 0 into quantifiers over
variables of sort 1 are allowed if the
 former Vare linked
V to the 1 
corresponding variables of sort 1 ¬ ϕ0 → ni=1 m j=1 zi ∈ Zj

Example
(∀Z 1 ) Z 1 ∈ X 2 ↔ (∀z) ( z ∈ Z 1 → z ∈ X 1 )


If M |= ¬ ( z ∈ Z 1 → z ∈ X 1 ) then M |= z ∈ Z 1

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 13 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Characterizing 4LQS R

Restriction II (simplified version)


Every quantified atomic formula of level 3 is either
of type (∀Z12 ), . . . , (∀Zp2 )ϕ2 , where ϕ2 is a propositional
combination of quantifier-free atomic formulae, or
of type (∀Z 2 )(Z 2 ∈ X 3 ↔ ¬(∀z1 )(∀z2 )¬(hz1 , z2 i = Z 2 )
Examples
(∀Z 2 )(Z 2 ∈ X 3 ↔ (Z 2 ∈ X13 ∧ Z 2 ∈ X23 )) (intersection)
(∀Z 2 )(Z 2 ∈ X 3 ↔ (Z 2 ∈ X13 ∧ ¬(Z 2 ∈ X23 ))) (set difference)

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 14 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

The description logic DL4,×


D

D = (ND , NC , NF , ·D ): datatype map


RA , RD , C, I: sets of abstract role names, concrete role
names, concept names, individual names
(a) t1 , t2 −→ dr | ¬t1 | t1 u t2 | t1 t t2 | {ed }

(b) C1 , C2 −→ A | > | ⊥ | ¬C1 | C1 t C2 | C1 u C2 | {a}


| ∃R.Self | ∃R.{a} | ∃P.{ed }

(c) R1 , R2 −→ S | U | R1− | ¬R1 | R1 t R2 | R1 u R2 | RC1 |·


| R ·|C1 | RC1 |C2 | id(C ) | C1 × C2

(d) P1 , P2 −→ T | ¬P | P1 t P2 | P1 u P2 | PC1 |· | P·|t1 | PC1 |t1

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 15 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

The description logic DL4,×


D

A DL4,×
D -TBox is a set of statements of the following types:

- C1 ≡ C2 , C1 v C2 , C1 v ∀R1 .C2 , ∃R1 .C1 v C2 ,


≥nR1 .C1 v C2 , C1 v ≤nR1 .C2 ,
- t1 ≡ t2 , t1 v t2 , C1 v ∀P1 .t1 , ∃P1 .t1 v C1 ,
≥nP1 .t1 v C1 , C1 v ≤nP1 .t1 ,

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 16 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Semantics of terms of DL4,×


D

Name Syntax Semantics


concept A AI ⊆ ∆I
ab. (resp., cn.) rl. R (resp., P ) R I ⊆ ∆I × ∆I (resp., P I ⊆ ∆I × ∆D )
individual a a I ∈ ∆I
nominal {a} {a}I = {aI }
dtype (resp., ng.) d (resp., ¬d) d D ⊆ ∆D (resp., ∆D \ d D )
negative datatype term ¬t1 (¬t1 )D = ∆D \ t1D
datatype terms
intersection
t1 u t2 (t1 u t2 )D = t1D ∩ t2D
datatype terms union t1 t t2 (t1 t t2 )D = t1D ∪ t2D
constant in NC (d) ed edD ∈ d D
data range {ed1 , . . . , edn } {ed1 , . . . , edn }D = {edD } ∪ . . . ∪ {edD }
1 n
data range ψd ψdD
data range ¬dr ∆D \ dr D
top (resp., bot.) > (resp., ⊥ ) ∆I (resp., ∅)
negation ¬C (¬C )I = ∆I \ C
conj. (resp., disj.) C u D (resp., C t D) (C u D)I = C I ∩ D I (resp., (C t D)I = C I ∪ D I )
valued exist.
quantification
∃R.a (∃R.a)I = {x ∈ ∆I : hx, aI i ∈ R I }
datatyped exist. quantif. ∃P.ed (∃P.ed )I = {x ∈ ∆I : hx, edD i ∈ P I }
self concept ∃R.Self (∃R.Self )I = {x ∈ ∆I : hx, xi ∈ R I }
nominals {a1 , . . . , an } {a1 , . . . , an }I = {a1I } ∪ . . . ∪ {anI }

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 17 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Semantics of terms of DL4,×


D

Name Syntax Semantics


universal role U (U)I = ∆I × ∆I
inverse role R− (R − )I = {hy , xi | hx, y i ∈ R I }
concept cart. prod. C1 × C2 (C1 × C2 )I = C1I × C2I
abstract role complement ¬R (¬R)I = (∆I × ∆I ) \ R I
abstract role union R1 t R2 (R1 t R2 )I = R1I ∪ R2I
abstract role intersection R1 u R2 (R1 u R2 )I = R1I ∩ R2I
abstract role domain restr. RC | (RC | )I = {hx, y i ∈ R I : x ∈ C I }
concrete role complement ¬P (¬P)I = (∆I × ∆D ) \ P I
concrete role union P1 t P2 (P1 t P2 )I = P1I ∪ P2I
concrete role intersection P1 u P2 (P1 u P2 )I = P1I ∩ P2I
concrete role domain restr. PC | (PC | )I = {hx, y i ∈ P I : x ∈ C I }
concrete role range restr. P|t (P|t )I = {hx, y i ∈ P I : y ∈ t D }
concrete role restriction PC |t (PC |t )I = {hx, y i ∈ P I : x ∈ C1I ∧ y ∈ t D }
1 1

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 18 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Semantics of axioms and assertions of DL4,×


D -KB

Name Syntax Semantics


concept subsum. C1 v C2 I |=D C1 v C2 ⇐⇒ C1I ⊆ C2I
ab. role subsum. R1 v R2 I |=D R1 v R2 ⇐⇒ R1I ⊆ R2I
role incl. axiom R1 . . . Rn v R I |=D R1 . . . Rn v R ⇐⇒ R1I ◦ . . . ◦ RnI ⊆ R I
cn. role subsum. P1 v P2 I |=D P1 v P2 ⇐⇒ P1I ⊆ P2I
symmetric role Sym(R) I |=D Sym(R) ⇐⇒ (R − )I ⊆ R I
asymmetric role Asym(R) I |=D Asym(R) ⇐⇒ R I ∩ (R − )I = ∅
transitive role Tra(R) I |=D Tra(R) ⇐⇒ R I ◦ R I ⊆ R I
disj. ab. role Dis(R1 , R2 ) I |=D Dis(R1 , R2 ) ⇐⇒ R1I ∩ R2I = ∅
reflexive role Ref(R) I |=D Ref(R) ⇐⇒ {hx, xi | x ∈ ∆I } ⊆ R I
irreflexive role Irref(R) I |=D Irref(R) ⇐⇒ R I ∩ {hx, xi | x ∈ ∆I } = ∅
func. ab. role Fun(R) I |=D Fun(R) ⇐⇒ (R − )I ◦ R I ⊆ {hx, xi | x ∈ ∆I }
disj. cn. role Dis(P1 , P2 ) I |=D Dis(P1 , P2 ) ⇐⇒ P1I ∩ P2I = ∅
I |=D Fun(p) ⇐⇒ hx, y i ∈ P I and hx, zi ∈
func. cn. role Fun(P)
P I imply y = z
datatype terms
equivalence
t1 ≡ t2 I |=D t1 ≡ t2 ⇐⇒ t1D = t2D
datatype terms subsum. t1 v t2 I |=D (t1 v t2 ) ⇐⇒ t1D ⊆ t2D
concept assertion a : C1 I |=D a : C1 ⇐⇒ (aI ∈ C1I )
agreement a=b I |=D a = b ⇐⇒ aI = b I
ab. role asser. (a, b) : R I |=D (a, b) : R ⇐⇒ haI , b I i ∈ R I
cn. role asser. (a, ed ) : P I |=D (a, ed ) : P ⇐⇒ haI , edD i ∈ P I

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 19 / 43
Introduction
4LQS
Preliminaries
4LQS R
HOCQA 4,×
DLD
Conclusions

Expressiveness of DL4,×
D

Existential quantification and at-least number restriction


(resp., universal quantification and at-most number
restriction) only on the left- (resp., right-) hand side of
inclusion axioms.
More liberal than SROIQ(D) in:
construction of role inclusion axioms (roles involved not
subject to any ordering relationship),
simple roles are not needed to define role inclusion axioms and
axioms involving number restrictions,
Boolean operators on roles are admitted.
Derived datatypes (inside inclusion axioms involving concrete
roles).

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 20 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

HO Conjunctive Query Answering for DL4,×


D

Let Vi = {v1 , v2 , . . .}, Vc = {c1 , c2 , . . .}, Var = {r1 , r2 , . . .}, and


Vcr = {p1 , p2 , . . .} be pairwise disjointSdenumerable infinite sets of
variables which are disjoint from Ind, {NC (d) : d ∈ ND }, C, RA ,
and RD .
A HO DL4,× D -atomic formula is an expression of one of the
following types: R(w1 , w2 ), P(w1 , u1 ), C (w1 ), r(w1 , w2 ), p(w1 , u1 ),
c(w1 ), w1 = w S2 , u1 = u2 , where w1 , w2 ∈ Vi ∪4,×Ind,
u1 , u2 ∈ Vi ∪ {NC (d) : d ∈ ND }, R is a DLD -abstract role
term, P is a DL4,× 4,×
D -concrete role term, C is a DLD -concept term,
r ∈ Var , p ∈ Vcr , and c ∈ Vc .

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 21 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

HO Conjunctive Query Answering for DL4,×


D

A HO DL4,× D -atomic formula containing no variables is said to be


ground. A HO DL4,× 4,×
D -literal is a HO DLD - atomic formula or its
negation. A HO DL4,× D -conjunctive query is a conjunction of HO
4,× 4,×
DLD -literals. We denote with λ the empty HO DLD -
conjunctive query.
Let v1 , . . . , vn ∈ Vi , c1 , . . . , cm ∈ Vc ,Sr1 , . . . , rk ∈ Var ,
p1 , . . . , ph ∈ Vcr , o1 , . . . , on ∈ Ind ∪ {NC (d) : d ∈ ND },
C1 , . . . , Cm ∈ C, R1 , . . . , Rk ∈ RA , and P1 , . . . , Ph ∈ RD .

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 22 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

HO Conjunctive Query Answering for DL4,×


D

A substitution

σ =Def {v1 /o1 , . . . , vn /on , c1 /C1 , . . . , cm /Cm ,


r1 /R1 , . . . , rk /Rk , p1 /P1 , . . . , ph /Ph }

is a map such that, for every HO DL4,×


D -literal L, Lσ is obtained
from L by replacing
the occurrences of vi in L with oi , for i = 1, . . . , n;
the occurrences of cj in L with Cj , for j = 1, . . . , m;
the occurrences of r` in L with R` , for ` = 1, . . . , k;
the occurrences of pt in L with Pt , for t = 1, . . . , h.
Substitutions can be extended to HO DL4,×
D -conjunctive queries in
the usual way.
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 23 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

HO Conjunctive Query Answering for DL4,×


D

Let Q =Def (L1 ∧ . . . ∧ Lm ) be a HO DL4,×


D -conjunctive query, and
4,×
KB a DLD -knowledge base. The Higher Order Conjunctive
Query Answering (HOCQA) problem for a DL4,× D -HO conjunctive
query Q w.r.t. KB consists in finding the HO answer set Σ of Q
w.r.t. KB, namely the collection of the solutions for Q w.r.t. KB.
A substitution σ is a solution for Q w.r.t. KB if:
it involves exactly the variables occurring in Q and
there exists a DL4,×
D -interpretation I such that I |=D KB and
I |=D Qσ.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 24 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

HO Conjunctive Query Answering for DL4,×


D

Example:
KB 1 = ({hasParent · hasBrother v hasUncle},
{Female, Male},
{hasParent(Ann, Paul), hasParent(John, Ann),
Male(John), Male(Bob), Male(James), Male(Paul),
hasBrother(Paul, Bob), hasBrother(Ann, James)})
Q1 = hasParent(x, y ) ∧ hasUncle(x, James) ∧ Female(y )
Σ1 = {σ1 = {x/John, y /Ann}} ,
Q2 = hasUncle(x, z)
Σ2 = {σ2 = {x/Ann, z/Bob}, τ2 = {x/John, z/James}}.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 25 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

HO Conjunctive Query Answering for 4LQS R -formulae


Let φ be a 4LQS R -formula and
ψ a conjunction of 4LQS R -formulae of the types
x = y,
x ∈ X 1,
hx, y i ∈ X 3
or their negations.

The HOCQA problem for ψ w.r.t. φ consists in computing the HO


answer set of ψ w.r.t. φ, namely the collection Σ0 of all the
substitutions σ 0 =Def {x/z, X1 /Y1 , X2 /Y2 , X3 /Y3 } such that
M |= φ ∧ ψσ 0 , for some 4LQS R -interpretation M.

The HOCQA problem for 4LQS R -formulae is decidable (by the


decidability of the satisfiability problem for 4LQS R ).
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 26 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Decidability of the HOCQA problem for DL4,×


D

Theorem 1. Given a DL4,×


D -knowledge base KB and a
4,×
DLD -conjunctive query Q, the HOCQA problem for Q w.r.t. KB
is decidable.

Idea of the proof:


Transformation θ from DL4,× D -statements into
4LQS R -formulae in CNF
Example: θ(C1 ≡ {a}) =Def (∀z)((¬(z ∈ XC11 ) ∨ z =
xa ) ∧ (z ∈ XC11 ∨ ¬(z = xa ))),
definition of the 4LQS R -formulae φKB and ψQ in CNF
Σ consists of all substitutions σ such that θ(σ) ∈ Σ0 (recall
that Σ0 can be effectively calculated).

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 27 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D

Given
φKB corresponding to a DL4,×
D -knowledge base KB and
ψQ corresponding to a DL4,×
D -HO conjunctive query Q

the procedure yields all the substitutions σ 0 belonging to the


answer set Σ0 of ψQ w.r.t. φKB .

It consists of:
a preliminary phase,
a saturation phase, and
a phase of construction of the answer set.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 28 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D

Let φKB be obtained from φKB by:


moving universal quantifiers in φKB as inwards as possible,
renaming universally quantified variables so as to make them
pairwise distinct.

We define
m
S
ΦKB =defAs Exp(Si ) ∪ {Fj : i = 1, . . . , k} ,
i=1

where

Si {z1i /xa1 , . . . , zni i /xani }


V
Exp(Si ) =defAs
{xa1 ,...,xan }⊆Var0 (φKB )
i

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 29 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D
Example:

KB 2 = {∅, {Kid ≡ Person u VeryYoung} ,


{Person(Ann) }

φKB2 = (∀x)((¬(x ∈ XK1 ) ∨ x ∈ XP1 ) ∧ (¬(x ∈ XK1 ) ∨ x ∈ XVY


1 )∧

(¬(x ∈ XP1 ) ∨ ¬(x ∈ XVY


1 ) ∨ x ∈ X 1 )) ∧
K
xA ∈ XP1

φ̄KB2 = (∀x)(¬(x ∈ XK1 ) ∨ x ∈ XP1 ) ∧ (∀y )(¬(y ∈ XK1 ) ∨ y ∈ XVY


1 )∧

(∀z)(¬(z ∈ XP1 ) ∨ ¬(z ∈ XVY


1 ) ∨ z ∈ X 1) ∧
K
xA ∈ XP1
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 30 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D

Example:

ΦKB2 = { ¬(xA ∈ XK1 ) ∨ xA ∈ XP1 ,

¬(xA ∈ XK1 ) ∨ xA ∈ XVY


1 ,

¬(xA ∈ XP1 ) ∨ ¬(xA ∈ XVY


1 ) ∨ x ∈ X1 ,
A K

xA ∈ XP1 }

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 31 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D
Expansion rules for the KE-tableau

β1 ∨ . . . ∨ βn Siβ
E-Rule PB-Rule
βi A | A

where with A a literal


Siβ := {β 1 , ..., β n } \ {β i }
i = 1, ..., n

A branch of a KE-tableau is closed if it contains both A and


¬A, for some formula A, otherwise it is open.
A formula β1 ∨ . . . ∨ βn is fulfilled in a branch ϑ, if βi is in ϑ,
for some i = 1, . . . , n.
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 32 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D - saturation phase
4,×
1: procedure HOCQA-DLD (ψQ ,φKB );
2: Σ0 := ∅;
3: - let ΦKB be the expansion of φKB ;
4: TKB := ΦKB ;
5: while TKB is not fulfilled do
6: - select an unfulfilled open branch ϑ of TKB and an unfulfilled
formula β1 ∨ . . . ∨ βn in ϑ;
7: if Sjβ is in ϑ, for some j ∈ {1, . . . , n} then
8: - apply the E-Rule to β1 ∨ . . . ∨ βn and Sjβ on ϑ;
9: else
10: - let B β be the collection of the formulae β 1 , . . . , β n present
in ϑ and let h be the lowest index such that β h ∈ / Bβ;
11: - apply the PB-rule to β h on ϑ;
12: end if;
13: end while; . procedure continues
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 33 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D - saturation phase
Example:
1 )∨x
¬(xA ∈ XKid 1
Ann ∈ XPerson

1 ) ∨ x ∈ X1
¬(xAnn ∈ XKid A VeryYoung

1
¬(xAnn ∈ XPerson 1
) ∨ ¬(xA ∈ XVeryYoung 1
) ∨ xAnn ∈ XKid

1
xAnn ∈ XPerson

PB-Rule
1
xAnn ∈ XVeryYoung 1
¬(xAnn ∈ XVeryYoung )

E-Rule E-Rule
xAnn ∈ 1
XKid 1 )
¬(xAnn ∈ XKid
Complete Complete

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 34 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D - equivalence axioms

14: while TKB has open branches containing literals of type x = y ,


with distinct x and y do
15: - select such an open branch ϑ of TKB ;
16: σϑ :=  (where  is the empty substitution);
17: Eqϑ := {literals of type x = y occurring in ϑ};
18: while Eqϑ contains x = y , with distinct x, y do
19: - select a literal x = y in Eqϑ , with distinct x, y ;
20: z := min<ϑ (x, y );
21: σϑ := σϑ · {x/z, y /z};
22: Eqϑ := Eqϑ σϑ ;
23: end while;
24: ϑ := ϑσϑ ; . procedure continues
44: end while

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 35 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D - construction of the HO answer set

Each open and complete branch ϑ of TKB induces a


4LQS R -interpretation Mϑ such that Mϑ |= ΦKB .

For every open and complete branch ϑ of TKB , we construct a


decision tree Dϑ such that every maximal branch of Dϑ
defines a substitution σ 0 such that Mϑ |= ψQ σ 0 .

Each σ 0 is added to the answer set Σ0 .

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 36 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D - construction of the HO answer set

25: if ϑ is open then


26: - initialize S to the empty stack;
27: - push (, ψQ σϑ ) in S;
28: while S is not empty do
29: - pop (σ 0 , ψQ σϑ σ 0 ) from S;
30: if ψQ σϑ σ 0 6= λ then
31: - let q be the leftmost conjunct of ψQ σϑ σ 0 ;
32: ψQ σϑ σ 0 := ψQ σϑ σ 0 deprived of q;
33: LitQM := {t ∈ ϑ : t = qρ, for some substitution ρ};

34: while LitQ M is not empty do

35: - let t ∈ LitQM , t = qρ;

36: M M
LitQ := LitQ \ {t};
37: - push (σ 0 ρ, ψQ σϑ σ 0 ρ) in S;
38: end while;
39: else
40: Σ0 := Σ0 ∪ {σϑ σ 0 };
41: end if;
42: end while;
43: end if; . end while of line 14
45: return (TKB , Σ0 ); . end of procedure
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 37 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Procedure HOCQA-DL4,×
D - construction of the HO answer set

Example:
1 )∨x
¬(xAnn ∈ XKid 1
Ann ∈ XPerson

1 )∨x
¬(xAnn ∈ XKid 1
Ann ∈ XVeryYoung

1
¬(xAnn ∈ XPerson 1
) ∨ ¬(xA ∈ XVeryYoung 1
) ∨ xAnn ∈ XKid

1
xAnn ∈ XPerson
PB-Rule
1
xAnn ∈ XVeryYoung 1
¬(xAnn ∈ XVeryYoung )
E-Rule E-Rule
1
xAnn ∈ XKid 1 )
¬(xAnn ∈ XKid
Complete Complete
1 ∧ y ∈ X1
h, x ∈ XKid VeryYoung i
1
h{x/xAnn }, y ∈ XVeryYoung i
h{x/xAnn , y /xAnn }, Λi

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 38 / 43
Introduction 4,×
HOCQA for DLD
Preliminaries
HOCQA for 4LQS R
HOCQA 4,×
Procedure HOCQA-DLD
Conclusions

Some remarks

The procedure is correct, complete, and terminating.

The HO answer set of ψQ w.r.t. φKB is calculated in


double-exponential time.

Sizes of φKB and ψQ are polynomially related to those of KB


and Q
the construction of the HO answer set of Q w.r.t. KB can be
done in double-exponential time.

In case KB contains no role chain axioms and qualified


cardinality restrictions, the complexity of our HOCQA problem
is in EXPTIME.
Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 39 / 43
Introduction
Conclusions
Preliminaries
Future Work
HOCQA
References
Conclusions

Conclusions

4,×
We addressed the problem of HOCQA for DLD by
4,×
formalizing the notions of DLD -knowledge bases and of
DL4,× R
D -HO conjunctive queries in terms of 4LQS .

We introduced a KE-tableau based procedure to compute the


HO answer set of a DL4,×
D -conjunctive query Q w.r.t. a
4,×
DLD -knowledge base KB and gave some complexity results.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 40 / 43
Introduction
Conclusions
Preliminaries
Future Work
HOCQA
References
Conclusions

Hints of future work

Implementation of the procedure (work in progress),

Generalization of the procedure with datatypes,

Extension to restricted form of composition operator,

Improvement of the efficiency of the KE-tableau based


procedure and of the expressiveness of the queries,

Definition of a parallel model of the procedure and relative


implementation,

Relational dual tableaux.


Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 41 / 43
Introduction
Conclusions
Preliminaries
Future Work
HOCQA
References
Conclusions

References

Cantone D. and Longo C., A decidable two-sorted quantified fragment of set


theory with ordered pairs and some undecidable extensions. Theor. Comput.
Sci., 560:307—325, 2014.
Cantone D., Longo C. and Nicolosi-Asmundo M., A decidable quantified
fragment of set theory involving ordered pairs with applications to description
logics. In Proc. Computer Science Logic, 20th Annual Conf. of the EACSL,
CSL 2011, September 12-15, 2011, Bergen, Norway, pages 129—143.
Cantone D., Longo C., Nicolosi-Asmundo M., and Santamaria D. F., Web
ontology representation and reasoning via fragments of set theory, in Proc. Web
Reasoning and Rule Systems - 9th International Conference, RR 2015, Berlin,
Germany, August 4-5, 2015, LNCS vol. 9209, Springer, ISBN
978-3-319-22001-7 pp. 61–76.
Cantone D., Longo C. and Pisasale A., Comparing description logics with
multi-level syllogistics: the description logic DLhMLSS×
2,m i. In Paolo Traverso,
editor, 6th Workshop on Semantic Web Applications and Perspectives
(Bressanone, Italy, Sep. 21-22, 2010), pages 1—13, 2010.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 42 / 43
Introduction
Conclusions
Preliminaries
Future Work
HOCQA
References
Conclusions

References

Cantone D. and Nicolosi-Asmundo M., On the satisfiability problem for a 4-level


quantified syllogistic and some applications to modal logic. Fundamenta
Informaticae, 124(4):427—448, 2013.
Cantone D., Nicolosi-Asmundo M., Santamaria D. F., Trapani F., Ontoceramic:
an owl ontology for ceramics classification, in Proc. of the 30th Italian Conf. on
Computational Logic, CILC 2015, July 1-3 2015 Genova, CEUR Electronic
Workshop Proceedings, vol. 1459, pp. 122–127.
Cantone D., Omodeo E.G. and Policriti A., Set theory for computing: from
decision procedures to declarative programming with sets. Monographs in
Computer Science. Springer-Verlag, New York, NY, USA, 2001.
D’Agostino M., Tableau methods for classical propositional logic. Handbook of
Tableau Methods, M. D’Agostino, D. M. Gabbay, R. Haehnle, and J. Posegga,
Eds. Springer, 1999, pp. 45–123.

Cantone, Nicolosi-Asmundo, Santamaria Rule ML+RR 2017 - London, July 13, 2017 43 / 43

You might also like