Mathematical Logics Description Logic: Introduction Fausto - - PowerPoint PPT Presentation

mathematical logics description logic introduction
SMART_READER_LITE
LIVE PREVIEW

Mathematical Logics Description Logic: Introduction Fausto - - PowerPoint PPT Presentation

Mathematical Logics Description Logic: Introduction Fausto Giunchiglia and Mattia Fumagallli University of T rento *Originally by Luciano Serafini and Chiara Ghidini Modified by Fausto Giunchiglia and Mattia Fumagalli 1 Mental Model


slide-1
SLIDE 1

Mathematical Logics Description Logic: Introduction

1

Fausto Giunchiglia and Mattia Fumagallli

University of T rento *Originally by Luciano Serafini and Chiara Ghidini Modified by Fausto Giunchiglia and Mattia Fumagalli

slide-2
SLIDE 2

Mental Model

2/61

World Language L Theory T Domain D Model M Mental Model

SEMANTIC GAP

Causes Represents expresses grounds

slide-3
SLIDE 3

Logical Model

3/61

SEMANTIC GAP

World Language L Theory T Domain D Model M expresses Logical Model grounds Interpretation Entailment Causes Represents

slide-4
SLIDE 4

*Where G informally means “Monkey gets banana” *Where #3 stands for “Monkey actually gets Banana”.

Logical Model

4/61

Logical Model Model M Theory T Language L Domain D

L = “Monkey, Above, Banana, Near, Get, monkey#1, banana#2, tree, ⊓, ⊔, ¬, ⊑, ∃, ∀ …” TBOX = “MonkeyGetBanana ≡ Monkey ⊓ ∀Get.Banana” D: {monkey#1, banana#2} ABOX: “MonkeyGetBanana(monkey#1), Banana(banana#2)” T, A ⊨ ∀Get.Banana

World SEMANTIC GAP

/ Get

monkey#1 banana#2

MONKEY / Get--

banana#2 monkey#2

BANANA

slide-5
SLIDE 5

qThe syntax of ClassL is similar to PL qAlphabet of symbols Σ0

5

Σ0

Descriptive Logical ⊓, ⊔, ¬ Constants

  • ne proposition only

A, B, C … Variables

they can be substituted by any proposition or formula

P , Q, ψ …

NOTE: not only characters but also words (composed by several characters) like “monkey” are descriptive symbols

Language (Syntax)

slide-6
SLIDE 6

Overview

Description Logics (DLs) is a family of KR formalisms

TBox ABox Representation Reasoning

Alphabet of symbols with two new symbols w.r.t. ClassL:

∀R (value restriction) ∃R (existential quantification)

R are atomic role names

6

slide-7
SLIDE 7

Origins of Description Logics

Description Logics stem from early days knowledge representation formalisms (late ‘70s, early ‘80s): Semantic Networks: graph-based formalism, used to represent the meaning of sentences. Frame Systems: frames used to represent prototypical situations, antecedents of object-oriented formalisms. Problems: no clear semantics, reasoning not well understood. Description Logics (a.k.a. Concept Languages, T erminological Languages) developed starting in the mid ’80s, with the aim of providing semantics and inference techniques to knowledge representation system

7

slide-8
SLIDE 8

What are Description Logics today?

In the modern view, description logics are a family of logics that allow to speak about a domain composed of a set of generic (pointwise) objects,

  • rganized in classes, and related one another via various binary relations.

Abstractly, description logics allows to predicate about labeled directed graphs vertexes represents real world objects vertexes’ labels represents qualities of objects edges represents relations between (pairs of) objects vertexes’ labels represents the types of relations between objects. Every piece of world that can be abstractly represented in terms of a labeled directed graph is a good candidate for being formalized by a DL.

8

slide-9
SLIDE 9

What are Description Logics about?

Exercise Represent Metro lines in Milan in a labelled directed graph

9

slide-10
SLIDE 10

What are Description Logics about?

Exercise Represent some aspects of Facebook as a labelled directed graph

10

slide-11
SLIDE 11

What are Description Logics about?

Exercise Represent some aspects of human anatomy as a labelled directed graph

11

slide-12
SLIDE 12

What are Description Logics about?

Exercise Represent some aspects of everyday life as a labelled directed graph

12

slide-13
SLIDE 13

The everyday life example as a graph - intuition

Family of logics designed for knowledge representation Allow to encode general knowledge (as above) as well as specific properties about objects (with individuals, e.g., Mary).

13

slide-14
SLIDE 14

Ingredients of a Description Logic

