Description Logics Syntax, Semantics and Reasoning Services - Claudia d'Amato & Nicola Fanizzi

Page created by Jonathan Burns
 
CONTINUE READING
Description Logics
Syntax, Semantics and Reasoning Services

    Claudia d’Amato & Nicola Fanizzi
  Machine Learning and the Semantic Web

 PhD Programme in Computer Science and Mathematics
      Università degli Studi di Bari ”Aldo Moro”

                 March 3, 2020
Summary

1     Description Logics
        The DL Famiy
        Defining a DL Knowledge Base
        Reasoning Services

    d’Amato & Fanizzi   (MLSW)   Description Logics   March 3, 2020   2 / 28
Agenda

1     Description Logics
        The DL Famiy
        Defining a DL Knowledge Base
        Reasoning Services

    d’Amato & Fanizzi   (MLSW)   Description Logics   March 3, 2020   3 / 28
DLs: Characteristics

Description Logics:
      family of logics of different expressive power
      decidable fragment of FOL
      grounded on Model Theoretic semantics
      describe domains in terms of Concepts (classes), roles (relation),
      individuals
      endowed with several reasoning services (usually correct and complete)
      theoretical and computational foundation of OWL

 d’Amato & Fanizzi   (MLSW)       Description Logics          March 3, 2020   4 / 28
DLs Architecture

 d’Amato & Fanizzi   (MLSW)   Description Logics   March 3, 2020   5 / 28
DL: Basic Elements

      Primitive Concepts NC = {C, D, . . .}: subsets of a domain
      Primitive Roles NR = {R, S, . . .}: binary relations on the domain
      Interpretation I = (∆I , ·I ) where
            ∆I : domain of the interpretation
            ·I : interpretation function
                     assigns to each primitive concept C a subset C I ⊆ ∆I
                     assigns to each primitive role R a binary relation RI ⊆ ∆I × ∆I

 d’Amato & Fanizzi   (MLSW)             Description Logics              March 3, 2020   6 / 28
The Basic Language: AL

     AL = Attribute Language [Schmidt-Schauß, 1991]
     Other languages obtained as extension of AL
     Operators → Complex concept descriptions

     Example.: Primitive Concepts: Person, Female → Person u Female;
     Person u ¬Female
     Primitive Role: hasChild → Person u ∀hasChild.Female
                                Person u ∃hasChild.>
                                Person u ∃hasChild.⊥

d’Amato & Fanizzi   (MLSW)    Description Logics      March 3, 2020   7 / 28
AL: Semantics

     Given the interpretation function, the interpretation of complex
     descriptions is defined inductively

     Two concepts C and D are said equivalent (C ≡ D) if for all
     interpretations I results C I = DI

d’Amato & Fanizzi   (MLSW)      Description Logics          March 3, 2020   8 / 28
Multiple Models and Single Model

      A DLs Knowledge Base (KB) does not define a single model
            a KB is a set of constraints defining a set of possible models
                     No constrains (== empty KB) ⇔ any model is possible
                     By increasing constraints decrease the possible models
                     A very high number of constraints may cause that any possible model
                     exists (inconsistent KB)
      Differently, DB (and frame/rule KR systems) make assumptions so
      that DB/KB define a single model
            UNA == different names are interpreted as different individuals
            Closed World Assumption == the domain is built by the only
            individuals that are mentioned in DB/KB
            Minimal Models == the extensions are as small as possible

 d’Amato & Fanizzi   (MLSW)             Description Logics              March 3, 2020   9 / 28
DLs: Constructs

            Name           Syntax           Semantics
 atomic negation       ¬A, A ∈ NC           A I ⊆ ∆I
      full negation          ¬C             C I ⊆ ∆I
    concept conj.          CuD              C I ∩ DI
     concept disj.         CtD              C I ∪ DI
  full exist. restr.        ∃R.C            {a ∈ ∆I | ∃b (a, b) ∈ RI ∧ b ∈ C I }
   universal restr.         ∀R.C            {a ∈ ∆I | ∀b (a, b) ∈ RI → b ∈ C I }
    at most restr.          ≤ nR            {a ∈ ∆I | | {b ∈ ∆I | (a, b) ∈ RI } |≤ n}
    at least restr.         ≥ nR            {a ∈ ∆I | | {b ∈ ∆I | (a, b) ∈ RI } |≥ n}
