Title: Inconsistency Tolerance in SNePS
1Inconsistency Tolerance in SNePS
- Stuart C. Shapiro
- Department of Computer Science and Engineering,
- and Center for Cognitive Science
- University at Buffalo, The State University of
New York - 201 Bell Hall, Buffalo, NY 14260-2000
- shapiro_at_cse.buffalo.edu
- http//www.cse.buffalo.edu/shapiro/
2Acknowledgements
- João Martins
- Frances L. Johnson
- Bharat Bhushan
- The SNePS Research Group
- NSF, Instituto Nacional de Investigação
Cientifica, Rome Air Development Center, AFOSR,
U.S. Army CECOM
3Outline
- Introduction
- Some Rules of Inference
- I and Belief Revision
- Credibility Ordering and Automatic BR
- Reasoning in Different Contexts
- Default Reasoning by Preferential Ordering
- Summary
4SNePS
- A logic- and network-based
- Knowledge representation
- Reasoning
- And acting
- System Shapiro Group 02
- This talk will ignore network and acting aspects.
5Logic
- Based on R, the logic of relevant implication
- Anderson Belnap 75 Martins Shapiro 88,
Shapiro 92
6Supported wffs
- P ltorigin tag, origin setgt
Set of hypotheses From which P has been derived.
hyp hypothesis der derived
Origin set tracks relevance and ATMS assumptions.
7Outline
- Introduction
- Some Rules of Inference
- I and Belief Revision
- Credibility Ordering and Automatic BR
- Reasoning in Different Contexts
- Default Reasoning by Preferential Ordering
- Summary
8Rules of InferenceHypothesis
- Hyp P lthyp,Pgt
- whale(Willy) and free(Willy). wff3
free(Willy) and whale(Willy) lthyp,wff3gt
9Rules of InferenceE
- E From A and B ltt,sgt
- infer A ltder,sgt or B ltder,sgt
- wff3 free(Willy) and whale(Willy) lthyp,wff3gt
- free(Willy)? wff2 free(Willy) ltder,wff3gt
10Rules of InferenceandorE
- The os is the union of os's of parents
- wff3 free(Willy) and whale(Willy) lthyp,wff3gt
- wff6all(x)(andor(0,1)manatee(x), dolphin(x),
whale(x)) -
lthyp,wff6gt dolphin(Willy)? - wff9 dolphin(Willy) ltder,wff3,wff6gt
At most 1
11Rules of InferencegtE
- The origin set is the union of os's of parents.
- Since wff10 all(x)(whale(x) gt mammal(x))
lthyp,wff10gt - and wff1 whale(Willy)ltder,wff3gt
- I infer wff11 mammal(Willy) ltder,wff3,wff10gt
12Rules of InferencegtI
- origin set is diff of os's of parents.
- wff12 all(x)(orca(x) gt whale(x))
lthyp,wff12gt - orca(Keiko) gt mammal(Keiko)?
- Let me assume that wff13 orca(Keiko)
lthyp,wff13gt - Since wff12 all(x)(orca(x) gt whale(x))
lthyp,wff12gtand wff13 orca(Keiko)lthyp,wff13
gt - I infer whale(Keiko) ltder,wff12,wff13gt
13Rules of InferencegtI (contd)
- origin set is diff of os's of parents.
- Since wff10 all(x)(whale(x) gt mammal(x))
lthyp,wff10gt - and wff16 whale(Keiko) ltder,wff12,wff13gtI
infer mammal(Keiko) ltder,wff10,wff12,wff13gt - Since wff14 mammal(Keiko) ltder,wff10,wff12,wff1
3gtwas derived assuming - wff13 orca(Keiko) lthyp,wff13gtI
infer - wff15 orca(Keiko) gt mammal(Keiko)
ltder,wff10,wff12gt
14Outline
- Introduction
- Some Rules of Inference
- I and Belief Revision
- Credibility Ordering and Automatic BR
- Reasoning in Different Contexts
- Default Reasoning by Preferential Ordering
- Summary
15I and Belief Revision
- I triggered when a contradiction is derived.
- Proposition to be negated must be one of the
hypotheses underlying the contradiction. - Origin set is the rest of the hypotheses.
- SNeBR Martins Shapiro 88 involved in
choosing the culprit.
16Adding Inconsistent Hypotheses
- wff19 all(x)(whale(x) gt fish(x))lthyp,wff19gt
- wff20 all(x)(andor(0,1)mammal(x), fish(x))
- lthyp,wff20gt
- wff21 all(x)(fish(x) ltgt has(x,scales))
- lthyp,wff21gt
17Finding the Contradiction
- has(Willy, scales)?
- Since wff19 all(x)(whale(x) gt fish(x))
lthyp,wff19gt - and wff1 whale(Willy) ltder,wff3gtI infer
fish(Willy) ltder,wff3,wff19gt - Since wff21 all(x)(fish(x) ltgt has(x,scales))
-
lthyp,wff21gt - and wff23 fish(Willy) ltder,wff3,wff19gtI
infer has(Willy,scales) ltder,wff3,wff19,wff21gt
- Since wff20
- all(x)(andor(0,1)mammal(x), fish(x))
- lthyp,wff20gt
- and wff11 mammal(Willy) ltder,wff3,wff10gtI
infer it is not the case that wff23 fish(Willy)
18Manual Belief Revision
- A contradiction was detected
- within context
default-defaultct. The contradiction involves
the newly derived proposition wff24
fish(Willy) ltder,wff3,wff10,wff20gt and
the previously existing proposition wff23
fish(Willy) ltder,wff3,wff19gt You have
the following options 1. continue anyway,
knowing that a contradiction is derivable 2.
re-start the exact same run in a different
context which is not inconsistent 3.
drop the run altogether. (please type c, r
or d)gtlt r
19BR Advice
- In order to make the context consistent you must
delete at least one hypothesis from the set
listed below. - This set of hypotheses is known to be
inconsistent - 1 wff20 all(x)(andor(0,1)mammal(x),fish(x))
-
lthyp,wff20gt (1 dependent proposition
(wff24)) - 2 wff19 all(x)(whale(x) gt fish(x))
lthyp,wff19gt (2 dependent
propositions (wff23 wff22)) - 3 wff10 all(x)(whale(x) gt
mammal(x))lthyp,wff10gt (3 dependent
propositions (wff24 wff15 wff11)) - 4 wff3 free(Willy) and whale(Willy)
lthyp,wff3gt (8 dependent
propositions - (wff24 wff23 wff22 wff11 wff9 wff5
wff2 wff1)) - User
deletes 2 wff19.
20Willy has no Scales
- Since wff21 all(x)(fish(x) ltgt has(x,scales))
-
lthyp,wff21gt - and it is not the case that wff23 fish(Willy)
-
ltder,wff3,wff19gt - I infer it is not the case that
- wff22 has(Willy,scales) ltder,wff3,wff19,w
ff21gt - wff26 has(Willy,scales)ltder,wff3,wff10,wff20,w
ff21gt
21Final KB hyps positive ders
- list-asserted-wffs
- wff3 free(Willy) and whale(Willy)
lthyp,wff3gt - wff6 all(x)(andor(0,1)manatee(x),dolphin(x),whal
e(x)) -
lthyp,wff6gt - wff10 all(x)(whale(x) gt mammal(x))
lthyp,wff10gt - wff12 all(x)(orca(x) gt whale(x))
lthyp,wff12gt - wff20 all(x)(andor(0,1)mammal(x),fish(x))
lthyp,wff20gt - wff21 all(x)(fish(x) ltgt has(x,scales))
lthyp,wff21gt - wff1 whale(Willy)
ltder,wff3gt - wff2 free(Willy)
ltder,wff3gt - wff11 mammal(Willy)
ltder,wff3,wff10gt - wff15 orca(Keiko) gt mammal(Keiko)
ltder,wff10,wff12gt
22Final KB hyps negative ders
- list-asserted-wffs
- wff3 free(Willy) and whale(Willy)
lthyp,wff3gt - wff6 all(x)(andor(0,1)manatee(x),dolphin(x),whal
e(x)) -
lthyp,wff6gt - wff10 all(x)(whale(x) gt mammal(x))
lthyp,wff10gt - wff12 all(x)(orca(x) gt whale(x))
lthyp,wff12gt - wff20 all(x)(andor(0,1)mammal(x),fish(x))
lthyp,wff20gt - wff21 all(x)(fish(x) ltgt has(x,scales))
lthyp,wff21gt - wff9 dolphin(Willy)
ltder,wff3,wff10gt - wff24 fish(Willy)
ltder,wff3,wff10,wff20gt - wff25 (all(x)(whale(x) gt fish(x)))
ltext,wff3,wff10,wff20gt - wff26 has(Willy,scales)
ltder,wff3,wff10,wff20,wff21gt
23Summary
- Logic is paraconsistent
- Pltt1, h1 higt,
- Pltt2, h(i1) hngt
- hj
- When a contradiction is explicitly found, the
user is engaged in its resolution.
24Outline
- Introduction
- Some Rules of Inference
- I and Belief Revision
- Credibility Ordering and Automatic BR
- Reasoning in Different Contexts
- Default Reasoning by Preferential Ordering
- Summary
25Credibility Ordering and Automatic Belief
Revision
- Hypotheses may be given sources.
- Sources may be given relative credibility.
- Hypotheses inherit relative credibility from
sources. - Hypotheses may be given relative credibility
directly. (Not shown.) - SNeBR may use relative credibility to choose a
culprit by itself. Shapiro Johnson 00 - Not yet in released version.
26Contradictory Sources
- wff1 all(x)(andor(0,1)mammal(x),fish(x))
lthyp,wff1gt - wff2 all(x)(fish(x) ltgt has(x,scales))
lthyp,wff2gt - wff3 all(x)(orca(x) gt whale(x)) lthyp,wff3gt
- Source(Melville, all(x)(whale(x) gt fish(x)).).
- wff5 Source(Melville,all(x)(whale(x) gt
fish(x))) -
lthyp,wff5gt - Source(Darwin, all(x)(whale(x) gt mammal(x)).).
- wff7 Source(Darwin,all(x)(whale(x) gt
mammal(x))) -
lthyp,wff7gt Sgreater(Darwin, Melville).
wff8 Sgreater(Darwin,Melville) lthyp,wff8gt - wff11 free(Willy) and whale(Willy)
lthyp,wff11gt
Note Source Sgreater props are regular
object-language props.
27Finding the Contradiction
- has(Willy, scales)?Since wff4
all(x)(whale(x) gt fish(x)) lthyp,wff4gtand
wff9 whale(Willy)
ltder,wff11gtI infer fish(Willy)
ltder,wff4,wff11gt - Since wff2 all(x)(fish(x) ltgt has(x,scales))
lthyp,wff2gtand wff14 fish(Willy)
ltder,wff4,wff11gtI infer
has(Willy,scales)Since wff6 all(x)(whale(x)
gt mammal(x)) lthyp,wff6gtand wff9
whale(Willy) ltder,wff11gtI
infer mammal(Willy)Since wff1
all(x)(andor(0,1)mammal(x),fish(x)) -
lthyp,wff1gtand wff15 mammal(Willy)
ltder,wff6,wff11gtI infer it is not the case
that - wff14 fish(Willy) ltder,wff4,wff11gt
28Automatic BR
- A contradiction was detected within context
default-defaultct. - The contradiction involves the newly derived
proposition wff17 fish(Willy)
ltder,wff1,wff6,wff11gt - and the previously existing proposition
wff14 fish(Willy) ltder,wff4,wff11gt - The least believed hypothesis (wff4)
- The most common hypothesis (nil)
- The hypothesis supporting the fewest wffs (wff1)
- I removed the following belief wff4
all(x)(whale(x) gt fish(x)) lthyp,wff4gt - I no longer believe the following 2
propositions wff14 fish(Willy)
ltder,wff4,wff11gt wff13
has(Willy,scales) ltder,wff2,wff4,wff11gt
29Summary
- User may select automatic BR.
- Relative credibility is used.
- User is informed of lost beliefs.
30Outline
- Introduction
- Some Rules of Inference
- I and Belief Revision
- Credibility Ordering and Automatic BR
- Reasoning in Different Contexts
- Default Reasoning by Preferential Ordering
- Summary
31Reasoning in Different Contexts
- A context is a set of hypotheses and all
propositions derived from them. - Reasoning is performed within a context.
- A conclusion is available in every context that
is a superset of its origin set. Martins
Shapiro 83 - Contradictions across contexts are not noticed.
32Darwin Context
- set-context Darwin ()
- set-default-context Darwin
- wff1 all(x)(andor(0,1)mammal(x),fish(x))
-
lthyp,wff1gt - wff2 all(x)(fish(x) ltgt has(x,scales))
lthyp,wff2gt - wff3 all(x)(orca(x) gt whale(x))
lthyp,wff3gt - wff4 all(x)(whale(x) gt mammal(x))
lthyp,wff4gt - wff7 free(Willy) and whale(Willy)
lthyp,wff7gt
33Melville Context
- describe-context((assertions (wff8 wff7 wff4
wff3 wff2 wff1)) (restriction nil) (named
(science))) set-context Melville (wff8 wff7
wff3 wff2 wff1)((assertions (wff8 wff7 wff3 wff2
wff1)) (restriction nil) (named (melville)))
set-default-context Melville((assertions (wff8
wff7 wff3 wff2 wff1)) (restriction nil) (named
(melville))) all(x)(whale(x) gt fish(x)).
wff9 all(x)(whale(x) gt fish(x)) lthyp,wff9gt
34Melville Willy has scales
- has(Willy, scales)?Since wff9
all(x)(whale(x) gt fish(x))lthyp,wff9gtand
wff5 whale(Willy) ltder,wff7gtI infer
fish(Willy) ltder,wff7,wff9gt - Since wff2 all(x)(fish(x) ltgt has(x,scales))
-
lthyp,wff2gtand wff11 fish(Willy)
ltder,wff7,wff9gtI infer has(Willy,scales)
ltder,wff2,wff7,wff9gt - wff10 has(Willy,scales) ltder,wff2,wff7,wff9
gt
35Darwin No scales
- set-default-context Darwin
- has(Willy, scales)?Since wff4
all(x)(whale(x) gt mammal(x)) lthyp,wff4gtand
wff5 whale(Willy)
ltder,wff7gtI infer mammal(Willy)Since
wff1 all(x)(andor(0,1)mammal(x),fish(x)) -
lthyp,wff1gtand wff12 mammal(Willy)
ltder,wff4,wff7gtI infer it is not the case
that wff11 fish(Willy) - Since wff2 all(x)(fish(x) ltgt has(x,scales))
lthyp,wff2gtand it is not the case that
wff11 fish(Willy) -
ltder,wff7,wff9gtI infer it is not the case
that wff10 has(Willy,scales) - wff15 has(Willy,scales) ltder,wff1,wff2,wff4
,wff7gt
36Summary
- Contradictory information may be isolated in
different contexts. - Reasoning is performed in a single context.
- Results are available in other contexts.
37Outline
- Introduction
- Some Rules of Inference
- I and Belief Revision
- Credibility Ordering and Automatic BR
- Reasoning in Different Contexts
- Default Reasoning by Preferential Ordering
- Summary
38Default Reasoning by Preferential Ordering
- No special syntax for default rules.
- If P and P are derived
- but argument for one is undercut by an argument
for the other - dont believe the undercut conclusion.
- Unlike BR, believe the hypotheses, but not a
conclusion. - Grosof 97, Bhushan 03
39Preclusion Rules in SNePS
- P undercuts P if
- Precludes(P, P) or
- Every origin set of P has some hyp h such that
there is some hyp q in an origin set of P such
that Precludes(q, h). - Precludes(P, Q) is a proposition like any other.
- Not yet in released version.
40Animal Modes of Mobility
- wff1 all(x)(orca(x) gt whale(x))
- wff2 all(x)(whale(x) gt mammal(x))
- wff3 all(x)(deer(x) gt mammal(x))
- wff4 all(x)(tuna(x) gt fish(x))
- wff5 all(x)(canary(x) gt bird(x))
- wff6 all(x)(penguin(x) gt bird(x))
- wff7 all(x)(andor(0,1)swims(x),flies(x),runs(x)
) - wff8 all(x)(mammal(x) gt runs(x))
- wff9 all(x)(fish(x) gt swims(x))
- wff10 all(x)(bird(x) gt flies(x))
- wff11 all(x)(whale(x) gt swims(x))
- wff12 all(x)(penguin(x) gt swims(x))
41Using Preclusion for Exceptions
- wff13 Precludes(all(x)(whale(x) gt swims(x)),
- all(x)(mammal(x) gt runs(x)))
- wff14 Precludes(all(x)(penguin(x) gt swims(x)),
- all(x)(bird(x) gt flies(x)))
- wff15 orca(Willy)
- wff16 tuna(Charlie)
- wff17 deer(Bambi)
- wff18 canary(Tweety)
- wff19 penguin(Opus)
42Who Swims?(Contradictory Conclusions)
- swims(?x)?
- I infer swims(Opus)
- I infer swims(Charlie)
- I infer swims(Willy)
- I infer flies(Tweety)
- I infer it is not the case that swims(Tweety)
- I infer flies(Opus)
- I infer it is not the case that wff20
swims(Opus) - I infer runs(Willy)
- I infer it is not the case that wff24
swims(Willy) - I infer runs(Bambi)
- I infer it is not the case that swims(Bambi)
43Using Preclusionto Arbitrate Contradictions (1)
- Since wff13 Precludes(all(x)(whale(x) gt
swims(x)), - all(x)(mammal(x) gt
runs(x))) - and wff11 all(x)(whale(x) gt swims(x))
lthyp,wff11gt - holds within the BS defined by context
default-defaultct - Therefore wff34 swims(Willy)
- containing in its support
- wff8 all(x)(mammal(x) gt runs(x))
- is precluded by wff24 swims(Willy)
- that contains in its support
- wff11all(x)(whale(x) gt swims(x))
44Using Preclusionto Arbitrate Contradictions (2)
- Since wff14 Precludes(all(x)(penguin(x) gt
swims(x)), - all(x)(bird(x) gt
flies(x))) - and wff12 all(x)(penguin(x) gt swims(x))
- holds within the BS defined by context
default-defaultct - Therefore wff31 swims(Opus)
- containing in its support
- wff10all(x)(bird(x) gt flies(x))
- is precluded by wff20 swims(Opus)
- that contains in its support
- wff12 all(x)(penguin(x) gt
swims(x))
45The Swimmersand Non-Swimmers
- wff38 swims(Bambi) ltder,wff3,wff7,wff8,wff17
gt - wff28 swims(Tweety) ltder,wff5,wff7,wff10,wff18
gt - wff24 swims(Willy) ltder,wff1,wff11,wff15gt
- wff22 swims(Charlie) ltder,wff4,wff9,wff16gt
- wff20 swims(Opus) ltder,wff12,wff19gt
46Two-Level Preclusion
- wff1 all(x)(robin(x) gt bird(x))
- wff2 all(x)(kiwi(x) gt bird(x))
- wff3 all(x)(bird(x) gt flies(x))
- wff4 all(x)(bird(x) gt (flies(x)))
- wff5 all(x)(robin(x) gt flies(x))
- wff6 all(x)(kiwi(x) gt (flies(x)))
- Example from Delgrande Schaub 00
47Preferences
- wff7 Precludes(all(x)(robin(x) gt flies(x)),
- all(x)(bird(x) gt (flies(x))))
- wff8 Precludes(all(x)(kiwi(x) gt (flies(x))),
- all(x)(bird(x) gt flies(x)))
- wff12 (location(New Zealand))
- gt Precludes(all(x)(bird(x) gt flies(x)),
- all(x)(bird(x) gt
(flies(x)))) - wff14 location(New Zealand)
- gt Precludes(all(x)(bird(x) gt
(flies(x))), - all(x)(bird(x) gt flies(x)))
- wff10 location(New Zealand)
- wff15 Precludes(location(New Zealand),
- location(New Zealand))
48Who flies?
- wff16 robin(Robin)
- wff17 kiwi(Kenneth)
- wff18 bird(Betty)
- flies(?x)?
49Outside New Zealand
- wff24 flies(Kenneth)ltder,wff6,wff17gt,
- ltder,wff2,wff4,wff17gt,
- ltder,wff2,wff4,wff6,wff17
gt - wff21 flies(Robin) ltder,wff5,wff16gt,
- ltder,wff1,wff3,wff16gt
- wff19 flies(Betty) ltder,wff3,wff18gt
50Inside New Zealand
- location("New Zealand").
- wff9 location(New Zealand)
- flies(?x)?
- wff24 flies(Kenneth) ltder,wff6,wff17gt,
- ltder,wff2,wff4,wff17gt,
- ltder,wff2,wff4,wff6,wff17
gt - wff21 flies(Robin) ltder,wff5,wff16gt,
- ltder,wff1,wff3,wff16gt
- wff20 flies(Betty) ltder,wff4,wff18gt
51Summary
- Contradictions may be handled by DR instead of by
BR. - Hypotheses retained conclusion removed.
- DR uses preferential ordering among contradictory
conclusions or among supporting hypotheses. - Precludes forms object-language proposition that
may be reasoned with or reasoned about.
52Outline
- Introduction
- Some Rules of Inference
- I and Belief Revision
- Credibility Ordering and Automatic BR
- Reasoning in Different Contexts
- Default Reasoning by Preferential Ordering
- Summary
53SummaryInconsistency Tolerance in SNePS
- Inconsistency across contexts is harmless.
- Inconsistency about unrelated topic is harmless.
- Explicit contradiction may be resolved by user.
- Explicit contradiction may be resolved by system
using relative credibility of propositions or
sources. - Explicit contradiction may be resolved by system
using preferential ordering of conclusions or
hypotheses.
54For more information
- http//www.cse.buffalo.edu/sneps/
55References I
- A. R. Anderson, A. R. and N. D. Belnap, Jr.
(1975) Entailment Volume I (Princeton Princeton
University Press). - Â
- B. Bhushan (2003) Preferential Ordering of
Beliefs for Default Reasoning, M.S. Thesis,
Department of Computer Science and Engineering,
State University of New York at Buffalo, Buffalo,
NY. - Â
- J. P. Delgrande and T. Schaub (2000) The role of
default logic in knowledge representation. In J.
Minker, ed. Logic-Based Artificial Intelligence
(Boston Kluwer Academic Publishers) 107-126. - Â
- B. N. Grosof (1997) Courteous Logic Programs
Prioritized Conflict Handling for Rules, IBM
Research Report RC 20836, revised. - Â
56Â References II
- J. P. Martins and S. C. Shapiro (1983)
Reasoning in multiple belief spaces, Proc.
Eighth IJCAI (Los Altos, CA Morgan Kaufmann)
370-373. - Â
- J. P. Martins and S. C. Shapiro (1988) A
model for belief revision, Artificial
Intelligence 35, 25-79. - S. C. Shapiro (1992) Relevance logic in
computer science. In A. R. Anderson, N. D.
Belnap, Jr., M. Dunn, et al. Entailment Volume
II (Princeton Princeton University Press)
553-563. - Â
- S. C. Shapiro and The SNePS Implementation Group
(2002) SNePS 2.6 User's Manual, Department of
Computer Science and Engineering, University at
Buffalo, The State University of New York,
Buffalo, NY. - Â
- S. C. Shapiro and F. L. Johnson (2000) Automatic
belief revision in SNePS. In C. Baral M.
Truszczynski, eds., Proc. 8th International
Workshop on Non-Monotonic Reasoning.