Representation: Issues and Practice
Quantifier scoping and the order of quantifiers
Quantifiers and implications: some unlikely sentence forms
E.g., forall X, dorm(X) and building (X) is very strong statement!
dorm(garcia) and building(garcia), dorm(science hall) and building(science hall),dorm (president clinton), building (president clinton), dorm(water), building(water),....
How about: forall X, exist Y, person(X) and motherof(X,Y)?
E.g., exists X, chairof(X, nmsu-cs-dept) --> nameof(X, art) is a
very weak statement!
What could this allow you to infer? (skolem constants are unique; don't
unify)
Could it be false?
(not(chairof(science hall, nmsu-cs-dept) or nameof(science hall, art))
or
(not(chairof(president clinton, nmsu-cs-dept) or nameof(predident clinton,
art)) or
(not(chairof(water, nmsu-cs-dept) or nameof(water, art)) or ...
Getting the benefits of higher-order logic without the added complexity
One for each predicate:
Now, on to a specific representation scheme...
Conceives of the world as broken into snapshots, called situations
Similar to states in state-space search
Motivation: suppose a robot observes another moving from the den to the kitchen
First, he is at(robot1, den); then he is at(robot1,kitchen).
But robots can only
be at one place at one time...
Introduce times? He's at the den at 3, then at the kitchen at 4.
But what if we don't know when exactly he began the move and when he
accomplished it? We would have to use a vague description such
as ``before now''.
The knowledge base would be a mixture of vague and specific times, etc.,
making reasoning
complicated.
A situation is a more abstract unit with less committment to detail,allowing less complex representation of the basic things we need. Example:
holding(robot1,gold,result(grab,result(move,s0))).
How infer this? An effect axiom:
General form: If the preconditions of action A are satisfied in
situation S, then the effects of A would hold in the situation resulting
from doing A in S.
Example: forall A,P,S, at(A,P,S) and at(gold,P,S) -->
holding(A,gold,result(grab,S)).
We will illustrate general types of axioms with the Wumpus World used
in the text
To make the presentation feasible, we will solve a simpler problem
(Note: the set of axioms in the text illustrate
additional issues, but do not as a whole solve the problem)
Our problem: get from start to home, picking up the gold along the
way.
actions : just forward and grab.
Types of axioms: effect, frame, precondition, and closure
We saw effect axioms above:
LHS checks the preconditions.
RHS specifies the effects (ignore ``bestaction''
for now)
effect axiom: grab
all(S,L)(bestaction(grab,S) and at(gold,L,S) and at(me,L,S) => holding(me,gold,result(grab,S)))
The frame problem: what stays the same?
Frame axioms for our simple problem:
Frame axioms if there were many actions, including release (text, p. 206):
Closure axiom for at (we are not making the closed-world assumption,
so we provide the means to infer that something is not the case):
To focus inference, let's include a mechanism for choosing one
action per situation; bestaction(a,s) means that a is the action
to
perform in state s. Clearly, we want to prefer grab over forward.
all(S)(possible(grab,S) => bestaction(grab,S))
all(s)(possible(forward,S) and ~possible(grab,S) => bestaction(forward,S))
We will use precondition axioms, and precondition closure axioms, to enable the robot to infer which actions are possible and which are not;
precondition axioms
all(L1,L2,S)(at(me,L1,S) and toward(L1,L2) =>
possible(forward,S))
all(l,s)(at(me,L,S) and at(gold,L,S) =>
possible(grab,S))
closure axioms for preconditions
type facts
equality and inequality facts and axioms:
toward facts (the map)
initial state
goal
solution
S = result(forward, (result(grab, result(forward,s0))))