qualif. at most r.       ≤ nR.C             {a ∈ ∆I | | {b ∈ ∆I | (a, b) ∈ RI ∧ b ∈ C I } |≤ n}
qualif. at least r.      ≥ nR.C             {a ∈ ∆I | | {b ∈ ∆I | (a, b) ∈ RI ∧ b ∈ C I } |≥ n}
             one-of    {a1 , a2 , ...an }   {a ∈ ∆I | a = ai , 1 ≤ i ≤ n}
          has value       ∃R.{b}            {a ∈ ∆I | (a, b) ∈ RI }
          inverse of         R−             {(b, a) ∈ ∆I × ∆I | (a, b) ∈ RI }

 d’Amato & Fanizzi     (MLSW)                  Description Logics                 March 3, 2020   10 / 28
DLs: Constructors e Languages of the AL Family

                 DL Name                 Constructors

                       ALN      AL ∪ {≤ nR, ≥ nR} (N )
                       ALE         AL ∪ {∃R.C} (E)
                      ALEN        ALE ∪ {≤ nR, ≥ nR}
                       ALC         ALE ∪ {¬C, t} (C)
                      ALCN        ALC ∪ {≤ nR, ≥ nR}
                     SHOIN     ALC ∪ role transitivity (S)∪
                                 ∪role hierarchies (H)∪
                              ∪ oneOf (i.e. nominals) (O)∪
                               ∪{R− }(inverserole) (I) ∪ N
                      SHIQ    SHI ∪ {≤ n R.C, ≥ n R.C} (Q)

 d’Amato & Fanizzi   (MLSW)       Description Logics     March 3, 2020   11 / 28
OWL e DLs

     OWL DL is grounded on SHIQ e SHOIN (D)
     OWL benefits of:
           Reasoning algorithms and DLs Formal properties
                    algorithms complexity and decidability well understood
           Reasoners implementing DLs services freely available

d’Amato & Fanizzi   (MLSW)              Description Logics             March 3, 2020   12 / 28
KB & Subsumption

K = hT , Ai
      TBox T – set of definitions C ≡ D equality axiom, meaning C I = DI

            An equality axiom where C is an atomic concept is called definition
            Es.: Mother ≡ Woman u ∃hasChild.Person
            Other axioms: C v D inclusion axioms meaning C I ⊆ DI (risp.
            RI ⊆ S I )
                     where C, D concepts and R, S roles;
      ABox A – set of concept and role assertions e.g. C(a) e R(a, b),
      meaning: aI ∈ C I e (aI , bI ) ∈ RI (risp.).

Subsumption
Let C and D two concept descriptions, C sussume D, denoted D v C, iff
for all interpretations I, results DI ⊆ C I

 d’Amato & Fanizzi   (MLSW)            Description Logics        March 3, 2020    13 / 28
TBox: Example

Primitive Concepts: NC = {Female, Male, Human}.
Primitive Roles: NR = {HasChild, HasParent, HasGrandParent, HasUncle}.
T = { Woman ≡ Human u Female; Man ≡ Human u Male
Parent ≡ Human u ∃HasChild.Human
Mother ≡ Woman u Parent
Father ≡ Man u Parent
Child ≡ Human u ∃HasParent.Parent
Grandparent ≡ Parent u ∃HasChild.( ∃ HasChild.Human)
Sibling ≡ Child u ∃HasParent.( ∃ HasChild ≥ 2)
Niece ≡ Human u (∃HasGrandParent.Parent t ∃HasUncle.Uncle)
Cousin ≡ Niece u ∃HasUncle.(∃ HasChild.Human)
}.

 d’Amato & Fanizzi   (MLSW)    Description Logics         March 3, 2020   14 / 28
ABox: Example

A = {Woman(Clara), Woman(Tiziana), Father(Leonardo), Father(Antonio),
Father(AntonioB),Mother(Maria), Mother(Giovanna), Child(Valentina), Sibling(Martina),
Sibling(Vito), HasParent(Clara,Giovanna), HasParent(Leonardo,AntonioB),
HasParent(Martina,Maria), HasParent(Giovanna,Antonio), HasParent(Vito,AntonioB),
HasParent(Tiziana,Giovanna), HasParent(Tiziana,Leonardo), HasParent(Valentina,Maria),
HasParent(Maria,Antonio), HasSibling(Leonardo,Vito), HasSibling(Martina,Valentina),
HasSibling(Giovanna,Maria), HasSibling(Vito,Leonardo), HasSibling(Tiziana,Clara),
HasSibling(Valentina,Martina), HasChild(Leonardo,Tiziana), HasChild(Antonio,Giovanna),
HasChild(Antonio,Maria), HasChild(Giovanna,Tiziana), HasChild(Giovanna,Clara),
HasChild(AntonioB,Leonardo), HasChild(Maria,Valentina), HasUncle(Martina,Giovanna),
HasUncle(Valentina,Giovanna)
}

    d’Amato & Fanizzi   (MLSW)         Description Logics                 March 3, 2020   15 / 28
