As an example, here is a partial solution to Exercise 11.4 of R&N. I've done parts (a) and (b) as well as constructed a plan that fools the scientists (described in part c).
INITIAL STATE: At(Monkey,A) ^ At(Bananas,B) ^ At(Box,C) ^ Height(Monkey,Low) ^ Height(Box,Low) ^ Height(Bananas,High) ^ Pushable(Box) ^ Climbable(Box) ============================================== THE ACTIONS: Go(x,y) PC: At(Monkey,x) A: At(Monkey,y) D: At(Monkey,x) Push(b,x,y) PC: At(Monkey,x) ^ At(b,x) ^ Pushable(b) A: At(b,y) ^ At(Monkey,y) D: At(b,x) ^ At(Monkey,x) ClimbUp(b) PC: At(Monkey,x) ^ At(b,x) ^ Climbable(b) ^ Height(Monkey,Low) A: On(Monkey,b) ^ Height(Monkey,High) D: Height(Monkey,Low) Grasp(b) PC: Height(Monkey,h) ^ Height(b,h) ^ At(Monkey,x) ^ At(b,x) A: Have(Monkey,b) D: ClimbDown(b) PC: On(Monkey,b) ^ Height(Monkey,High) A: Height(Monkey,Low) D: On(Monkey,b) ^ Height(Monkey,High) UnGrasp(b) PC: Have(Monkey,b) A: D: Have(Monkey,b) ============================================== THE PLAN: Go(A,C) Push(Box,C,B) ClimbUp(Box) Grasp(Bananas) ClimbDown(Box) Push(Box,B,C) Go(C,A)
This is a fine answer. It might have some undesirable features. For example, the monkey can grasp things other than the bananas, namely the box or himself. (We could get rid of this by adding Graspable(Bananas) to the initial state and Graspable(b) to the PC of Grasp(b).) The monkey can also push a box while he has the bananas in his hand. This could be fixed by adding a HandsFree literal (compare it to Clear for the block's world) that should appear in the initial state, the PC and D lists of Grasp and the A list of UnGrasp.