ontology reasoning v2008 - department of computer ... reasoning...1 ontology reasoning jon atle...

20
1 Ontology Reasoning Jon Atle Gulla Jon Atle Gulla Reasoning An ontology of this talk People Student Jie Bao present Description Logic DL reasoning Knowledge Representation Topic

Upload: lengoc

Post on 20-Apr-2018

218 views

Category:

Documents


0 download

TRANSCRIPT

1

Ontology Reasoning

Jon Atle Gulla

Jon Atle Gulla Reasoning

An ontology of this talk

People

Student

Jie Bao

present

Description Logic

DL reasoning

Knowledge Representation

Topic

2

Outline

What is Description Logics (DL)Semantics of DLBasic Tableau Algorithm

Description Logics

A formal logic-based knowledge representation language

“Description" about the world in terms of concepts(classes), roles (properties, relationships) and individuals(instances)

Decidable fragments of FOLWidely used in database (e.g., DL CLASSIC) and semantic web (e.g., OWL language)

3

A “Family” Knowledge Base

Person include Man(Male) and Woman(Female), A Man is not a WomanA Father is a Man who has ChildA Mother is a Woman who has ChildBoth Father and Mother are ParentGrandmother is a Mother of a ParentA Wife is a Woman and has a Husband( which as Man)A Mother Without Daughter is a Mother whose all Child(ren) are not Women

Jon Atle Gulla Reasoning

DL for Family Knowledge Base

4

Jon Atle Gulla Reasoning

DL Basics

Concepts (unary predicates/formulae with one free variable)E.g., Person, Father, Mother

Roles (binary predicates/formulae with two free variables)E.g., hasChild, hasHusband

Individual names (constants)E.g., Alice, Bob, Cindy

Subsumption (relations between concepts)E.g. Female ⊆ Person

Operators (for forming concepts and roles) And(Π) , Or(U), Not (¬)Universal qualifier (∀), Existent qualifier(∃)Number restiction : ≤, ≥, = Inverse role (-), transitive role (+), Role hierarchy

Jon Atle Gulla Reasoning

More for “Family” Ontology

(Inverse Role) hasParent = hasChild-

hasParent(Bob,Alice) -> hasChild(Alice, Bob)(Transitive Role)hasBrother

hasBrother(Bob,David), hasBrother(David, Mack) -> hasBrother(Bob,Mack)

(Role Hierarchy) hasMother ⊆ hasParenthasMother(Bob,Alice) -> hasParent(Bob, Alice)

HappyFather ⊆ Father Π ≥1 hasChild.Woman Π ≥1 hasChild.Man

5

DL Architecture

Knowledge Base

Tbox (schema)

Abox (data)

HappyFather ⊆ Person Π ≥1 hasChild.Woman Π ≥1 hasChild.Man

Happy-Father(Bob)

Infe

ren

ce S

yst

em

Inte

rface

DL RepresentivesALC: the smallest DL that is propositionally closed

Constructors include booleans (and, or, not), Restrictions on role successors

SHOIQ = OWL DLS=ALCR+: ALC with transitive roleH = role hierarchyO = nomial .e.g WeekEnd = {Saturday, Sunday}I = Inverse roleQ = qulified number restriction e.g. >=1 hasChild.Man

N = number restriction e.g. >=1 hasChild

6

Outline

What is Description Logic (DL)Semantics of DLBasic Tableau AlgorithmAdvanced Tableau Algorithm

InterpretationsDL Ontology: is a set of terms and their relationsInterpretation of a DL Ontology: A possible world ("model") thatmateralizes the ontology

People

Student

Jie Bao

present

Description Logic

DL reasoning

Knowledge Representation

Topic

Ontology:

Student ⊆ PeopleStudent ⊆ ∃Present.TopicKR ⊆ TopicDL ⊆ KR

Interpretation

7

Jon Atle Gulla Reasoning

DL Semantics

DL semantics defined by interpretations: I = (ΔI, .I), whereΔI is the domain (a non-empty set)

.I is an interpretation function that maps:Concept (class) name A -> subset AI of ΔI

Role (property) name R -> binary relation RI over ΔI

Individual name i -> iI element of ΔI

Interpretation function .I tells us how to interpret atomic concepts, properties and individuals.

The semantics of concept forming operators is given by extending the interpretation function in an obvious way.

Jon Atle Gulla Reasoning

DL Semantics: example

I = (ΔI, .I)