Subsumption: Example

Given the definition: Father ≡ Male u ∃hasChild.Person
”a father is a male (person) having persons as children”

Examples of assertions are:
Male(Leonardo), Male(Vito), hasChild(Leonardo, Vito)

Let us suppose that Male v Person:
Person(Leonardo), Person(Vito) hence Father(Leonardo)

Other definitions:
Parent ≡ Person u ∃hasChild.Person and
FatherWithoutSons ≡ Male u ∃hasChild.Person u ∀hasChild.(¬Male)

It is straightforward to verify:
Father v Parent and FatherWithoutSons v Father.

 d’Amato & Fanizzi   (MLSW)    Description Logics          March 3, 2020   16 / 28
Reasoning on ontologies

      Given an ontology ⇒ the implicit knowledge may be made explicit by
      reasoning operators

      Developed Reasoners:
            FaCT
            RACER
            PELLET
            Hermit

 d’Amato & Fanizzi   (MLSW)    Description Logics        March 3, 2020   17 / 28
TBox: Standard Reasoning Services

      Concept Satisfiability: verify if a new added concept within an
      ontology is coherent with its TBox or if it contradicts the TBox
Definition of Concept Satisfiability
Given a concept C it is satisfiable wrt the TBox T if there exists a model I
of T s.t. C I 6= ∅.
It is said that I is model of C

      Example:
      T = { Parent, Man, Woman ≡ ¬ Man, Mother ≡ Woman u
      Parent}
      added Mother v Man ⇒ new axiom unsatisfiable wrt the TBox
      the disjointness axiom Woman ≡ ¬ Man violated

 d’Amato & Fanizzi   (MLSW)      Description Logics        March 3, 2020   18 / 28
TBox: Standard Reasoning Services                                    [. . . cont.]

      Concept Subsumption: verify if a se a concept C is more general
      than another concept D
            used for building the concept hierarchy

A concept C subsumes a concept D wrt TBox T if DI ⊆ C I for each model
I of T . Written as: D vT C or T |= D v C
      Example:
      T = { Parent, Man, Woman ≡ ¬ Man, Mother ≡ Woman u Parent} added
      Father ≡ Man u Parent ⇒ Father v Parent and Father v Man

Two concepts C and D are equivalent wrt T if C I = DI for each model I
of T . It is written C ≡T D are T |= C ≡ D

Two concepts C are D are disjoint wrt T if C I ∩ DI = ∅ ∀ model I of T .
N.B.: the qualification "wrt T " can be omitted when T is clear from the context (or T is
empty)

 d’Amato & Fanizzi   (MLSW)            Description Logics                    March 3, 2020   19 / 28
ABox: Standard Reasoning Services

      ABox Consistency Check (wrt TBox): verify if a new (concept or
      role) assertion in ABox A makes A inconsistent wrt TBox T or not
            Example 1:
            T = {Woman ≡ Person u Female, Man ≡ Person u ¬Female};
            A = { Woman(MARY),Man(MARY)} ⇒ A is è inconsistent wrt T
            Example 2: TBox T = {Woman, Man} ⇒ A consistent wrt T
            there is no restriction on the interpretation of the concepts Woman and
            Man
      Instance Checking: assesses if an individual is an instance of a given
      concept or not
      Retrieval: returns all individuals that are instance of a concept
            Example:
            T = {Woman v Female }; A = { Female(Ann), Woman(Sara)}
            ⇒ Retrieval(Female) = {Ann, Sara}

 d’Amato & Fanizzi   (MLSW)        Description Logics            March 3, 2020   20 / 28
OWA vs. CWA...

     Open World Assumption: typically mande in DLs
           Missing information is interpreted as information not known
                    Knowledge in the KB is not considered as complete
     Closed World Assumption: typically made in DB, ML
           Missing information is interpreted as negative information
                    Knowledge in the KB is considered as complete

Example:
    T = { Female,Woman};
    A = { Female(Ann),Woman(Sara)}

     CWA: q = Female(Sara) ? → N O
     OWA: q = Female(Sara) ? → U N KN OW N

d’Amato & Fanizzi   (MLSW)             Description Logics               March 3, 2020   21 / 28
OWA vs. CWA...                    [. . . cont.]

     another example of the meaning of OWA: the scope of resource
     descriptions is not the single OWL file
           Example: Given a class C1 defined in the ontology O1 , C1 can be
           extended in other ontologies
           the consequences of the additional propositions concerning C1 are
           MONOTONE ⇔ new information cannot retract previous inforamtion
                    New (also deduced) information can only be added, also if they
                    contradict existing knowledge

