overview
play

Overview State Spaces & Partial-Order Planning What is - PDF document

12/5/18 Overview State Spaces & Partial-Order Planning What is planning? AI Class 22 (Ch. 10 through 10.4.4 ) Approaches to planning GPS / STRIPS Situation calculus formalism [revisited] Partial-order planning Material


  1. 12/5/18 Overview State Spaces & Partial-Order Planning • What is planning? AI Class 22 (Ch. 10 through 10.4.4 ) • Approaches to planning • GPS / STRIPS • Situation calculus formalism [revisited] • Partial-order planning Material from Dr. Marie desJardin, Some material adopted from notes by Andreas Geyer-Schulz and Chuck Dyer Planning Problem Planning Problem • put on right shoe • put on left shoe • put on pants • What is the planning problem? • What is the planning problem? • put on right sock • put on left sock • Find a sequence of actions that achieves a goal • Find a sequence of actions that achieves a goal • put on shirt when executed from an initial state . when executed from an initial state . • pants off • right shoe off • That is, given • That is, given • right sock off • A set of operators (possible actions) • A set of operators (possible actions) • right shoe off • An initial state description • An initial state description (etc) • A goal (description or conjunction of predicates) • A goal (description or conjunction of predicates) • pants on • Compute a sequence of operations: a plan . • Compute a sequence of operations: a plan . (etc) Typical Assumptions (1) Typical Assumptions • Atomic time : Each action is indivisible • Agent is the sole cause of change in the world • Can’t be interrupted halfway through putting on pants • Nobody else is putting on your socks • No concurrent actions allowed • Agent is omniscient: • Can’t put on socks at the same time • Has complete knowledge of the state of the world • Deterministic actions • Closed world assumption : • The result of actions are completely known – no uncertainty • Everything known-true about the world is in the state description • Anything not known-true is known-false 1

  2. 12/5/18 Blocks world Blocks World The blocks world consists of a table, set of blocks, and a • A micro-world robot gripper • Some domain constraints: Some domain constraints: • Only one block can be • Only one block on another block on another block • Any number of blocks on table • Hand can only hold one block • Any number of blocks can be on the table B Typical representation: ontable(a) handempty A C • The hand can only hold Meant to be a simple model! one block ontable(c) on(b,a) TABLE Try demo at: clear(b) clear(c) http://aispace.org/planning/ Typical BW planning problem Typical BW planning problem assertions atomic Initial state: Initial state: describing robot clear(a) clear(a) a state actions clear(b) clear(b) clear(c) clear(c) ontable(a) ontable(a) Plan: ontable(b) A C B ontable(b) A C B pickup(b) ontable(c) ontable(c) stack(b,c) handempty handempty pickup(a) Goal state: Goal state: stack(a,b) on(b,c) A on(b,c) A on(a,b) on(a,b) B B ontable(c) ontable(c) C C Major Approaches Planning vs. problem solving • GPS / STRIPS • Planning vs. problem solving: can often solve similar problems • Planning is more powerful and efficient because of the • Situation calculus representations and methods used • Partial order planning • States, goals, and actions are decomposed into sets of sentences (usually in first-order logic) • Hierarchical decomposition (HTN planning) • Search often proceeds through plan space rather than state • Planning with constraints (SATplan, Graphplan) space (though there are also state-space planners) • Sub-goals can be planned independently, reducing the • Reactive planning complexity of the planning problem 2

  3. 12/5/18 Yet Another BW planning problem Another BW planning problem Plan: Initial state: Initial state: unstack(c,b) clear(a) clear(c) A plan putdown(c) clear(b) ontable(a) pickup(a) unstack(b,a) clear(c) stack(a,b) on(b,a) putdown(b) ontable(a) unstack(a,b) backtracking { putdown(b) on(c,b) ontable(b) A C B A C B putdown(a) pickup(a) ontable(c) handempty pickup(b) stack(a,b) handempty stack(b,c) unstack(a,b) Goal: pickup(a) putdown(a) Goal: on(a,b) stack(a,b) pickup(b) on(a,b) A A on(b,c) stack(b,c) on(b,c) B B pickup(a) ontable(c) ontable(c) C C stack(a,b) “Get a quart of milk, a bunch of bananas Planning as Search and a variable-speed cordless drill.” Slightly more complex KB: • Can think of planning as a search problem • Actions: generate successor states • States: completely described & only used for successor generation, heuristic fn. evaluation & goal testing • Goals: represented as a goal test and using a heuristic function • Plan representation: unbroken sequences of actions forward from initial states or backward from goal state Treating planning as a search problem isn’t very efficient! General Problem Solver Situation Calculus Planning • The General Problem Solver (GPS) system • Intuition: Represent the planning problem using • An early planner (Newell, Shaw, and Simon) first-order logic • Generate actions that reduce difference between current state • Situation calculus lets us reason about changes in the world and goal state • Use theorem proving to show (“prove”) that a sequence of actions will lead to a desired result, when applied to a world • Uses Means-Ends Analysis state / situation • Compare what is given or known with what is desired • Select a reasonable thing to do next • Use a table of differences to identify procedures to reduce differences • GPS is a state space planner • Operates on state space problems specified by an initial state, some goal states, and a set of operations 3

  4. 12/5/18 Situation Calculus Planning, cont. Situation Calculus Planning, cont. • Initial state : • Initial state : a logical sentence about (situation) S 0 At(Home, S 0 ) ∧ ¬ Have(Milk, S 0 ) ∧ ¬ Have(Bananas, S 0 ) ∧ ¬ Have(Drill, S 0 ) • Goal state: usually a conjunction of logical sentences • Goal state : ( ∃ s) At(Home,s) ∧ Have(Milk,s) ∧ Have(Bananas,s) ∧ Have(Drill,s) • Operators : descriptions of how the world changes as a • Operators: result of the agent’s actions: ∀ (a,s) Have(Milk,Result(a,s)) ⇔ � • Result( a,s ) names the situation resulting from executing ((a=Buy(Milk) ∧ At(Grocery,s)) ∨ (Have(Milk, s) ∧ a ≠ Drop(Milk))) action a in situation s . • Result(a,s) : situation after executing action a in situation s • Action sequences are also useful: ( ∀ s) Result’([ ],s) = s • Result’(l,s) : result of executing list of actions l starting in s ( ∀ a,p,s) Result’([a|p]s) = Result'(p,Result(a,s)) p=plan Situation Calculus, cont. Situation Calculus: Blocks World • Example situation calculus rule for blocks world: • Solution: a plan that when applied to the initial state • clear(X, Result(A,S)) ↔ � gives a situation satisfying the goal query : [clear(X, S) ∧ � ( ¬ (A=Stack(Y,X) ∨ A=Pickup(X)) � At(Home, Result'(p,S 0 )) ∨ (A=Stack(Y,X) ∧ ¬ (holding(Y,S)) � ∧ Have(Milk, Result'(p,S 0 )) ∨ (A=Pickup(X) ∧ ¬ (handempty(S) ∧ ontable(X,S) ∧ clear(X,S))))] � ∨ [A=Stack(X,Y) ∧ holding(X,S) ∧ clear(Y,S)] � ∧ Have(Bananas, Result'(p,S 0 )) ∨ [A=Unstack(Y,X) ∧ on(Y,X,S) ∧ clear(Y,S) ∧ handempty(S)] � ∧ Have(Drill, Result'(p,S 0 )) ∨ [A=Putdown(X) ∧ holding(X,S)] • Thus we would expect a plan (i.e., variable assignment • English translation: a block is clear if through unification) such as: (a) in the previous state it was clear AND we didn’t pick it up or stack something on it successfully, or p = [Go(Grocery), Buy(Milk), Buy(Bananas), Go(HardwareStore), � Wow. (b) we stacked it on something else successfully, or Buy(Drill), Go(Home)] (c) something was on it that we unstacked successfully, or (d) we were holding it and we put it down. Situation Calculus Planning: Analysis Basic Representations for Planning • Classic approach first used in the STRIPS planner circa 1970 • Fine in theory, but: • Problem solving (search) is exponential in the worst case • States represented as conjunction of ground literals • at(Home) ∧ ¬ have(Milk) ∧ ¬ have(bananas) ... • Resolution theorem proving only finds a proof (plan), not necessarily a good plan • Goals are conjunctions of literals, but may have variables* • at(?x) ∧ have(Milk) ∧ have(bananas) ... • So what can we do? • Don’t need to fully specify state • Restrict the language • Un-specified: either don’t-care or assumed-false • Blocks world is already pretty small… • Represent many cases in small storage • Use a special-purpose planner rather than general • Often only represent changes in state rather than entire situation theorem prover • Unlike theorem prover, not finding whether the goal is true , but whether there is a sequence of actions to attain it *generally assume ∃ 4

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend