Tải bản đầy đủ (.pdf) (42 trang)

Slide trí tuệ nhân tạo chapter7 3 structured knowledge

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (340.71 KB, 42 trang )

Structured Knowledge
Chapter 7


Logic Notations
Does logic represent well knowledge in structures?

2


Logic Notations
Frege’s Begriffsschrift (concept writing) - 1879:
assert P

P

not P

P

if P then Q

Q
P

for every x, P(x)

x

P(x)


3


Logic Notations
Frege’s Begriffsschrift (concept writing) - 1879:
“Every ball is red”

x

red(x)
ball(x)

“Some ball is red”

x

red(x)
ball(x)

4


Logic Notations
Algebraic notation - Peirce, 1883:
Universal quantifier: xPx
Existential quantifier: xPx

5



Logic Notations
Algebraic notation - Peirce, 1883:
“Every ball is red”: x(ballx —< redx)
“Some ball is red”: x(ballx • redx)

6


Logic Notations
Peano’s and later notation:
“Every ball is red”: (x)(ball(x)  red(x))
“Some ball is red”: (x)(ball(x)  red(x))

7


Logic Notations
Existential graphs - Peirce, 1897:
Existential quantifier: a link structure of bars, called line of
identity, represents 
Conjunction: the juxtaposition of two graphs represents 

Negation: an oval enclosure represents ~

8


Logic Notations
“If a farmer owns a donkey, then he beats it”:


farmer

owns

donkey

beats

9


Logic Notations
EG’s rules of inferences:
Erasure: in a positive context, any graph may be erased.

Insertion: in a negative context, any graph may be inserted.
Iteration: a copy of a graph may be written in the same
context or any nested context.

Deiteration: any graph may be erased if a copy of its occurs
in the same context or a containing context.
Double negation: two negations with nothing between them
may be erased or inserted.

10


Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s)) is valid


11


Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s)) is valid

p r

p q

q s

r s

12


Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s))
Erasure: in a positive context,
any graph may be erased.
Insertion: in a negative context,
any graph may be inserted.
Iteration: a copy of a graph may
be written in the same context or
any nested context.
Deiteration: any graph may be
erased if a copy of its occurs in
the same context or a containing
context.

Double negation: two negations
with nothing between them may
be erased or inserted.
13


Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s))
Erasure: in a positive context,
any graph may be erased.
Insertion: in a negative context,
any graph may be inserted.
Iteration: a copy of a graph may
be written in the same context or
any nested context.
Deiteration: any graph may be
erased if a copy of its occurs in
the same context or a containing
context.

p r

q s

Double negation: two negations
with nothing between them may
be erased or inserted.
14



Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s))
Erasure: in a positive context,
any graph may be erased.

p r

q s

Insertion: in a negative context,
any graph may be inserted.
Iteration: a copy of a graph may
be written in the same context or
any nested context.
Deiteration: any graph may be
erased if a copy of its occurs in
the same context or a containing
context.
Double negation: two negations
with nothing between them may
be erased or inserted.

p r

q s
p r
15


Existential Graphs

Prove: ((p  r)  (q  s))  ((p q)  (r s))
Erasure: in a positive context,
any graph may be erased.
Insertion: in a negative context,
any graph may be inserted.
Iteration: a copy of a graph may
be written in the same context or
any nested context.
Deiteration: any graph may be
erased if a copy of its occurs in
the same context or a containing
context.
Double negation: two negations
with nothing between them may
be erased or inserted.

p r

q s
p r

p r

q s
p q r
16


Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s))

Erasure: in a positive context,
any graph may be erased.
Insertion: in a negative context,
any graph may be inserted.
Iteration: a copy of a graph may
be written in the same context or
any nested context.

p r

q s
p q r

Deiteration: any graph may be
erased if a copy of its occurs in
the same context or a containing
context.

p r

Double negation: two negations
with nothing between them may
be erased or inserted.

pq

q s

r q s
17



Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s))
Erasure: in a positive context,
any graph may be erased.
Insertion: in a negative context,
any graph may be inserted.
Iteration: a copy of a graph may
be written in the same context or
any nested context.
Deiteration: any graph may be
erased if a copy of its occurs in
the same context or a containing
context.
Double negation: two negations
with nothing between them may
be erased or inserted.

p r

pq

q s

r q s
p r

p q


q s

r s
18


Existential Graphs
Prove: ((p  r)  (q  s))  ((p q)  (r s))
p r

p r

q s

q s
p r

p r

q s
p r

p q

q s

p r

q s


r s
pq

r q s

p q r
19


Existential Graphs


a-graphs: propositional logic



b-graphs: first-order logic



-graphs: high-order and modal logic

20


Semantic Nets
• Since the late 1950s dozens of different versions of
semantic networks have been proposed, with various
terminologies and notations.
• The main ideas:

For representing knowledge in structures
The meaning of a concept comes from the ways it is
connected to other concepts
Labelled nodes representing concepts are connected by
labelled arcs representing relations
21


Semantic Nets
Mammal
Is a
Person

White

uniform
color

has-part

Nose

instance

Kaka

team

Real


person(Kaka)  instance(Kaka, Person)

team(Kaka, Real)

22


Semantic Nets
John

Bill

height
H1

height
greater-than

H2

value

1.80

23


Semantic Nets
“John gives Mary a book”
Give


John

agent

g

instance
object

Book
instance
b

beneficiary
give(John, Mary, book)

Mary

24


Frames
• A vague paradigm - to organize knowledge in highlevel structures
• “A Framework for Representing Knowledge” - Minsky,
1974

• Knowledge is encoded in packets, called frames
(single frames in a film)
Frame name + slots

25


×