d’Amato & Fanizzi   (MLSW)                 Description Logics          March 3, 2020   22 / 28
Reasoning Algorithms

      Almost all reasoning services may be reduced to a basic service: the
      ABox Consistency Check
            provided that the DL allows conjunction and (full) negation
            Tableau based algorithms have been developed
                     Complexity of the algorithm: exponential in time and space
                     can be optimized → polynomial complexity in space
      For DLs that do not allow negation
            algorithms grounded on the comparison of the structure of
            (normalized) concepts are considered (e.g. structural subsuption)

 d’Amato & Fanizzi   (MLSW)             Description Logics              March 3, 2020   23 / 28
Reduction of the standard inferences to the ABox
Consistency Check

Given the concepts C and D the following equivalence are valid
Reduction to the Subsumption
  1   C is unsatisfiable ⇔ C is subsumed by ⊥
  2   C ≡ D ⇔ C is subsumed by D and D is subsumed by C
  3   C and D are disjoint ⇔ C u D is subsumed by ⊥

If the DL allows for negation, the following equivalence are valid:
Reduction to Unsatisfiability
  1   C is subsumed by D ⇔ C u ¬D is unsatisfiable
  2   C ≡ D ⇔ both C u ¬D and ¬C u D unsatisfiable
  3   C and D are disjoint ⇔ C u D is unsatisfiable
N.B.: These propositions are verified also wrt TBox

 d’Amato & Fanizzi   (MLSW)     Description Logics           March 3, 2020   24 / 28
Reduction of the standard inferences to the ABox
Consistency Check [. . . cont.]

Reduction of Unsatisfiability
Given the concept C, the following propositions are equivalent
   1   C is unsatisfiable
   2   C is subsumed by ⊥
   3   C and ⊥ are equivalent
   4   C and > are disjoint

Reduction of the Instance Check to the ABox Consistency Check
       A |= C(a) iff A ∪ {¬C(a)} is inconsistent
where a is an arbitrary individual

Reduction of the Concept Satisfiability to the ABox Consistency Check
       C is satisfiable iff {C(a)} is consistent
where a is an arbitrary individual

N.B.: These propositions are verified also wrt TBox

 d’Amato & Fanizzi   (MLSW)                Description Logics           March 3, 2020   25 / 28
Standard Reasoning Services in the Ontology
Lifecycle

Standard Reasoning Services can be exploited in different phases of the
Ontology Lifecycle
    Design
            Check for concepts satisfiability within the ontology and consequent
            relationships (implicitly) implied
      Ontology Merging/Alignment
            Inter-ontology relationships
            Captuiring/computing concept hierarchy among different ontologies
      Ontology Deployment
            Assess if a set of assertions is consistent with the ontology
            Assess if a set of individuals are instances of one or more concepts
            within the ontology
            Query Inclusion / Classification-based querying

 d’Amato & Fanizzi   (MLSW)         Description Logics             March 3, 2020   26 / 28
Some Non-Standard Reasoning Services

least common subsumer is the most specific concept subsuming a given set
            of concepts
A concept description E is the lcs of C1 , · · · , Cn iff
  1   Ci v E ∀ i = 1, · · · , n and
  2   if E 0 is a concept satisfying (1) then E v E 0

realization problem assesses the concepts to which an individual belongs
               to. Among these concepts, the most specific concept (if it
               exists) is particularly important and it is formally defined as:
most specific concept
Given an ABox A and an individual a, the most specific concept of a wrt A is
the concept C, denoted MSCA (a), s.t. A |= C(a) and ∀D s.t. A |= D(a),
C v D,.

 d’Amato & Fanizzi   (MLSW)       Description Logics           March 3, 2020   27 / 28
Bibliography

      F. Baader et al. The Description Logic Handbook: Theory,
      Implementation, Applications. Cambridge University Press (2003) Ch.
      1,2,4 (2007 II Edition).
      M. Schmidtand G. Smolka. Attributive concept descriptions with
      complements. Artificial Intelligence, 48(1) pp. 1–26
      Online material http : //dl.kr.org/courses.html
      N. Guarino and P. Giaretta. Ontologies and Knowledge Bases:
      Towards a Terminological Clarification. In Proc. of 2nd Int. Conf. on
      Building and Sharing Very Large-Scale Knowledge Bases (1995).

 d’Amato & Fanizzi   (MLSW)     Description Logics          March 3, 2020   28 / 28
You can also read