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

Trí tuệ nhân tạo chapter9 uncertain krr

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 (567.05 KB, 72 trang )

Uncertain KR&R
Chapter 10


Outline
• Probability
• Bayesian networks
• Fuzzy logic

2


Probability
FOL fails for a domain due to:
Laziness: too much to list the complete set of rules, too hard to
use the enormous rules that result
Theoretical ignorance: there is no complete theory for the domain

Practical ignorance: have not or cannot run all necessary tests

3


Probability
• Probability = a degree of belief
• Probability comes from:
Frequentist: experiments and statistical assessment
Objectivist: real aspects of the universe

Subjectivist: a way of characterizing an agent’s beliefs


• Decision theory = probability theory + utility theory

4


Probability
Prior probability: probability in the absence of any other
information
P(Dice = 2) = 1/6
random variable: Dice

domain = <1, 2, 3, 4, 5, 6>
probability distribution: P(Dice) = <1/6, 1/6, 1/6, 1/6, 1/6, 1/6>

5


Probability
Conditional probability: probability in the presence of
some evidence
P(Dice = 2 | Dice is even) = 1/3
P(Dice = 2 | Dice is odd) = 0
P(A | B) = P(A  B)/P(B)
P(A  B) = P(A | B).P(B)

6


Probability
Example:

S = stiff neck
M = meningitis
P(S | M) = 0.5
P(M) = 1/50000
P(S) = 1/20
P(M | S) = P(S | M).P(M)/P(S) = 1/5000

7


Probability
Joint probability distributions:
X: <x1, …, xm>

Y: <y1, …, yn>

P(X = xi, Y = yj)

8


Probability
Axioms:
• 0  P(A)  1

• P(true) = 1 and P(false) = 0
• P(A  B) = P(A) + P(B) - P(A  B)

9



Probability
Derived properties:
• P(A) = 1 - P(A)

• P(U) = P(A1) + P(A2) + ... + P(An)
U = A1  A2  ...  An

collectively exhaustive

Ai  Aj = false

mutually exclusive

10


Probability
Bayes’ theorem:
P(Hi | E) = P(E | Hi).P(Hi)/iP(E | Hi).P(Hi)
Hi’s are collectively exhaustive & mutually exclusive

11


Probability
Problem: a full joint probability distribution P(X1, X2, ..., Xn)
is sufficient for computing any (conditional) probability on
Xi's, but the number of joint probabilities is exponential.


12


Probability
• Independence:
P(A  B) = P(A).P(B)

P(A) = P(A | B)

• Conditional independence:
P(A  B | E) = P(A | E).P(B | E)
P(A | E) = P(A | E  B)
Example:

P(Toothache | Cavity  Catch) = P(Toothache | Cavity)
P(Catch | Cavity  Toothache) = P(Catch | Cavity)
13


Probability
"In John's and Mary's house, an alarm is installed to
sound in case of burglary or earthquake. When the alarm
sounds, John and Mary may make a call for help or
rescue."

14


Probability
"In John's and Mary's house, an alarm is installed to

sound in case of burglary or earthquake. When the alarm
sounds, John and Mary may make a call for help or
rescue."
Q1: If earthquake happens, how likely will John make a
call?

15


Probability
"In John's and Mary's house, an alarm is installed to
sound in case of burglary or earthquake. When the alarm
sounds, John and Mary may make a call for help or
rescue."
Q1: If earthquake happens, how likely will John make a
call?
Q2: If the alarm sounds, how likely is the house
burglarized?

16


Bayesian Networks
• Pearl, J. (1982). Reverend Bayes on Inference
Engines: A Distributed Hierarchical Approach,

presented at the Second National Conference on Artificial
Intelligence (AAAI-82), Pittsburgh, Pennsylvania

17



Bayesian Networks
Burglary

P(B)

Earthquake

.001

Alarm

JohnCalls

A
T
F

P(J)
.90
.05

B

E

T
T
F

F

T
F
T
F

P(E)
.002

P(A)
.95
.94
.29
.001

MaryCalls

A
T
F

P(M)
.70
.01

18


Bayesian Networks

Syntax:
• A set of random variables makes up the nodes
• A set of directed links connects pairs of nodes
• Each node has a conditional probability table that quantifies the
effects of its parent nodes
• The graph has no directed cycles

yes

A

A

B

B

D

C

C

no

D
19


Bayesian Networks

Semantics:
• An ordering on the nodes: Xi is a predecessor of Xj  i < j

• P(X1, X2, …, Xn)
= P(Xn | Xn-1, …, X1).P(Xn-1 | Xn-2, …, X1). … .P(X2 | X1).P(X1)
= iP(Xi | Xi-1, …, X1) = iP(Xi | Parents(Xi))
P (Xi | Xi-1, …, X1) = P(Xi | Parents(Xi))

Parents(Xi)  {Xi-1, …, X1}

Each node is conditionally independent of its predecessors given its
parents
20


Bayesian Networks
Example:
P(J  M  A  B  E)
= P(J | A).P(M | A).P(A | B  E).P(B).P(E)
= 0.00062

E

B
A
J

M
21



Bayesian Networks
• Why Bayesian Networks?

22


Uncertain Question Answering
P(Query | Evidence) = ?
Diagnostic (from effects to causes): P(B | J)
Causal (from causes to effects): P(J | B)
Intercausal (between causes of a common effect): P(B | A, E)

Mixed: P(A | J, E), P(B | J, E)
E

B
A
J

M
23


Uncertain Question Answering
• The independence assumptions in a Bayesian Network
simplify computation of conditional probabilities on its
variables

24



Uncertain Question Answering
Q1: If earthquake happens, how likely will John make a
call?
Q2: If the alarm sounds, how likely is the house
burglarized?
Q3: If the alarm sounds, how likely both John and Mary
make calls?

25


×