ΔI = {Jie_Bao, DL_Reasoning}PeopleI=StudentI={Jie_Bao}TopicI=KRI=DLI={DL_Reasoning}PresentI={(Jie_Bao, DL_Reasoning)}

An interpretation that satisifies all axioms in an DLontology is also called a model of the ontology.

8

Jon Atle Gulla ReasoningSource: Description Logics Tutorial, Ian Horrocks and Ulrike Sattler, ECAI-2002,

Jon Atle Gulla ReasoningSource: Description Logics Tutorial, Ian Horrocks and Ulrike Sattler, ECAI-2002,

9

Outline

What is Description Logic (DL)Semantics of DLBasic Tableau Algorithm

What is Reasoning?

"Machine Understanding"Find facts that are implicit in the ontology given explicitly stated facts

Find what you know, but you don't know you know it - yet.

ExampleA is father of B, B is father of C, then A is ancestor of C.D is mother of B, then D is female

10

Jon Atle Gulla Reasoning

Reasoning Tasks

Knowledge is correct (captures intuitions)C subsumes D w.r.t. K iff for every model I of K, CI µ DI

Knowledge is minimally redundant (no unintended synonyms)C is equivallent to D w.r.t. K iff for every model I of K, CI = DI

Knowledge is meaningful (classes can have instances)C is satisfiable w.r.t. K iff there exists some model I of K s.t. CI ≠ ∅;

Querying knowledgex is an instance of C w.r.t. K iff for every model I of K, xI ∈ CI

hx,yi is an instance of R w.r.t. K iff for, every model I of K, (xI,yI) ∈ RI

Knowledge base consistencyA KB K is consistent iff there exists some model I of K

Jon Atle Gulla Reasoning

Reasoning Tasks(2)

Many inference tasks can be reduced to subsumption reasoning

Subsumption can be reduced to satisfiability

11

Tableau Algorithm

Tableau Algorithm is the de facto standard reasoning algorithm used in DLBasic intuitions

Reduces a reasoning problem to concept satisfiability problemFinds an interpretation that satisfies concepts in question.The interpretation is incrementally constructed as a "Tableau"

Jon Atle Gulla Reasoning

Short Example

given: Wife⊆ Woman, Woman⊆ Personquestion: if Wife⊆ Person

Reasoning processTest if there is a individual that is a Woman but not a Person, i.e. test the satisfiability of concept C0=(WifeΠ¬Person)C0(x) -> Wife(x), (¬Person)(x)Wife(x)->Woman(x)Woman(x) ->Person(x)Conflict!C0 is unsatisfiable, therefore Wife⊆ Person is true with the given ontology.

12

Jon Atle Gulla Reasoning

General Process

Transform C into negation normal form(NNF), i.e. negation occurs only in front of concept names.Denote the transformed expression as C0, the algorithm starts with an ABox A0 = {C0(x0)}, and apply consistency-preserving transformation rules (tableaux expansion) to the ABox as far as possible.If one possible ABox is found, C0 is satisfiable.If not ABox is found under all search pathes, C0 is unsatisfiable.

Jon Atle Gulla Reasoning

Using Pellet for Reasoning in Protege

Pellet is one of the most common reasoning engines used for reasoning with Protege OWL models

13

Jon Atle Gulla Reasoning

Pellet Standard ReasoningStandard Reasoning Services

Pellet supports reasoning with the full expressivity of OWL-DL (SHOIN(D) in Description Logic jargon) and has been extended to support OWL 1.1 (the DL SROIQ(D)). OWL 1.1 adds the following language constructs to OWL DL: qualified cardinality restrictions complex subproperty axioms (between a property and a property chain) local reflexivity restrictions reflexive, irreflexive, symmetric, and anti-symmetric properties disjoint properties user-defined datatypes

Consistency checkingEnsures that an ontology does not contain any contradictory facts. The OWL Semantics standard provides the formal definition of ontology consistency used by Pellet.

Concept satisfiabilityDetermines whether it’s possible for a class to have any instances. If a class is unsatisfiable, then defining an instance of that class will cause the whole ontology to be inconsistent.

ClassificationComputes the subclass relations between every named class to create the complete class hierarchy. The class hierarchy can be used to answer queries such as getting all or only the direct subclasses of a class.

RealizationFinds the most specific classes that an individual belongs to; i.e., realization computes the direct types for each of the individuals. Realization can only be performed after classification since direct types are defined with respect to a class hierarchy. Using the classification hierarchy, it is also possible to get all the types for each individual.

