LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro...

19
L Logics for D Data and K Knowledge R Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia and Rui Zhang

Transcript of LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro...

Page 1: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

LLogics for DData and KKnowledge RRepresentation

Fausto Giunchiglia

Originally by Alessandro Agostini and Fausto GiunchigliaModified by Fausto Giunchiglia and Rui Zhang

Page 2: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Forehead

Staff

Scheduling

Reception times

Course website

Objective and

Outcomes

Prerequisites

Contents

Lectures

Handouts & Slides

Readings

Other resources

Exam policy & Grading

Page 3: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Outline: Introduction

The World

Model

Language

Theory

(Abstraction)Modeling

Realization

Representation

Interpretation

Data&

Knowledge

Page 4: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

What are we talking about?A Running example: a picture

The world?

A model?

A theory?

Page 5: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

The worldThe world is everything around us.One can only describe a part of the world with

certain degree of abstraction and approximation.

Page 6: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

ModelAn abstraction of a part of the world.Domain: the set of objects that are interested. Individual: single item in the domain.Set: group of individuals sharing common

propertiesRelation: set of pairs of individuals

Example: a model of the world from the picture

Page 7: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

LanguageEnglish

Natural Language: Italian, Chinese, … Java

Programming Language: C, Python, …Picture

Diagram: photo, ER, UML, …FOL

Logic: Modal Logic, DLs, …

Example: a model of the world from the picture

Page 8: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

TheoryTheory = Data + Knowledge (about the model)Data: A collection of facts from which

conclusions may be drawn. Useful irrelevant or redundant facts, which must

be processed to be meaningful. Used as a basis for reasoning, discussion or

calculation (Merriam-Webster).Knowledge: How to use a language to

represent and structure the facts. The sum of what is known. Knowledge is data in context, or organized data,

or also data in relationship.

Page 9: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Data in the Example English: “There are 3 girls playing in

the snow…”

Java:P1 = new

Person(Benedeta,red);

Diagram:the pictures on the right.

FOL:Person(Benedeta)

ClothColor(Benedata,Red)

Page 10: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Knowledge in the ExampleEnglish: “The figure with head, arms,

body, legs represents a person. The white stuff represents snow. The grew stuffs are mountains.

…”

Java:Class Person(String name,

String Benedeta,red);

Diagram:The picture on the above right.

The ER diagram on the right.

FOL:x,y Person(x)Person(y)

Play(x,y)

Light Pink

Yellow

Pink

Behind

Right

Right

Page 11: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Data vs. Knowledge in Different AspectsDataA factual output of

physical deviceBare facts Isolated factsDirect facts…

Observed

KnowledgeStatement a class is

related to anotherOrganized factsRelated factsProcessed facts…

Axioms + theorems (via inference/deduction/reasoning)

Page 12: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Syntax and SemanticsSyntax: the way a language is written.

Syntax is determined by a set of “rules” saying how to construct the expressions of the language from the set of atomic tokens (i.e., terms, characters, symbols).

The set of atomic token is called alphabet of symbols, or simply the alphabet).

Semantics: the way a language is interpreted. determines the meaning of syntactic constructs

(expressions), that is, the relationship between syntactic constructs and the elements of some universe of meanings (the model).

such relationship is called interpretation.

Page 13: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Example of Syntax and SemanticsSuppose we want to represent the fact that

Benedetta and Eleonora are near each other. By using English we may write (syntax):

Benedetta is near to Eleonora. By using a ‘symbolized’ English we may write

(syntax): near(B,E), or extensivelynear(Benedetta,Eleonora)

To fix the semantics of “near(B,E)” we need to fix an interpretation I of it, i.e., “near” by I means near (spatial relation)“B” by I means Benedetta (a girl) “E” by I means Eleonora (a girl)

Page 14: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Levels of Formalization

14

Logics

Diagrams

NLsProgramming

Languages

EnglishItalian

RussianHindi

...

ERUML...

SQL...

PLFOLDL...

Both Syntax and Semantics can be formal or informal.

Level1 Leveln

Page 15: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

LogicsWhat is a logic for?

Specification Automation

Why logic? Advantages of a logical framework:

Precise Syntax Precise Semantics Reasoning mechanisms

Which logic? Expressiveness ↔ Complexity

How to represent?

Syntax (Webster): the way in which

linguistic elements (as words) are put together to form constituents (as

phrases or clauses)

Semantics (Webster): the meaning or relationship of

meanings of a sign or set of signs especially connotative meaning

Page 16: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Efficiency VS. EffectivenessTask of the modeler: an appropriate

representationEffectiveness (with language: expressiveness)

What is it? Adequate to accomplish a purpose; producing the intended result.

How to measure it? completeness and correctness

Efficiency (with a language: complexity) What is it?

Performing in the best possible manner; satisfactory and economical to use.

How to measure it? time and space consumption

Trade-off

Page 17: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

What we refer to in this course

Languages Level of Formalization

Natural Language English, Italian, etc.

Diagrams ER, UML, etc.

Logic First Order Logic Modal Logic Description Logics …

Informal

Semi-formal

Formal

Focus of the course:How to use logics

Page 18: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

What is the message?

Expressions

Language

Knowledge

Data

Page 19: LDK R Logics for Data and Knowledge Representation Fausto Giunchiglia Originally by Alessandro Agostini and Fausto Giunchiglia Modified by Fausto Giunchiglia.

Exercises1. What is in the comic?2. What is the data?3. What is the

knowledge?4. Represent the comic

in English(natural Language)

5. List at least 3 schemas to represent the comic and try to formalize the contents with them.