Скачать презентацию Planning Tuomas Sandholm Carnegie Mellon University Computer Science Скачать презентацию Planning Tuomas Sandholm Carnegie Mellon University Computer Science

03867132a265c160ebcd74c8f6746720.ppt

  • Количество слайдов: 22

Planning Tuomas Sandholm Carnegie Mellon University Computer Science Department Planning Tuomas Sandholm Carnegie Mellon University Computer Science Department

Planning Planning

Search-based problem solving Actions: generate successor states States: completely described & only used for Search-based problem solving Actions: generate successor states States: completely described & only used for successor generation, heuristic fn. Evaluation & goal testing. Goals: represented via goal test & heuristic fn. Black boxes: cannot look inside to select actions that might be useful Representation of plans: unbroken sequences of actions forward from initial states (or backward from goal state)

“Get a quart of milk, a bunch of bananas and a variable-speed cordless drill. “Get a quart of milk, a bunch of bananas and a variable-speed cordless drill. ”

From problem solving to planning 1. “Open up” the representation (usually FOL or a From problem solving to planning 1. “Open up” the representation (usually FOL or a subset) State & goals : set of sentences Actions: preconditions & effects Direct connections between state & actions used in choice of actions 2. Actions can be added to the plan whenever needed. (Also, actions operate on partial state descriptions) 3. Most part of the world are independent divide the plan into subplans. 4. Real world vs. puzzles

STRIPS language States are conjunctions of function-free ground literals At (home) ^ Have(milk) ^ STRIPS language States are conjunctions of function-free ground literals At (home) ^ Have(milk) ^ Have(bananas) ^ Have(drill) ^ … Often assumed that if a positive literal does not appear, then the negation can be assumed (aka. closed world assumption) Goals are also conjunctions of literals, but may contain variables At(x) ^ Sells(x, Milk)

STRIPS language … Actions At(here), Path(here, there) Go (there) At(there), At(here) Precondition: conjunctions of STRIPS language … Actions At(here), Path(here, there) Go (there) At(there), At(here) Precondition: conjunctions of positive literals operator effects: conjunction of literals “add list” & “delete list” An operator is applicable in states if there is some way to instantiate the variables in the operator s. t. every one of the preconditions is true.

Planning Situation-space planning Progression planning (forward from initial state) high branching factor Regression planning Planning Situation-space planning Progression planning (forward from initial state) high branching factor Regression planning (backward from goal) But often need to achieve a conjunction of goals. STRIPS was incomplete. Fixing it with an adequate method for handling conjunction goals is inefficient. Plan-space planning Refinement ops vs. modification ops add op … instantiate a var Impose ordering between 2 ops Partial vs. total order fully vs. partially instantiated plan Least-commitment planning

Start Initial State Goal State Start Left. Shoe. On Right. Shoe. On Finish (a) Start Initial State Goal State Start Left. Shoe. On Right. Shoe. On Finish (a) (b)

Partial Order Plan vs. Total Order Plan Partial Order Plan vs. Total Order Plan

Planning Plan has 1. Set of steps (one op per step) 2. Set of Planning Plan has 1. Set of steps (one op per step) 2. Set of binary ordering constraints on steps 3. A set of variable binding constraints 4. A set of causal links. Si Sj “Si achieves preconditions c for Sj” • The planner only considers adding steps that serve to achieve a precondition that has not yet been achieved. A solution is a complete consistent plan. Every precondition is achieved by some other step. No contradiction in the ordering or binding constraints

Planning E. g. Actions: Op(ACTION: Go(there), PRECOND: At(here), EFFECT: At(there) ^ At(here)) Op(ACTION: Buy(x), Planning E. g. Actions: Op(ACTION: Go(there), PRECOND: At(here), EFFECT: At(there) ^ At(here)) Op(ACTION: Buy(x), PRECOND: At(store) ^ Sells(store, x) EFFECT: Have(x)) Start At(Home) Sells(SM, Banana) Have(Drill) Have(Milk) Sells(SM, Milk) Sells(HWS, Drill) Have(Banana) At(Home) Finish

Planning Start At(s), Sells(s, Drill) Buy(Drill) At(s), Sells(s, Milk) Buy(Milk) Ordering constraints At(s), Sells(s, Planning Start At(s), Sells(s, Drill) Buy(Drill) At(s), Sells(s, Milk) Buy(Milk) Ordering constraints At(s), Sells(s, Bananas) Buy(Bananas) Have(Drill), Have(Milk), Have(Bananas), At(Home) Finish Causal links (protected) Have light arrows at every bold arrow. Start At(HWS), Sells(HWS, Drill) Buy(Drill) At(SM), Sells(SM, Milk) Buy(Milk) At(SM), Sells(SM, Bananas) Buy(Bananas) Have(Drill), Have(Milk), Have(Bananas), At(Home) Finish

Planning Start At(x) At (x) Go(HWS) At(HWS), Sells(HWS, Drill) Buy(Drill) Go(SM) At(SM), Sells(SM, Milk) Planning Start At(x) At (x) Go(HWS) At(HWS), Sells(HWS, Drill) Buy(Drill) Go(SM) At(SM), Sells(SM, Milk) Buy(Milk) At(SM), Sells(SM, Bananas) Buy(Bananas) Have(Drill), Have(Milk), Have(Bananas), At(Home) Finish

Planning Impasse must backtrack & make another choice Start At(Home) At (Home) Go(HWS) At(HWS), Planning Impasse must backtrack & make another choice Start At(Home) At (Home) Go(HWS) At(HWS), Sells(HWS, Drill) Buy(Drill) Go(SM) At(SM), Sells(SM, Milk) Buy(Milk) At(SM), Sells(SM, Bananas) Buy(Bananas) Have(Drill), Have(Milk), Have(Bananas), At(Home) Finish

How to identify a dead end? S 1 S 3 c c S 2 How to identify a dead end? S 1 S 3 c c S 2 S 1 S 3 c c S 2 c S 3 S 2 (a) S 1 c (b) Demotion (c) Promotion

Planning Start 1. Try to go from HWS to SM (i. e. a different Planning Start 1. Try to go from HWS to SM (i. e. a different way of achieving At(x)) At(Home) At (HWS) Go(SM) 2. by promotion At(HWS), Sells(HWS, Drill) Buy(Drill) At(SM), Sells(SM, Milk) At(SM), Sells(SM, Bananas) Buy(Milk) Buy(Bananas) Have(Drill), Have(Milk), Have(Bananas), At(Home) Finish At(SM) Go(Home)

Planning If 2 would try At(HWS) or At(Home), threats could not be resolved. Planning If 2 would try At(HWS) or At(Home), threats could not be resolved.

Do not backtrack on this Choose from existing steps or op pool. Presented as Do not backtrack on this Choose from existing steps or op pool. Presented as nondeterministic (choose and fail) POP is a regression planner. Sound & complete Assuming BFS or iterative deepening

Planning with partially instantiated operators Keep track of binding lists & unify right expressions Planning with partially instantiated operators Keep track of binding lists & unify right expressions at right time. Effect At(x) is a possible threat for condition At(Home) 1. Resolve now with an equality constraint, e. g. x=HWS 2. Resolve now with an inequality constraint, e. g. x HWS 3. Resolve later (only deal with it if it becomes a necessary threat) <- we will now give a POP algorithm for this Less commitment

Planning with partially instantiated operators … • New definition of achievement: • A step Planning with partially instantiated operators … • New definition of achievement: • A step Si achieves a precondition c of step Sj if – (1) Si < Sj and Si has an effect that necessarily unifies with c, and – (2) there is no step Sk such that Si < Sk< Sj in some linearization of the plan, and Sk has an effect that possibly unifies with c

Planning with partially instantiated operators … Can use bookkeeping to avoid going through this Planning with partially instantiated operators … Can use bookkeeping to avoid going through this triply nested loop every time. Sound & complete