Jon Atle Gulla Reasoning

Installing Pellet (1)Go to the Download section on the Pellet Web site. Download and unzip the Pellet ZIP file to a location of your choice. To follow is a screenshot of what the Pellet installation should look like on a Windows system after unzipping the file:

14

Jon Atle Gulla Reasoning

Installing Pellet (2)After installing Pellet, we recommend that you perform the following test to make sure that Pellet and the Protégé-OWL editor are communicating properly: Launch Pellet's DIG server. (Run the pellet-dig.bat batch file on Windows systems or the pellet-dig.sh file on Unix-like systems). To follow is a screenshot of the DIG server running on a Windows system:

Jon Atle Gulla Reasoning

Installing Pellet (3)Launch Protégé and open the "pizza.owl.pprj" file located in <your-protege-install-dir>/examples/pizza/. Open the OWL Preferences dialog by choosing OWL -> Preferences... from the menu bar. In the Reasoning section of the General tab, enter http://localhost:8081 as the Reasoner URL. To follow is a screenshot of the OWL Preferences dialog with the proper value entered into the Reasoner URL text area:

15

Jon Atle Gulla Reasoning

Installing Pellet (4)

Click Close to dismiss the OWL Preferences dialog. Choose OWL -> Check consistency... from the menu bar.

If Pellet has been properly installed and the Protégé-OWL editor properly configured, you will see a dialog with a title that includes the text "Connected to Pellet...", and Protégé-OWL will have performed a consistency check of the pizza ontology:

Jon Atle Gulla Reasoning

Conclusions

Web Ontology Languages (OWL) based on Description LogicOWL DL compatible with DL

Pellet reasoning engine

16

Jon Atle Gulla Reasoning

Additional Slides

The following slides are not part of the curriculum, but explains the tableaux method in some more detail...

Jon Atle Gulla Reasoning

NNF

17

Jon Atle Gulla Reasoning

Tableaux Expansion(Selected)

Clash

Jon Atle Gulla Reasoning

Termination Rules

An ABox is called complete if none of the expansion rules applies to it. An ABox is called consistent if no logic clash is found. If any complete and consistent ABox is found, the initial ABox A0 is satisfiableThe expansion terminates, either when finds a complete and consistent ABox, or try all search pathes ending with complete but inconsistent ABoxes.

18

Jon Atle Gulla Reasoning

Internalisation

Embed the TBox in the initial ABox conceptC⊆D is equivalent T⊆ ¬C U D (T is the "top" concept. It imeans ¬C U D is the super concept for ANY concepts)E.g.

Given ontology: Mother ⊆ Woman Π Parent, Woman ⊆ PersonQuery: Mother ⊆ PersonThe intitial ABox is : ¬Mother U(Woman Π Parent) Π (¬Woman U Person) Π (Mother Π ¬Person)

Jon Atle Gulla Reasoning

A Expansion Example

Search

19

Jon Atle Gulla Reasoning

Tree Model

Another explanation of tableaux algorithm is that it works on a finite completion tree whose

individuals in the tableau correspond to nodes and whose interpretation of roles is taken from the edge labels.

Jon Atle Gulla Reasoning

Requirments for Tab. Alg.

Similar tableaux expansions can be designed for more expressive DL languages. A tableau algorithm has to meet three requirements

Soundness: if a complete and clash-free ABox is found by the algorithm, the ABox must satisfies the initial concept C0.Completeness: if the initial concept C0 is satisfiable, the algorithm can always find an complete and clash-free ABoxTermination: the algorithm can terminate in finite steps with specific result.

20

ReferencesF. Baader, W. Nutt. Basic Description Logics. In the Description Logic Handbook, edited by F. Baader, D. Calvanese, D.L. McGuinness, D.Nardi, P.F. Patel-Schneider, Cambridge University Press, 2002, pages 47-100.Ian Horrocks and Ulrike Sattler. Description Logics Tutorial, ECAI-2002, Lyon, France, July 23rd, 2002.Ian Horrocks and Ulrike Sattler. A tableaux decision procedure for SHOIQ. In Proc. of the 19th Int. Joint Conf. on Artificial Intelligence (IJCAI 2005), 2005.I. Horrocks and U. Sattler. A description logic with transitive and inverse roles and role hierarchies. Journal of Logic and Computation, 9(3):385-410, 1999.