A DL is characterized by: A description language: how to form concepts and roles Human ⊓ Male ⊓ ∃hasChild. T ⊓ ∀hasChild.(Doctor ⊔ Lawyer) A mechanism to specify knowledge about concepts and roles (i.e., a TBox) Father ≡ Human ⊓ Male ⊓ ∃hasChild.T T = HappyFather ⊑ Father ⊓ ∀hasChild.(Doctor ⊔ Lawyer) hasFather ⊑ hasParent A mechanism to specify properties of objects (i.e., an ABox) A = {HappyFather (john), hasChild (john, mary )} A set of inference services that allow to infer new properties on concepts, roles and

  • bjects, which are logical consequences of those explicitly asserted in the T
  • box and in

the A-box (T , A) ⊨ HappyFather ⊑ ∃hasChild.(Doctor ⊔ Lawyer ) Doctor ⊔ Lawyer (mary )

14

slide-15
SLIDE 15

Architecture of a Description Logic system

15

slide-16
SLIDE 16

Many description logics

16

slide-17
SLIDE 17

Syntax – ALC (AL with full concept negation)

qFormation rules: <Atomic> ::= A | B | ... | P | Q | ... | ⊥ | ⊤ <wff> ::= <Atomic> | ¬ <wff> | <wff> ⊓ <wff> | <wff> ⊔ <wff> | ∀R.C | ∃R.C

17

q¬ (Mother ⊓ Father) “it cannot be both a mother and father” qPerson ⊓ Female “persons that are female” qPerson ⊓ ∃hasChild. ⊤ “(all those) persons that have a child” qPerson ⊓ ∀hasChild. ⊥ “(all those) persons without a child” qPerson ⊓ ∀hasChild.Female “persons all of whose children are female”

slide-18
SLIDE 18

Syntax – ClassL as DL-language

qIntroduction of the ⊔ and elimination of roles ∀R.C and ∃R.C qFormation rules:

<Atomic> ::= A | B | ... | P | Q | ... | ⊥ | ⊤ <wff> ::= <Atomic> | ¬ <wff> | <wff> ⊓ <wff> | <wff> ⊔ <wff>

qThe new language is a description language without roles which is ClassL (also called propositional DL) NOTE: So far, we are considering DL without TBOX and ABox.

18

slide-19
SLIDE 19

Syntax - AL* Interpretation (∆,I)

qI(⊥) =∅ and I(⊤) = ∆ (full domain, “Universe”) qFor every concept name A of L, I(A) ⊆ ∆ qI(¬C) = ∆ \ I(C) qI(C ⊓ D) = I(C) ∩ I(D) qI(C ⊔ D) = I(C) ∪ I(D) qFor every role name R of L, I(R) ⊆ ∆ × ∆ qI(∀R.C) = {a ∈ ∆ | for all b, if (a,b)∈I(R) then b∈I(C)} qI(∃R.⊤) = {a ∈ ∆ | exists b s.t. (a,b) ∈ I(R)} qI(∃R.C) = {a ∈ ∆ | exists b s.t. (a,b) ∈ I(R), b ∈ I(C)} qI(≥nR) = {a ∈ ∆ | |{b | (a, b) ∈ I(R)}| ≥ n} qI(≤nR) = {a ∈ ∆ | |{b | (a, b) ∈ I(R)}| ≤ n}

19

The SAME as in ClassL

slide-20
SLIDE 20

qBy regarding propositions as classes, it is very convenient to use Venn diagrams qVenn diagrams are used to represent extensional semantics of propositions in analogy of how truth-tables are used to represent intentional semantics qVenn diagrams allow to compute a class valuation σ’s value in polynomial time qIn Venn diagrams we use intersecting circles to represent the extension of a proposition, in particular of each atomic proposition qThe key idea is to use Venn diagrams to symbolize the extension of a proposition P by the device of shading the region corresponding to the proposition, as to indicate that P has a meaning (i.e., the extension of P is not empty).

20

Semantics -Venn Diagrams and Class-Values

slide-21
SLIDE 21

21

Venn diagrams are built starting from a “main box” which is used to represent the Universe U.

P

σ(P) σ(⊥)

The falsehood symbol corresponds to the empty set.

Semantics -Venn Diagram of P, ⊥

slide-22
SLIDE 22

22

¬P corresponds to the complement of P w.r.t. the universe U.

P

The truth symbol corresponds to the universe U.

σ(¬P) σ(⊤)

Semantics -Venn Diagram of ¬P, ⊤

slide-23
SLIDE 23

23

The intersection of P and Q

23

P

The union of P and Q

