Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Logistics z1 Handout yCopies of my slides zReading yRecent Advances in AI Planning, sections 1-2.

Similar presentations


Presentation on theme: "1 Logistics z1 Handout yCopies of my slides zReading yRecent Advances in AI Planning, sections 1-2."— Presentation transcript:

1 1 Logistics z1 Handout yCopies of my slides zReading yRecent Advances in AI Planning, sections 1-2

2 2 2 Approaches to Agent Control zReactive Control ySet of situation-action rules yE.g. x1) if dog-is-behind-me then run-forward x2)if food-is-near then eat zPlanning yReason about effect of combinations of actions y“Planning ahead” yAvoiding “painting oneself into a corner”

3 3 Different Planning Approaches zGenerative Planning yReason from first principles (knowledge of actions) to generate plan yRequires formal model of actions zCase-Based Planning yRetrieve old plan which worked for similar problem yRevise retrieved plan for this problem zSee also yPolicy Iteration / Markov-Decision Processes yReinforcement Learning

4 4 Generative Planning zInput yDescription of initial state of world (in some KR) yDescription of goal (in some KR) yDescription of available actions (in some KR) zOutput ySequence of actions

5 5 Input Representation zDescription of initial state of world ySet of propositions:  ((block a) (block b) (block c) (on-table a) (on-table b) (clear a) (clear b) (clear c) (arm-empty)) zDescription of goal (i.e. set of desired worlds) yLogical conjunction yAny world that satisfies the conjunction is a goal  (and (on a b) (on b c))) zDescription of available actions

6 6 Representing Actions STRIPS UWL ADL SADL TractableExpressive Situation Calculus

7 7 How Represent Actions? zSimplifying assumptions yAtomic time yAgent is omniscient (no sensing necessary). yAgent is sole cause of change yActions have deterministic effects zSTRIPS representation yWorld = set of true propositions yActions: xPrecondition: (conjunction of literals) xEffects (conjunction of literals) a a a north11 north12 W0W0 W2W2 W1W1

8 8 STRIPS Actions zAction =function from world-state  world-state zPrecondition says where function defined zEffects say how to change set of propositions a a north11 W0W0 W1W1 precond: (and (agent-at 1 1) (agent-facing north)) effect: (and (agent-at 1 2) (not (agent-at 1 1))) Note: strips doesn’t allow derived effects; you must be complete!

9 9 Action Schemata (:operator pick-up :parameters ((block ?ob1)) :precondition (and (clear ?ob1) (on-table ?ob1) (arm-empty)) :effect (and (not (clear ?ob1)) (not (on-table ?ob1)) (not (arm-empty)) (holding ?ob1))) zInstead of defining: pickup-A and pickup-B and … zDefine a schema: Note: strips doesn’t allow derived effects; you must be complete! }

10 10 Planning as Search zNodes zArcs zInitial State zGoal State World states Actions The state satisfying the complete description of the initial conds Any state satisfying the goal propositions

11 11 Forward-Chaining World-Space Search A C B C B A Initial State Goal State

12 12 Backward-Chaining Search Thru Space of Partial World-States D C B A E D C B A E D C B A E * * * zProblem: Many possible goal states are equally acceptable. zFrom which one does one search? A C B Initial State is completely defined D E

13 13 “Causal Link” Planning zNodes zArcs zInitial State zGoal State Partially specified plans Adding + deleting actions or constraints (e.g. <) to plan The empty plan (Actually two dummy actions…) A plan which when simulated achieves the goal Need efficient way to evaluate quality (percentage of preconditions satisfied) of partial plan … Hence causal link datastructures

14 14 Plan-Space Search pick-from-table(C) pick-from-table(B) pick-from-table(C) put-on(C,B) zHow represent plans? zHow test if plan is a solution?

15 15 Planning as Search 3 Graphplan zPhase 1 - Graph Expansion yNecessary (insufficient) conditions for plan existence yLocal consistency of plan-as-CSP zPhase 2 - Solution Extraction yVariables xaction execution at a time point yConstraints xgoals, subgoals achieved xno side-effects between actions

16 16 Planning Graph Proposition Init State Action Time 1 Proposition Time 1 Action Time 2

17 17 Constructing the planning graph… zInitial proposition layer yJust the initial conditions zAction layer i yIf all of an action’s preconds are in i-1 yThen add action to layer I zProposition layer i+1 yFor each action at layer i yAdd all its effects at layer i+1

18 18 Mutual Exclusion zActions A,B exclusive (at a level) if yA deletes B’s precond, or yB deletes A’s precond, or yA & B have inconsistent preconds zPropositions P,Q inconsistent (at a level) if yall ways to achieve P exclude all ways to achieve Q

19 19 Graphplan zCreate level 0 in planning graph zLoop yIf goal  contents of highest level (nonmutex) yThen search graph for solution xIf find a solution then return and terminate yElse Extend graph one more level A kind of double search: forward direction checks necessary (but insufficient) conditions for a solution,... Backward search verifies...

20 20 Searching for a Solution zFor each goal G at time t yFor each action A making G true @t xIf A isn’t mutex with a previously chosen action, select it xIf no actions work, backup to last G (breadth first search) zRecurse on preconditions of actions selected, t- 1 Proposition Init State Action Time 1 Proposition Time 1 Action Time 2

21 21 Dinner Date Initial Conditions: (:and (cleanHands) (quiet)) Goal: (:and (noGarbage) (dinner) (present)) Actions: (:operator carry :precondition :effect (:and (noGarbage) (:not (cleanHands))) (:operator dolly :precondition :effect (:and (noGarbage) (:not (quiet))) (:operator cook :precondition (cleanHands) :effect (dinner)) (:operator wrap :precondition (quiet) :effect (present))

22 22 Planning Graph noGarb cleanH quiet dinner present carry dolly cook wrap cleanH quiet 0 Prop 1 Action 2 Prop 3 Action 4 Prop

23 23 Are there any exclusions? noGarb cleanH quiet dinner present carry dolly cook wrap cleanH quiet 0 Prop 1 Action 2 Prop 3 Action 4 Prop

24 24 Do we have a solution? noGarb cleanH quiet dinner present carry dolly cook wrap cleanH quiet 0 Prop 1 Action 2 Prop 3 Action 4 Prop

25 25 Extend the Planning Graph noGarb cleanH quiet dinner present carry dolly cook wrap carry dolly cook wrap cleanH quiet noGarb cleanH quiet dinner present 0 Prop 1 Action 2 Prop 3 Action 4 Prop

26 26 One (of 4) possibilities noGarb cleanH quiet dinner present carry dolly cook wrap carry dolly cook wrap cleanH quiet noGarb cleanH quiet dinner present 0 Prop 1 Action 2 Prop 3 Action 4 Prop


Download ppt "1 Logistics z1 Handout yCopies of my slides zReading yRecent Advances in AI Planning, sections 1-2."

Similar presentations


Ads by Google