Q P Q

σ(P ⊓ Q) σ(P ⊔ Q)

Semantics -Venn Diagram of P ⊓ Q and P ⊔ Q

slide-24
SLIDE 24

24

q Prove by Venn diagrams that σ(P) = σ(¬¬P) q Case σ(P) = ∅ ⊥

σ(P) σ(¬P)

σ(¬¬P)

How to use Venn diagrams - exercise 1

slide-25
SLIDE 25

25

25

q Prove by Venn diagrams that σ(P) = σ(¬¬P) q Case σ(P) = U

σ(P) σ(¬P) σ(¬¬P)

How to use Venn diagrams - exercise 1

slide-26
SLIDE 26

26

q Prove by Venn diagrams that σ(P) = σ(¬¬P) q Case σ(P) not empty and different from U

σ(P) σ(¬P) σ(¬¬P)

P P P

How to use Venn diagrams - exercise 1

slide-27
SLIDE 27

27

27

q Prove by Venn diagrams that σ(¬(A ⊔ B)) = σ(¬ A ⊓ ¬ B)

q Case σ(A) and σ(B) not empty (other cases as homework)

σ(¬(A ⊔ B)) σ(¬ A ⊓ ¬ B)

A B A B

σ(A ⊔ B) σ(¬ A)

A B A B

σ(¬ B)

A B

How to use Venn diagrams - exercise 2

slide-28
SLIDE 28

qLet σ be a class-valuation on language L, we define the truth- relation (or class-satisfaction relation) ⊨ and write σ ⊨ P (read: σ satisfies P) iff σ(P) ≠ ∅ qGiven a set of propositions Γ, we define σ ⊨ Γ iff σ ⊨ θ for all formulas θ ∈ Γ

28

Semantics - Truth Relation (Satisfaction Relation)

slide-29
SLIDE 29

qLet σ be a class valuation on language L. σ is a model of a proposition P (set of propositions Γ) iff σ satisfies P (Γ). qP (Γ) is class-satisfiable if there is a class valuation σ such that σ ⊨ P (σ ⊨ Γ).

29

Semantics - Model and Satisfiability

slide-30
SLIDE 30

qIs the formula P = ¬(A ⊓ B) satisfiable? In other words, there exist a σ that satisfies P? YES! In order to prove it we use Venn diagrams and it is enough to find one. σ is a model for P

30

A B

Semantics - Satisfiability, an example

slide-31
SLIDE 31

qLet σ be a class valuation on language L. qP is true under σ if P is satisfiable (σ ⊨ P) qP is valid if σ ⊨ P for all σ (notation: ⊨ P) qIn this case, P is called a tautology (always true) qNOTE: the notions of ‘true’ and ‘false’ are relative to some truth valuation.

31

Semantics - Truth, satisfiability and validity

slide-32
SLIDE 32
  • Is the formula P = A ⊔ ¬A valid?

In other words, is P true for all σ? YES! In order to prove it we use Venn diagrams, but we need to discuss all cases.

32

A

Case σ(A) empty: if σ(A) is empty, then σ(¬A) is the universe U Case σ(A) not empty: if σ(A) is not empty, σ(¬A) covers all the other elements of U

Semantics -Validity, an example

slide-33
SLIDE 33

Semantics - Interpretation of Existential Quantifier

qI(∃R.C) = {a ∈ ∆ | exists b s.t. (a,b) ∈ I(R), b ∈ I(C)} qThose a that have some value b in C with role R.

b I(C) a (a,b)∈I(R)

33

slide-34
SLIDE 34

Semantics - Interpretation of Value Restriction

qI(∀R.C) = {a ∈ ∆ | for all b, if (a,b)∈I(R) then b∈I(C)} qThose a that have only values b in C with role R.

b I(C) a if (a,b) ∈I(R) b' b'' if (a,b') ∈I(R) if (a,b'') ∈I(R)

34

slide-35
SLIDE 35

Semantics - Interpretation of Number Restriction

qI(≥nR) = {a∈∆ | |{b | (a, b) ∈ I(R)}|≥ n} qThose a that have relation R to at least n individuals.

∆ a bb' … |{b | (a, b) ∈ I(R)}| ≥ n

35

slide-36
SLIDE 36

Given a class-propositions P we want to reason about the following:

qModel checking Does σ satisfy P? (σ ⊨ P?) qSatisfiability Is there any σ such that σ ⊨ P? qUnsatisfiability Is it true that there are no σ satisfying P? qValidity Is P a tautology? (true for all σ)

36

Reasoning on Class-Propositions