Planning. Outline. Planning. Planning

Size: px
Start display at page:

Download "Planning. Outline. Planning. Planning"

Transcription

1 Planning Outline Jacky Baltes University of Manitoba urses/comp_4190-artificial-intelligence Reasoning about actions STRIPS representation Planning vs search Means-ends analysis Partial order planning Case-based planning Planning and execution Planning Planning Definition (Webster s) Method or procedure, esp. conceived beforehand, by which something is to be done goal oriented Most of human behavior is goal oriented General vs. special purpose planners Early research area in AI (GPS, 1969) You've seen planning problems many times e.g. the water-jugs problem way back in 319 A plan is a sequence of operators that, when applied or carried out, transforms a known world/state into some desired world/state In the real worlds, plans may be more or less detailed (e.g. a computer program vs. a blueprint vs. a recipe)

2 The Planning Problem Planning Representation Formally a planning algorithm has three inputs: A description of the world in some formal language, A description of the agent s goal in some formal language, and A description of the possible actions that can be performed. The planner s output is a sequence of actions which when executed in any world satisfying the initial state description will achieve the goal Synthesis problem: classification, synthesis, learning Consider the problem of being at home and deciding you needed a jug of milk, a bunch of bananas, and a drill What for? We can easily specify an initial state: at home with none of these objects Goal: at home with all of these objects Operations: everything the agent could do A Planner would take a formal description of these (e.g. in FOL) to allow the planner to make direct connections between states and actions Problems? Planning as Search Planning Representation Huge branching factor too many actions, too many states to consider more on this in a minute! Before we can even talk about using search, however How do we describe the world? e.g., this classroom,... How do we describe the goals? I want to be rich? How do we describe operators? Pick up the chair Changes in the world

3 Representing Change Approaches to Managing Change Our planning agent must have an internal model of how the world works, and how it's changes will affect it All the operations an agent can follow involve change across time e.g. buying bananas means having them, and having less money How can we represent this formally? Have a Non-Monotonic Knowledge base - that is, be able to delete facts as well as add them so as a result of a buying action, for example, we add having bananas, and retract having money The problem with this is that we need to reason about what was, and what will be too A strict non-monotonic knowledge base can't do this: we have just one single snapshot Representing States Explicitly Situation Calculus An alternative is to have many snapshots, not just one i.e. add info to each primitive: Have(Bananas,S5) I have bananas in state S5 One of the most common, and simplest, ways of managing change is the Situation Calculus Section 10.3 in text World is a sequence of situations Each is a snapshot frozen in time Each step we take causes a new snapshot We can have logical predicates that reason across situations (diachronic rules) e.g. forall X,S present(x,s) ^ portable(x) implies holding(x,result(grab,s)) Result is a function that generates a state (the result of the Grab action)

4 Situation Calculus State during execution of an action is unknown No multiple agents No duration of actions Another way: Fluents Reify predicates: loc, clear (holds clear(b) S) & (holds clear(l1) S) -> (holds loc(b L1) result(move(b L1) S) loc and clear are called fluents (functions that depend on state) Change in Situation Calculus More Representation Problems These are Effect Axioms: show what happens when we do something There is a representation problem associated with these: in any very complex world, we don't have the ability to detail every ramification of an action e.g. put an apple on the table e.g. put 5 tons of apples on the table ramification problem As often as not we care what is preserved as much as what is changed e.g. grab(bananas) means they're still edible, or that if we are holding something and we don't drop it, we're still holding it In fact, what doesn't change as the result of an action most stuff! A Frame Axiom is an axiom that we add to ensure that our representation states that something remains true after we perform some action

5 Frame Axioms Blocksworld These can get arbitrarily "silly" forall a,s currency(canada,$,s) ^ (A=grab) implies (currency(canada,$,(result(a,s))) We technically have an infinite number of such axioms in any real logical system The Frame Problem Several blocks on a table All blocks have the same size Robot arm can lift one block Table is infinitely large as opposed to qualification problem: Infinite exceptions to any clause e.g when grabbing bananas they stay edible unless we grab too hard, have poison on our hands, wear spiked gloves, Blocksworld Blocksworld General method for describing domains Effects of actions are dependent on the situation Predicate logic Add situation S (is-on B C) (move B L1 S1) -> (is-at B L1 next(s1)) (is-at B L1) How to describe actions? Use results of actions (loc B L1 result(move(b L1),S)) Predicates: move(b L1) -> (is-at B L1) move and result are functions But: move(b L1) & move(b L2) -> (is-at B L1) & (is-at B L2)

6 Frame/Ramification/Quantification Problem Frame problem: what does not change pickup dog How do we know that... did not change Ramification problem: what changes Put apple on table Put ton apple on table Qualification problem: list all preconditions have key ^ has_gas car --> car running unless... Better Planning Representations Recall looking at logic in 319 It's nice in that it's general, but it isn't always easy to say the things you want in a way that's simple to represent and easy to work with for a specific task So, for example, we move to rule-based systems for particular kinds of reasoning Planning is similar, we can develop more streamlined representations STRIPS Representation Representation for states and goals Reduced language Actions are represented as Preconditions: Effects conjunction of positive/negative literals conjunction of positive/negative literals Implemented as add and del lists In the STRIPS language, states are represented by conjunctions of function-free ground literals, that is, predicates applied to constant symbols, possibly negated. For example, At(Home)^ Have(Milk)^ Have(Bananas)^ Have(Drill)^. Goals are also described by conjunctions of literals. For example, At(Home)^Have(Milk)^ Have(Bananas)^ Have(Drill) Goals can also contain variables. For example, the goal of being at a store that sells milk would be represented as At($X) ^ Sells($X,Milk) No states associated with actions. Actions create new states from initial state

7 STRIPS representation Blocksworld Operators STRIPS assumption: Assume only predicates mentioned in the effects of operators are changed Closed world assumption: State contains all true predicates only Example: (is-on B table) (holding C) ~ (arm-empty) How many operators in the blocksworld domain? How do we represent them? Operators in the blocksworld Operators in the blocksworld Predicates: is-on, clear, arm-empty, holding Pickup Precondition: (clear $X) & (arm-empty) Effects: add (holding $X) Pickup ($X) Prec.: (is-on $X table) (arm-empty) (clear $X) Eff.: add (holding$x) UnStack($X $Y) Prec: (is-on $X $Y) (clear $X) (arm-empty) Eff: add (holding $X) del (arm-empty) Note that we have to add that whatever X was on is now clear but did we pick X up from the table, or from another block? Operator variables must be bound in order to use the operator or know if it is applicable in a specific case del (arm-empty) Putdown ($X) Prec.: (holding $X) Eff.: add (is-on $X table) add (arm-empty) del (holding $X) add (clear $Y) del (is-on $X $Y) del(arm-empty) Stack ($X $Y) Prec: (holding $X) (clear $Y) Eff:...

8 Blocksworld Operators Situation Space Planning Need four instead of two operators. Why? -(clear table) Why not add a rule (conditional effect) Stack($X, $Y) :- Effects: if ( $Y!= table ) del (clear $Y) No way to reason backwards from the action We could use this planning representation to deal with the blocks world problem Take the initial state and apply operators one at a time until we hit the goal state, using any standard search method This would be a situation space planner: it searches through the space of possible situations (graph node:state; arcs:operators) It would also be a Progression Planner because it reasons purely in a forward direction Search through World Space Search vs Planning The simplest way to build a planner is to cast the planning problem as search through the space of world states. Each node in the graph denotes a state of the world, and arcs connect worlds that can be reached by executing a single action. We would call it a situation space planner because it searches through the space of possible situations. There are two types of planners: Progression Planner: it searches forward from the initial situation to the goal situation. Forward chaining. Regression Planner: it searches backward from the goal situation to the initial situation. Backward chaining. Goal: get milk, bananas, and cordless drill Standard search techniques: DFS, BFS,...

9 Forward chaining From the initial state Apply operators whose preconditions are satisfied Generate new state Example: Buying coffee, cake, and ice-cream Start at home Actions with no bearing on the solution Forward Chaining Apply all possible operators to the current state Adventure game mentality Computational explosion 1st Insight: Goal: pass COMP_4190 State:... Operator: drink beer How does this accomplish the goal? Progression/Regression Planning Progression/Regression Planning The problem with progression planning is the high branching factor We can reduce it by starting at the goal: Regression planning In general there will be fewer ways to arrive at a goal immediately than places to go from an initial state Like other forms of backward reasoning, regression planning is naturally recursive: we have an action that will lead to a goal, and then plan to get to a state where that action can be achieved We have a stack of goals to achieve at any time (since solving one may only partially achieve the goal that it was ultimately adopted for, and so on up the stack) Whether we are progression or regression planning, one important technique used in planning is to reason about difference between the initial and goal states and reduce them: Means-Ends Analysis

10 Summary: Search in planners Planning can be represented as a search problem Simplest Nodes (World-states) Links: Application of an operator Planning can also be interpreted as a classification problem (reactive planning, situated activity) Summary: Representations for actions Our STRIPS operators consist of three components: the action description is what an agent actually returns to the environment in order to do something. the precondition is a conjunction of atoms (positive literals) that says what must be true before the operator can be applied. the effect of an operator is a conjunction of literals (positive or negative) that describes how the situation changes when the operator is applied. Here s an example for the operator for going from one place to another: Op(Action:Go(there), Precond:At(here)^Path(here, there), Effect:At(there)^ At(here)) Means ends analysis GPS (69) Ernst and Newell Based on analysis of human problem solving: Logic puzzles The idea is to compare the current state to the goal description and to compute the differences Pick a difference and an operator that reduces this difference Means ends analysis This operator may not be applicable (yet!) Example: B C Goal: (holding C) & (is-on B A) & (is-on A table)

11 Initial state: (is-on B C) (is-on A table) (arm-empty) Goal: (holding C) Differences(2) (holding C) (is-on B A) (holding C) Operators Pickup(C) UnStack(A C) UnStack(B C) UnStack(C C) Which one to choose? Pickup(C) Prec: clear(c) After 1 st Iteration We ve got something that will reduce one of our difference, but the goal still has other things that have to be achieved I now need to reason about how to reduce the differences between our initial state and that necessary to precede the pickup [clear(c)] subgoaling After nth iteration Eventually we have a sequence of actions that goes back to the initial state each of these may have other preconditions that have yet to be satisfied, but we have regressed back to the beginning based on minimizing differences we'd now need to minimize the other differences between the state preceding action 2 After nth iteration That is, our current state for reducing differences becomes the state preceding operator 2, and we examine the other differences between that and what 2 needs to achieve its effects i.e. our current state moves forward through the states created by the actions we've adopted

12 Problems We may get repeated states/goals as we proceed this way For example, we may need to provide condition A, adopt an action to do that, and then as planning ensues adopt an earlier action that undoes A as one of its consequences Essentially an infinite loop problem Means ends analysis Problem: State loops -> check for repeated state Goal loops: check for repeated goals Plan: Apply or Add operator Linear planning Sussman Anomaly (clear C) as new goal specification Assumption: Subgoals are independent Linear planner can not solve: Linear planning uses a stack of goals: only the unsatisfied preconditions of the recently added operator are used Call the planner recursively (is-on A B) & (is-on B C)

13 Non-linear planning Add unsatisfied preconditions and all open goals to the new goal descriptions Increases search space Can solve the Sussman anomaly Algorithm: Extended MEA (Prodigy) Terminate if the goal is satisfied in the current state Compute set of pending goals G and set of applicable operators A A goal is pending if it is an unsatisfied precondition in the current state of an operator in the tail An operator is applicable when all its preconditions are satisfied Choose a goal g from G or an operator a from A If g has been chosen: add an Operator o that can achieve g If a has been chosen: apply a, calculate new current state In contrast to standard MEA, pending operators are not ordered Apply or subgoal SAVTA Heuristic State determines if the goal has been reached which goals still need to be achieved which operators are applicable which operators to try first Two possibilities: SAVTA: Eager application SABA: Eager subgoaling Subgoal after every try to apply Eager state changes Assumption: Eager state changes may lead to more informed planning decisions State changes achieve goals for which they were selected State changes do not interfere with other goals

14 SABA Heuristic Select an operator to apply based on two constraints 1. Operator must not negate preconditions of other pending operators 2. No other operator should delete any effects of this operator Preference to condition 1 Comparison of planners 150 problems with different number of goals (1..15/10 each) Run problem on each planner and average results If there is no subgoal interaction all planners perform equally well Eager subgoaling can be better Paint domain: colors white, yellow,... black. One roller. Operator Ai Prec.: {I i } Eff: add {G i } del {I j for all i<j} Allow determination of subgoal interactions Eager applying can be better Paint domain: Use different brushes 1 to 8 Subgoaling attempts to reuse the same brush Fortuitous achieves parts of the goal One operator achieves the whole goal Operator selection Many possible operators achieve goal FLECS: Veloso (94) Intermediate heuristic

15 Moral of the story Partial order planning There is no single planning strategy that performs more efficiently than others for all problems or in all domains No general problem solver (GPS) Analyze conditions for planning strategies Learning conditions for planning strategies Planners that can use different strategies DoLittle (Baltes 1996): Combine different problem solving strategies on single problem Different sequences of the same operators Least commitment principle Sacerdoti (72) Noah, Chapman (87) Tweak Ordering of the operators Binding of variables No backtracking in Noah State space vs. Plan space Search through the Space of Plans Standard search: Each node represents a state Applying operators to move from one state to the next Plan space approach: Each node represents a possibly incomplete/faulty plan Apply changes to the plans to move from one state to the next (e.g., add operator, instantiate variable, reorder operators) Search through space of plans rather than space of situations i.e planspace node denote plans Start with a simple partial plan Expand the plan until the complete plan is developed Operators in this step: The solution: final plan Path to goal is irrelevant

16 Representation of Plans Partial Order Plans: Start Totally Order Plans: Start Start Start Start Start Start Consider a simple problem: Goal RightShoeOn ^ LeftShoeOn Four operators: Left Sock Left Shoe Left Shoe on Left Sock on Right Sock on Finish Right Sock Right Shoe Right Shoe on Right Sock Left Sock Right Shoe Left Shoe Right Sock Left Sock Left Sock Right Shoe Left Sock Right Sock Right Shoe Left Shoe Left Sock Right Sock Left Shoe Right Shoe Right Sock Right Shoe Left Sock Left Shoe Left Sock Left Shoe Right Sock Right Shoe Finish Finish Finish Finish Finish Finish Least Commitment Least Commitment One should make choices only about things that you currently care about,leaving the others to be worked out later. Partial Order Planner A planner that can represent plans in which some steps are ordered (before or after) w.r.t each other and other steps are unordered. Total Order Planner Planner in which plans consist of a simple lists of steps Linearization of P A totally ordered plan that is derived from a plan P by adding constraints Example Planning Domain

17 Towers of Hanoi Means-ends Analysis Objects: (Peg1,Peg2,Peg3, Small_D, Medium_D, Large_D) Predicates: (is-on $Disk_X $Peg_Y) order of disks is determined Operator Example: Move-Medium ($Peg_X $Peg_Y) Prec: ~ (is-on Small_D $Peg_X) ~ (is-on Small_D $Peg_Y) Eff: add (is-on Medium_D $Peg_Y) del (is-on Medium_D $Peg_X) Means-ends analysis sample problem Initial State: (is-on S P2)^(is-on M P1)^(is-on L P3) Goal: (is-on S P3)^(is-on M P1)^(is-on L P2) Trace the execution of linear MEA. Find optimal solution Show the current plan and the goal stack Identify all choice steps and list all alternatives Partial Solution Partial order planning Differences: (io S P3)^(io L P2). Choose goal Relevant operators: move-large(p1 P2), ml (P2 P2), ml (P3 P2) Add operator ml (P3 P2) to plan tail Precond of move-large(p3 P2) ~(io S P3)^ ~(io S P3)^ ~(io S P2)^ ~(io S P2) ~(io M P3)^~(io M P3)^~(io M P2)^~(io M P2) Differences: ~(io S P2) Relevant Operators: ms (P2 P1), ms (P2 P3) Precond: nil Apply or subgoal Apply or subgoal... Add operator ms(p1 P3) Apply or subgoal Plan I ml (P3 P2)->G I ms(p2 P1)-> ml(p3 P2)-> G I -> ms(p2 P1) -> ml (P3 P2) -> G I -> ms(p2 P1) -> ml (P3 P2) -> ms (P1 P3) -> G Problem

18 Partial order planning Planner chooses ordering of steps for no good reason Goals: Representation (P,A), where P is a precondition of A Plan to put on a pair of shoes (right one first?) Plans: Least commitment planning: Only make choices that are necessary. Delay other choices until later. Avoid backtracking! Same principle: fully instantiated vs. partially instantiated plans. Choice of variables Operators (Actions) Ordering constraints (A i < A j ) Causal links to record reasons for operators in the plan (A i, A j,p): A i achieves P for A j Causal links need to be protected from threats Partial order planning algorithm To start: create an empty plan to start Plans,Causal Links and Threats Loop: Pick an open goal (P,A y ) Try to find an existing action AX that achieves P Else create a new action AX that can precede A y Add ordering (A X < A Y ) Check for threats Promotion Demotion If A X is a new action, generate new goals for its preconditions Representing a Plan as a three tuple :-- <A,O,L> If A ={A1,A2,A3} then O might be set{a1<a3,a2<a3} These constraints specify a plan in which A3 is necessarily the last action but does not commit to a choice of which of the three actions comes first. As least commitment planners refine their plans, they must do constraint satisfaction to ensure consistency of O

19 Causal Links A Causal Links is written as S i -> S j and read as S i achieves c for S j Causal Links serve to record the purpose of steps in the plan:here a purpose of S i is to achieve the precondition c Example Problem of S j Threat Causal Links are used to detect when a newly introduced action interferes with past decision. Such an action is called a Threat. Let At be a different action in A : we say that A t threatens A p <- A c when the two criteria are met: Initial State and Goals of Operators Partial Order Plan Actions, Ordering, Links

20 Partial Order Planning Actions, Ordering, Links Partial Order Planning Actions, Ordering, Links Partial Order Planning Actions, Ordering, Links What constitutes a correct plan?

21 Why do we need an ordering? do we need an ordering? Must buy milk before going home Why Allow the other ordering Why do we need an ordering? do we need an ordering? Allow the other ordering Why Ordering resolves the threat

22 Plan Correctness Complete and Consistent Partial Order Planning Algorithm The algorithm can be derived from consistency and completeness Completeness achieve all preconditions Backward chaining from goal to initial state by inserting actions and causal links Must avoid intervening actions that threaten After adding an action, search for possible threats and introduce an ordering to resolve the threat Partial Order Planning Algorithm Backward Chaining Consistent Ordering must be consistent After each causal link and ordering is inserted, check for loops

23 Backward Chaining Backward Chaining Backward Chaining Threat Resolution

24 Promotion Demotion Example Problem Example Problem

25 Example Problem POP Planning Algorithm POP(<A,O,L>, agenda, actions) <A,O,L> a partial plan to expand Agenda: a queue of open conditions still to be satisfied: <p, a_need> Actions: a set of actions that may be introduced to meet needs a_add: an action that produces the needed condition for p for a_need a_threat: an action that may threaten a causal link from a_producer to a_consumer POP Planning Algorithm Initial: Sussman anomaly (again) (is-on C A),(is-on A table),(is-on B table) (clear B),(clear C) Goal: (is-on A B) (is-on B C)

26 Case-based planning Hammond s CHEF system (Szechuan cooking domain) Theory tells us that no matter what planning is a difficult problem. Instead of generating new plans from scratch, we should reuse as much as possible from previous plans. Instead, retrieve a previous plan and adapt it to the new situation Hash tables or discrimination nets CHEF algorithm Retrieve similar plan Domain dependent similarity measure (Goal and initial state Hash tables, discrimination net Superficially adapt the plan (replace objects) Simulate the plan and detect failures: why did an operator fail what goal was it trying to achieve Each failure is associated with a TOP CHEF TOP (Them. Organ. Packet) associate domain independent repair method anticipate failure learning from failure Repair strategies selected by TOPS CHEF Order of repairs depends on domain-dependent and independent control rules Adding a preparation step is easier than adding a cooking step Better to add single operator as opposed to a sequence of operators More expressive plan representation time, concurrent actions Objects have features (which can be changed) Ingredients and tools

27 Abstraction-based planning Tyranny of detail Example: Auckland - New York Create an abstract plan first, then refine later ABSTRIPS (Sacerdoti 1974) create abstract operators by dropping preconditions Each literal in the preconditions is assigned a criticality value TofH: Ignore position of smaller disks ABSTRIPS Hierarchy of problem spaces. Problem space at level i, ignore all predicates with criticality < i. Removal of preconditions leads to additional links between nodes in the world state Creation of abstraction levels User defined, system refined A literal that can not be affected by any operator (static literal)is at the highest criticality level If ABSTRIPS can find a short plan to achieve a precondition, given that the others are true, its criticality is given by the user If ABSTRIPS can not find a short plan, it gets a higher criticality value than any user defined one Reduced abstraction hierarchies Alpine (Knoblock 1991) Abstract problem spaces (goals, states, precond, effects) Dropping literals from the problem space Ordered monotonicity: A literal introduced at level i will not be changed by any lower level. TofH: (is-on Large Peg3), then during refinement, the Large disk can not be moved

28 Execution of Partial Order Plan Execution of Partial Order Plan Execution of Partial Order Plan Execution of Partial Order Plan

29 Execution of Partial Order Plan Execution of Partial Order Plan Execution of Partial Order Plan Execution of Partial Order Plan

30 Plan Execution Problem with Simple Planning Agent Classical Planning Real World World is totally accessible, deterministic, and completely closed - agent is omniscient all actions are complete and correct and all consequences of these actions are known World is inaccessible, nondeterministic, and open - impossible to know everything (Incomplete information) World does not necessarily match agent s model of it (Incorrect information) Anything can happen! How do we deal with this? What s the difference? Two ways of dealing with information that is incomplete or incorrect: Conditional (Contingency) Planning alternate plan for each contingency that could arise agent used sensing actions to test for appropriate conditions Execution Monitoring agent monitors what s happening while it s executing the plan agent sees what goes wrong and can then replan There is one main difference between conditional planning and execution monitoring: agent considers what might go wrong and plans for each contingency before hand. agent puts off dealing with problems until they actually arise

31 Conditional Planning Flat Tire Example A conditional planner: Goal: On(x) Inflated(x) Actions: deals with incorrect and incomplete information by making plans for each situation that might arise uses sensing actions to check the resulting situation and performs the corresponding plan Examples of sensing actions: Initial Conditions: Inflated(Spare) Intact(Spare) Off(Spare) On(Tire1) Flat(Tire1) Op(ACTION: PRECOND: EFFECT: Op(ACTION: PRECOND: EFFECT: Remove(x), On(x), Off(x) ClearHub(x) On(x)) PutOn(x), Off(x) ClearHub(x), On(x) ClearHub(x) Off(x)) CheckOn(Light) Op(ACTION: Inflate(x), CheckPrice(Milk) PRECOND: EFFECT: Intact(x) Flat(x), Inflated(x) Flat(x)) Plan: [Remove(Tire1), PutOn(Spare)] Flat Tire Example continued Is there an easier way? - inflate Tire1 instead of replacing it - Tire1 must be intact Need to add a conditional step: If(<Condition>, <ThenPart>, <ElsePart>) If(Intact(Tire1), [Inflate(Tire1)], [Remove(Tire1), PutOn(Spare)]) Sensing Actions The agent MUST be able to decide the truth or falsehood of a condition Sensing actions make facts known through percepts (eg. CheckTire(x)) Situation Calculus: x,s Tire(x) KnowsWhether( Intact(x), Result(CheckTire(x),s)) Action Schema: Op(ACTION: CheckTire(x), PRECOND:Tire(x), EFFECT: KnowsWhether( Intact(x) ))

32 Context CPOP Example the union of the conditions that must hold in order for the step to be executed describes the branch on which the step lies Example: Start On(Tire1) Flat(Tire1) Inflated(Spare) Check(Tire1) Intact(Tire1) Flat(Tire1) Intact(Tire1) Inflate(Tire1) (Intact(Tire1)) {x/tire1} On(x) Inflated(x) On(Tire1) Inflated(Tire1) Finish (True) The context of the action Inflate(Tire1) is Intact(Tire1). Inflate(Tire1) (Intact(Tire1)) CPOP Example CPOP Example Start On(Tire1) Flat(Tire1) Inflated(Spare) Check(Tire1) Intact(Tire1) Flat(Tire1) Intact(Tire1) Inflate(Tire1) (Intact(Tire1)) On(Tire1) Inflated(Tire1) Finish (Intact(Tire1)) Start On(Tire1) Flat(Tire1) Inflated(Spare) Check(Tire1) Intact(Tire1) Flat(Tire1) Intact(Tire1) Inflate(Tire1) (Intact(Tire1)) On(Tire1) Inflated(Tire1) Finish (Intact(Tire1)) {x/spare} Intact(Tire1) Remove(Tire1) (True) PutOn(Spare) (True) On(x) Inflated(x) On(Spare) Inflated(Spare) Finish ( Intact(Tire1)) Remove(Tire1) ( Intact(Tire1)) PutOn(Spare) ( Intact(Tire1)) On(Spare) Inflated(Spare) Finish ( Intact(Tire1))

33 Parameterized Plans Conditional steps can have more than two possible outcomes. eg. SenseTemperature(t) In this case, t is called a runtime variable because the value will not be known until the step is executed. A Simple Replanning Agent If an agent is in a closed world, it can deal with incomplete information. This is not the case in real domain. Execution Monitoring checks the remaining part of the plan to make sure no errors have occurred so far Action Monitoring check precondition of each action, rather than the entire remaining part of the plan Does not look ahead Detect changes in the world Action Monitoring Execution Monitoring Agent only checks the preconditions of the current step checks the preconditions protected by causal links that begin before or at the current state AND end at or after the current state Agent Checks: Example: s2 is the current state preconditions of s2 p2, p3 Example: s2 is the current state Agent Checks begin before or at cs (p1, p2, p3, p4, p5, p7) AND Links that: end at or after cs p2, p3, p4, p5, p7 Start p4 p5 s3 p6 p7 Finish Start p4 p5 s3 p6 p7 Finish p1 s1 p2 p3 s2 p1 s1 p2 p3 s2

34 Action Monitoring Action Monitoring Plan Execution with Action Monitoring Execution Monitoring

35 Execution Monitoring Plan Execution with Execution Monitoring Plan Execution with Execution Monitoring A Simple Replanning Agent Bounded indeterminacy: Action can have unexpected effects but can be enumerated eg. Open a can of paint having paint available having an empty can spilling the paint

36 A Simple Replanning Agent Simple Replanning with Execution Monitoring Unbounded indeterminacy: Set of possible unexpected outcome is too large Modified version of simple planning agent Complex and/or dynamic domain eg. Driving, economic planning, and military strategy Keep track of p, remaining plan, and q the complete plan Limit the plan and replan when encounter unexpected condition Fully Integrated Planning and Execution Situated Planning Agent Planner and Execution Monitor are a single process Agent can begin executing the plan before it is complete if independent subgoals are present Agent continuously monitors the world Execution monitoring & Replanning

37 Blocks World Example (1) Blocks World Example (2) Start Ontable(A) On(B,E) On(C,F) On(D,G) Clear(A) Clear(C) Clear(D) Clear(B) On(D,G) Clear(D) Clear(B) Move(D,B) On(C,F) Clear(C) Clear(D) Move(C,D) On(C,D) On(D,B) Finish Start Ontable(A) On(B,E) On(C,F) On(D,B) Clear(A) Clear(C) Clear(D) Clear(G) On(D,y) Clear(D) Clear(B) Move(D,B) On(C,F) Clear(C) Clear(D) Move(C,D) On(C,D) On(D,B) Finish B C D External agent moves D onto B D B C A E F G A E F G Blocks World Example (3) Blocks World Example (4) Open Condition! Start Ontable(A) On(B,E) On(C,F) On(D,B) Clear(A) Clear(C) Clear(D) Clear(G) On(C,F) Clear(C) Clear(D) Move(C,D) On(C,D) On(D,B) Finish Start Ontable(A) On(B,E) On(C,A) On(D,B) Clear(F) Clear(C) Clear(D) Clear(G) On(C,D) On(D,B) Finish Causal link is extended and redundant step is eliminated A D B E C F G Move(C,D) action fails because C accidentally drops onto A OOPS! C A D B E F G

38 Blocks World Example (5) Blocks World Example (6) Start Ontable(A) On(B,E) On(C,A) On(D,B) Clear(aF) Clear(C) Clear(D) Clear(G) On(C,A) Clear(C) Clear(D) Move(C,D) On(C,D) On(D,B) Finish Start Ontable(A) On(B,E) On(C,D) On(D,B) Clear(F) Clear(C) Clear(A) Clear(G) On(C,D) On(D,B) Finish Move(C,D) action is put back in to resolve open condition C A D B E F G We re done! A C D B E F G Comparing Conditional Planning & Replanning Summary Conditional Planning: Can have exponential conditions to plan for Impractical Replanning: Assume no action failure and fix it when problems occur Plans are fragile ; hard to fix if things go wrong eg. Spare tire (Conditional Planning) Ways that we can deal with incorrect or incomplete information: Conditional planning uses conditional steps and sensing actions to plan for each contingency Replanning can recover from execution error by checking preconditions and re-executing steps Fully integrated planning and execution allows the agent to remodel the plan during execution Coercion removes uncertainty by forcing the desired state Abstraction removes trivial details from the plan and looks at the bigger picture

39 References Russel and Norvig, AI, a modern approach, Chapter 11 (Planning) and 12 (Planning and acting) Craig Knoblock's PhD thesis (Alpine) Manuela Veloso (CMU) Marie desjardins (Lecture slides) Brian C. Williams (Lecture slides) MakingFall2003/0D0E3B6A-B A BD93A3D11/0/11partordplan.pdf

KI-Programmierung. Planning

KI-Programmierung. Planning KI-Programmierung Planning Bernhard Beckert UNIVERSITÄT KOBLENZ-LANDAU Winter Term 2007/2008 B. Beckert: KI-Programmierung p.1 Outline Search vs. planning STRIPS operators Partial-order planning The real

More information

Artificial Intelligence

Artificial Intelligence Artificial Intelligence Lecturer 7 - Planning Lecturer: Truong Tuan Anh HCMUT - CSE 1 Outline Planning problem State-space search Partial-order planning Planning graphs Planning with propositional logic

More information

Planning II. Introduction to Artificial Intelligence CSE 150 Lecture 12 May 15, 2007

Planning II. Introduction to Artificial Intelligence CSE 150 Lecture 12 May 15, 2007 Planning II Introduction to Artificial Intelligence CSE 150 Lecture 12 May 15, 2007 Administration Your second to last Programming Assignment is up - start NOW, you don t have a lot of time The PRIZE:

More information

Commitment Least you haven't decided where to go shopping. Or...suppose You can get milk at the convenience store, at the dairy, or at the supermarket

Commitment Least you haven't decided where to go shopping. Or...suppose You can get milk at the convenience store, at the dairy, or at the supermarket Planning as Search-based Problem Solving? Imagine a supermarket shopping scenario using search-based problem solving: Goal: buy milk and bananas Operator: buy Heuristic function: does = milk

More information

Set 9: Planning Classical Planning Systems. ICS 271 Fall 2013

Set 9: Planning Classical Planning Systems. ICS 271 Fall 2013 Set 9: Planning Classical Planning Systems ICS 271 Fall 2013 Outline: Planning Classical Planning: Situation calculus PDDL: Planning domain definition language STRIPS Planning Planning graphs Readings:

More information

3. Knowledge Representation, Reasoning, and Planning

3. Knowledge Representation, Reasoning, and Planning 3. Knowledge Representation, Reasoning, and Planning 3.1 Common Sense Knowledge 3.2 Knowledge Representation Networks 3.3 Reasoning Propositional Logic Predicate Logic: PROLOG 3.4 Planning Planning vs.

More information

Nonlinear State-Space Planning: Prodigy4.0

Nonlinear State-Space Planning: Prodigy4.0 Nonlinear State-Space Planning: Prodigy4.0 Manuela Veloso Carnegie Mellon University Computer Science Department Planning - Fall 2001 Planning - Problem Solving Newell and Simon 1956 Given the actions

More information

Planning and Acting. CITS3001 Algorithms, Agents and Artificial Intelligence. 2018, Semester 2

Planning and Acting. CITS3001 Algorithms, Agents and Artificial Intelligence. 2018, Semester 2 Planning and Acting CITS3001 Algorithms, Agents and Artificial Intelligence Tim French School of Computer Science and Software Engineering The University of Western Australia 2018, Semester 2 Summary We

More information

3. Knowledge Representation, Reasoning, and Planning

3. Knowledge Representation, Reasoning, and Planning 3. Knowledge Representation, Reasoning, and Planning 3.1 Common Sense Knowledge 3.2 Knowledge Representation Networks 3.3 Reasoning Propositional Logic Predicate Logic: PROLOG 3.4 Planning Introduction

More information

Planning (Chapter 10)

Planning (Chapter 10) Planning (Chapter 10) http://en.wikipedia.org/wiki/rube_goldberg_machine Planning Example problem: I m at home and I need milk, bananas, and a drill. What do I do? How is planning different from regular

More information

1 What is Planning? automatic programming. cis716-spring2004-parsons-lect17 2

1 What is Planning? automatic programming. cis716-spring2004-parsons-lect17 2 PLANNING 1 What is Planning? Key problem facing agent is deciding what to do. We want agents to be taskable: give them goals to achieve, have them decide for themselves how to achieve them. Basic idea

More information

Planning (What to do next?) (What to do next?)

Planning (What to do next?) (What to do next?) Planning (What to do next?) (What to do next?) (What to do next?) (What to do next?) (What to do next?) (What to do next?) CSC3203 - AI in Games 2 Level 12: Planning YOUR MISSION learn about how to create

More information

Outline. Planning and Execution in a Changing World. Readings and Assignments. Autonomous Agents

Outline. Planning and Execution in a Changing World. Readings and Assignments. Autonomous Agents Planning and in a Changing World Total Order Plan Contains Irrelevant Committments cleanh carry nogarb Slides draw upon materials from: Dan Weld Stuart Russell & Peter Norvig Brian C. Williams

More information

Planning. Some material taken from D. Lin, J-C Latombe

Planning. Some material taken from D. Lin, J-C Latombe RN, Chapter 11 Planning Some material taken from D. Lin, J-C Latombe 1 Logical Agents Reasoning [Ch 6] Propositional Logic [Ch 7] Predicate Calculus Representation [Ch 8] Inference [Ch 9] Implemented Systems

More information

AUTOMATED PLANNING Automated Planning sequence of actions goal

AUTOMATED PLANNING Automated Planning sequence of actions goal AUTOMATED PLANNING Automated Planning is an important problem solving activity which consists in synthesizing a sequence of actions performed by an agent that leads from an initial state of the world to

More information

Artificial Intelligence. Planning

Artificial Intelligence. Planning Artificial Intelligence Planning Planning Planning agent Similar to previous problem solving agents Constructs plans that achieve its goals, then executes them Differs in way it represents and searches

More information

Planning. Philipp Koehn. 30 March 2017

Planning. Philipp Koehn. 30 March 2017 Planning Philipp Koehn 30 March 2017 Outline 1 Search vs. planning STRIPS operators Partial-order planning The real world Conditional planning Monitoring and replanning 2 search vs. planning Search vs.

More information

Set 9: Planning Classical Planning Systems. ICS 271 Fall 2014

Set 9: Planning Classical Planning Systems. ICS 271 Fall 2014 Set 9: Planning Classical Planning Systems ICS 271 Fall 2014 Planning environments Classical Planning: Outline: Planning Situation calculus PDDL: Planning domain definition language STRIPS Planning Planning

More information

Lecture Overview. CSE3309 Artificial Intelligence. The lottery paradox. The Bayesian claim. The lottery paradox. A Bayesian model of rationality

Lecture Overview. CSE3309 Artificial Intelligence. The lottery paradox. The Bayesian claim. The lottery paradox. A Bayesian model of rationality CSE3309 Lecture Overview The lottery paradox A Bayesian model of rationality Lecture 15 Planning Dr. Kevin Korb School of Computer Science and Software Eng. Building 75 (STRIP), Rm 117 korb@csse.monash.edu.au

More information

Planning. Introduction to Planning. Failing to plan is planning to fail! Major Agent Types Agents with Goals. From Problem Solving to Planning

Planning. Introduction to Planning. Failing to plan is planning to fail! Major Agent Types Agents with Goals. From Problem Solving to Planning Introduction to Planning Planning Failing to plan is planning to fail! Plan: a sequence of steps to achieve a goal. Problem solving agent knows: actions, states, goals and plans. Planning is a special

More information

Primitive goal based ideas

Primitive goal based ideas Primitive goal based ideas Once you have the gold, your goal is to get back home s Holding( Gold, s) GoalLocation([1,1], s) How to work out actions to achieve the goal? Inference: Lots more axioms. Explodes.

More information

Automated Planning. Plan-Space Planning / Partial Order Causal Link Planning

Automated Planning. Plan-Space Planning / Partial Order Causal Link Planning Automated Planning Plan-Space Planning / Partial Order Causal Link Planning Jonas Kvarnström Automated Planning Group Department of Computer and Information Science Linköping University Partly adapted

More information

Plan Generation Classical Planning

Plan Generation Classical Planning Plan Generation Classical Planning Manuela Veloso Carnegie Mellon University School of Computer Science 15-887 Planning, Execution, and Learning Fall 2016 Outline What is a State and Goal What is an Action

More information

cis32-ai lecture # 21 mon-24-apr-2006

cis32-ai lecture # 21 mon-24-apr-2006 cis32-ai lecture # 21 mon-24-apr-2006 today s topics: logic-based agents (see notes from last time) planning cis32-spring2006-sklar-lec21 1 What is Planning? Key problem facing agent is deciding what to

More information

Introduction to Planning COURSE: CS40002

Introduction to Planning COURSE: CS40002 1 Introduction to Planning COURSE: CS40002 Pallab Dasgupta Professor, Dept. of Computer Sc & Engg 2 Outline Planning versus Search Representation of planning problems Situation calculus STRIPS ADL Planning

More information

A deterministic action is a partial function from states to states. It is partial because not every action can be carried out in every state

A deterministic action is a partial function from states to states. It is partial because not every action can be carried out in every state CmSc310 Artificial Intelligence Classical Planning 1. Introduction Planning is about how an agent achieves its goals. To achieve anything but the simplest goals, an agent must reason about its future.

More information

Planning. Introduction

Planning. Introduction Planning Introduction Planning vs. Problem-Solving Representation in Planning Systems Situation Calculus The Frame Problem STRIPS representation language Blocks World Planning with State-Space Search Progression

More information

CS 2750 Foundations of AI Lecture 17. Planning. Planning

CS 2750 Foundations of AI Lecture 17. Planning. Planning S 2750 Foundations of I Lecture 17 Planning Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Planning Planning problem: find a sequence of actions that achieves some goal an instance of a search

More information

INF Kunstig intelligens. Agents That Plan. Roar Fjellheim. INF5390-AI-06 Agents That Plan 1

INF Kunstig intelligens. Agents That Plan. Roar Fjellheim. INF5390-AI-06 Agents That Plan 1 INF5390 - Kunstig intelligens Agents That Plan Roar Fjellheim INF5390-AI-06 Agents That Plan 1 Outline Planning agents Plan representation State-space search Planning graphs GRAPHPLAN algorithm Partial-order

More information

Intelligent Agents. State-Space Planning. Ute Schmid. Cognitive Systems, Applied Computer Science, Bamberg University. last change: 14.

Intelligent Agents. State-Space Planning. Ute Schmid. Cognitive Systems, Applied Computer Science, Bamberg University. last change: 14. Intelligent Agents State-Space Planning Ute Schmid Cognitive Systems, Applied Computer Science, Bamberg University last change: 14. April 2016 U. Schmid (CogSys) Intelligent Agents last change: 14. April

More information

GPS: The general problem solver. developed in 1957 by Alan Newel and Herbert Simon. (H. Simon, 1957)

GPS: The general problem solver. developed in 1957 by Alan Newel and Herbert Simon. (H. Simon, 1957) GPS: The general problem solver developed in 1957 by Alan Newel and Herbert Simon (H. Simon, 1957) GPS: The general problem solver developed in 1957 by Alan Newel and Herbert Simon - Was the first program

More information

Planning. Search vs. planning STRIPS operators Partial-order planning. CS 561, Session 20 1

Planning. Search vs. planning STRIPS operators Partial-order planning. CS 561, Session 20 1 Planning Search vs. planning STRIPS operators Partial-order planning CS 561, Session 20 1 What we have so far Can TELL KB about new percepts about the world KB maintains model of the current world state

More information

Issues in Interleaved Planning and Execution

Issues in Interleaved Planning and Execution From: AAAI Technical Report WS-98-02. Compilation copyright 1998, AAAI (www.aaai.org). All rights reserved. Issues in Interleaved Planning and Execution Scott D. Anderson Spelman College, Atlanta, GA andorson

More information

Cognitive Robotics 2016/2017

Cognitive Robotics 2016/2017 based on Manuela M. Veloso lectures on PLNNING, EXEUTION ND LERNING ognitive Robotics 2016/2017 Planning:, ctions and Goal Representation Matteo Matteucci matteo.matteucci@polimi.it rtificial Intelligence

More information

CMU-Q Lecture 6: Planning Graph GRAPHPLAN. Teacher: Gianni A. Di Caro

CMU-Q Lecture 6: Planning Graph GRAPHPLAN. Teacher: Gianni A. Di Caro CMU-Q 15-381 Lecture 6: Planning Graph GRAPHPLAN Teacher: Gianni A. Di Caro PLANNING GRAPHS Graph-based data structure representing a polynomial-size/time approximation of the exponential search tree Can

More information

Planning in a Single Agent

Planning in a Single Agent What is Planning Planning in a Single gent Sattiraju Prabhakar Sources: Multi-agent Systems Michael Wooldridge I a modern approach, 2 nd Edition Stuart Russell and Peter Norvig Generate sequences of actions

More information

Creating Admissible Heuristic Functions: The General Relaxation Principle and Delete Relaxation

Creating Admissible Heuristic Functions: The General Relaxation Principle and Delete Relaxation Creating Admissible Heuristic Functions: The General Relaxation Principle and Delete Relaxation Relaxed Planning Problems 74 A classical planning problem P has a set of solutions Solutions(P) = { π : π

More information

Formalizing the PRODIGY Planning Algorithm

Formalizing the PRODIGY Planning Algorithm Formalizing the PRODIGY Planning Algorithm Eugene Fink eugene@cs.cmu.edu http://www.cs.cmu.edu/~eugene Manuela Veloso veloso@cs.cmu.edu http://www.cs.cmu.edu/~mmv Computer Science Department, Carnegie

More information

Planning. Planning. What is Planning. Why not standard search?

Planning. Planning. What is Planning. Why not standard search? Based on slides prepared by Tom Lenaerts SWITCH, Vlaams Interuniversitair Instituut voor Biotechnologie Modifications by Jacek.Malec@cs.lth.se Original slides can be found at http://aima.cs.berkeley.edu

More information

Artificial Intelligence 2004 Planning: Situation Calculus

Artificial Intelligence 2004 Planning: Situation Calculus 74.419 Artificial Intelligence 2004 Planning: Situation Calculus Review STRIPS POP Hierarchical Planning Situation Calculus (John McCarthy) situations actions axioms Review Planning 1 STRIPS (Nils J. Nilsson)

More information

Artificial Intelligence

Artificial Intelligence Artificial Intelligence CSC348 Unit 4: Reasoning, change and planning Syedur Rahman Lecturer, CSE Department North South University syedur.rahman@wolfson.oxon.org Artificial Intelligence: Lecture Notes

More information

Transformational Analogy: A General Framework, Semantics and Complexity

Transformational Analogy: A General Framework, Semantics and Complexity Transformational Analogy: A General Framework, Semantics and Complexity By Sarat Chandra Vithal Kuchibatla Venkata A Thesis Presented to the Graduate and Research Committee of Lehigh University in Candidacy

More information

cis32-ai lecture # 22 wed-26-apr-2006 Partial Order Planning Partially ordered plans Representation

cis32-ai lecture # 22 wed-26-apr-2006 Partial Order Planning Partially ordered plans Representation cis32-ai lecture # 22 wed-26-apr-2006 Partial Order Planning today s topics: partial-order planning decision-theoretic planning The answer to the problem we ended the last lecture with is to use partial

More information

Classical Planning. CS 486/686: Introduction to Artificial Intelligence Winter 2016

Classical Planning. CS 486/686: Introduction to Artificial Intelligence Winter 2016 Classical Planning CS 486/686: Introduction to Artificial Intelligence Winter 2016 1 Classical Planning A plan is a collection of actions for performing some task (reaching some goal) If we have a robot

More information

Where are we? Informatics 2D Reasoning and Agents Semester 2, Planning with state-space search. Planning with state-space search

Where are we? Informatics 2D Reasoning and Agents Semester 2, Planning with state-space search. Planning with state-space search Informatics 2D Reasoning and Agents Semester 2, 2018 2019 Alex Lascarides alex@inf.ed.ac.uk Where are we? Last time... we defined the planning problem discussed problem with using search and logic in planning

More information

Planning. Introduction

Planning. Introduction Introduction vs. Problem-Solving Representation in Systems Situation Calculus The Frame Problem STRIPS representation language Blocks World with State-Space Search Progression Algorithms Regression Algorithms

More information

Classical Planning Problems: Representation Languages

Classical Planning Problems: Representation Languages jonas.kvarnstrom@liu.se 2017 Classical Planning Problems: Representation Languages History: 1959 3 The language of Artificial Intelligence was/is logic First-order, second-order, modal, 1959: General

More information

Planning Algorithms Properties Soundness

Planning Algorithms Properties Soundness Chapter MK:VI III. Planning Agent Systems Deductive Reasoning Agents Planning Language Planning Algorithms State-Space Planning Plan-Space Planning HTN Planning Complexity of Planning Problems Extensions

More information

ICS 606. Intelligent Autonomous Agents 1

ICS 606. Intelligent Autonomous Agents 1 Intelligent utonomous gents ICS 606 / EE 606 Fall 2011 Nancy E. Reed nreed@hawaii.edu Lecture #4 Practical Reasoning gents Intentions Planning Means-ends reasoning The blocks world References Wooldridge

More information

Artificial Intelligence Planning

Artificial Intelligence Planning Artificial Intelligence Planning Instructor: Vincent Conitzer Planning We studied how to take actions in the world (search) We studied how to represent objects, relations, etc. (logic) Now we will combine

More information

Planning. CPS 570 Ron Parr. Some Actual Planning Applications. Used to fulfill mission objectives in Nasa s Deep Space One (Remote Agent)

Planning. CPS 570 Ron Parr. Some Actual Planning Applications. Used to fulfill mission objectives in Nasa s Deep Space One (Remote Agent) Planning CPS 570 Ron Parr Some Actual Planning Applications Used to fulfill mission objectives in Nasa s Deep Space One (Remote Agent) Particularly important for space operations due to latency Also used

More information

Planning. Outside Materials (see Materials page)

Planning. Outside Materials (see Materials page) Planning Outside Materials (see Materials page) What is Planning? Given: A way to describe the world An ini

More information

STRIPS HW 1: Blocks World

STRIPS HW 1: Blocks World STRIPS HW 1: Blocks World Operator Precondition Delete List Add List Stack(x, y) CLEAR(y) CLEAR(y) HOLDING(x) HOLDING(x) ON(x, y) Unstack(x, y) ON(x, y) ON(x, y) HOLDING(x) CLEAR(x) CLEAR(y) PickUp(x)

More information

Seach algorithms The travelling salesman problem The Towers of Hanoi Playing games. Comp24412: Symbolic AI. Lecture 4: Search. Ian Pratt-Hartmann

Seach algorithms The travelling salesman problem The Towers of Hanoi Playing games. Comp24412: Symbolic AI. Lecture 4: Search. Ian Pratt-Hartmann Comp24412: Symbolic AI Lecture 4: Search Ian Pratt-Hartmann Room KB2.38: email: ipratt@cs.man.ac.uk 2016 17 Outline Seach algorithms The travelling salesman problem The Towers of Hanoi Playing games Typical

More information

Intelligent Systems. Planning. Copyright 2010 Dieter Fensel and Ioan Toma

Intelligent Systems. Planning. Copyright 2010 Dieter Fensel and Ioan Toma Intelligent Systems Planning Copyright 2010 Dieter Fensel and Ioan Toma 1 Where are we? # Title 1 Introduction 2 Propositional Logic 3 Predicate Logic 4 Reasoning 5 Search Methods 6 CommonKADS 7 Problem-Solving

More information

CPS 270: Artificial Intelligence Planning

CPS 270: Artificial Intelligence   Planning CPS 270: Artificial Intelligence http://www.cs.duke.edu/courses/fall08/cps270/ Planning Instructor: Vincent Conitzer Planning We studied how to take actions in the world (search) We studied how to represent

More information

Lecture 10: Planning and Acting in the Real World

Lecture 10: Planning and Acting in the Real World Lecture 10: Planning and Acting in the Real World CS 580 (001) - Spring 2018 Amarda Shehu Department of Computer Science George Mason University, Fairfax, VA, USA Apr 11, 2018 Amarda Shehu (580) 1 1 Outline

More information

Artificial Intelligence II

Artificial Intelligence II Artificial Intelligence II 2013/2014 - Prof: Daniele Nardi, Joachim Hertzberg Exercitation 3 - Roberto Capobianco Planning: STRIPS, Partial Order Plans, Planning Graphs 1 STRIPS (Recap-1) Start situation;

More information

Planning as Search. Progression. Partial-Order causal link: UCPOP. Node. World State. Partial Plans World States. Regress Action.

Planning as Search. Progression. Partial-Order causal link: UCPOP. Node. World State. Partial Plans World States. Regress Action. Planning as Search State Space Plan Space Algorihtm Progression Regression Partial-Order causal link: UCPOP Node World State Set of Partial Plans World States Edge Apply Action If prec satisfied, Add adds,

More information

CS 621 Artificial Intelligence. Lecture 31-25/10/05. Prof. Pushpak Bhattacharyya. Planning

CS 621 Artificial Intelligence. Lecture 31-25/10/05. Prof. Pushpak Bhattacharyya. Planning CS 621 Artificial Intelligence Lecture 31-25/10/05 Prof. Pushpak Bhattacharyya Planning 1 Planning Definition : Planning is arranging a sequence of actions to achieve a goal. Uses core areas of AI like

More information

Search vs. planning. Planning. Search vs. planning contd. Outline

Search vs. planning. Planning. Search vs. planning contd. Outline Search vs. planning Planning onsider the task get milk, bananas, and a cordless drill Standard search algorithms seem to fail miserably: Go To Pet Store Talk to Parrot uy a Dog Go To School Go To lass

More information

6.001 Notes: Section 15.1

6.001 Notes: Section 15.1 6.001 Notes: Section 15.1 Slide 15.1.1 Our goal over the next few lectures is to build an interpreter, which in a very basic sense is the ultimate in programming, since doing so will allow us to define

More information

Components of a Planning System

Components of a Planning System Planning Components of a Planning System In any general problem solving systems, elementary techniques to perform following functions are required Choose the best rule (based on heuristics) to be applied

More information

Artificial Intelligence 2005/06

Artificial Intelligence 2005/06 Planning: STRIPS 74.419 rtificial Intelligence 2005/06 Planning: STRIPS STRIPS (Nils J. Nilsson) actions are specified by preconditions and effects stated as restricted FOPL formulae planning is search

More information

EMPLOYING DOMAIN KNOWLEDGE TO IMPROVE AI PLANNING EFFICIENCY *

EMPLOYING DOMAIN KNOWLEDGE TO IMPROVE AI PLANNING EFFICIENCY * Iranian Journal of Science & Technology, Transaction B, Engineering, Vol. 29, No. B1 Printed in The Islamic Republic of Iran, 2005 Shiraz University EMPLOYING DOMAIN KNOWLEDGE TO IMPROVE AI PLANNING EFFICIENCY

More information

Planning: STRIPS and POP planners

Planning: STRIPS and POP planners S 57 Introduction to I Lecture 8 Planning: STRIPS and POP planners Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square Representation of actions, situations, events Propositional and first order logic

More information

CS103 Spring 2018 Mathematical Vocabulary

CS103 Spring 2018 Mathematical Vocabulary CS103 Spring 2018 Mathematical Vocabulary You keep using that word. I do not think it means what you think it means. - Inigo Montoya, from The Princess Bride Consider the humble while loop in most programming

More information

June 1992 CMU-CS School of Computer Science Carnegie Mellon University Pittsburgh, PA Abstract

June 1992 CMU-CS School of Computer Science Carnegie Mellon University Pittsburgh, PA Abstract PRODIGY4.0: The Manual and Tutorial 1 The PRODIGY Research Group, under the supervision of Jaime G. Carbonell: Jim Blythe, Oren Etzioni, Yolanda Gil, Robert Joseph, Dan Kahn, Craig Knoblock, Steven Minton,

More information

CS 1571 Introduction to AI Lecture 17. Planning. CS 1571 Intro to AI. Planning

CS 1571 Introduction to AI Lecture 17. Planning. CS 1571 Intro to AI. Planning S 1571 Introduction to I Lecture 17 Planning Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square S 1571 Intro to I Planning Planning problem: find a sequence of actions that achieves some goal an instance

More information

CS510 \ Lecture Ariel Stolerman

CS510 \ Lecture Ariel Stolerman CS510 \ Lecture02 2012-10-03 1 Ariel Stolerman Midterm Evan will email about that after the lecture, at least 2 lectures from now. The exam will be given in a regular PDF (not an online form). We will

More information

Formal Methods of Software Design, Eric Hehner, segment 24 page 1 out of 5

Formal Methods of Software Design, Eric Hehner, segment 24 page 1 out of 5 Formal Methods of Software Design, Eric Hehner, segment 24 page 1 out of 5 [talking head] This lecture we study theory design and implementation. Programmers have two roles to play here. In one role, they

More information

Planning. Chapter 11. Chapter Outline. Search vs. planning STRIPS operators Partial-order planning. Chapter 11 2

Planning. Chapter 11. Chapter Outline. Search vs. planning STRIPS operators Partial-order planning. Chapter 11 2 Planning hapter 11 hapter 11 1 Outline Search vs. planning STRIPS operators Partial-order planning hapter 11 2 Search vs. planning onsider the task get milk, bananas, and a cordless drill Standard search

More information

Section 9: Planning CPSC Artificial Intelligence Michael M. Richter

Section 9: Planning CPSC Artificial Intelligence Michael M. Richter Section 9: Planning Actions (1) An action changes a situation and their description has to describe this change. A situation description (or a state) sit is a set of ground atomic formulas (sometimes literals

More information

Planning. Why not standard search? What is Planning. Planning language. Planning 1. Difficulty of real world problems

Planning. Why not standard search? What is Planning. Planning language. Planning 1. Difficulty of real world problems Planning Based on slides prepared by Tom Lenaerts SWITCH, Vlaams Interuniversitair Instituut voor Biotechnologie Modifications by Jacek.Malec@cs.lth.se Original slides can be found at http://aima.cs.berkeley.edu

More information

CS 520: Introduction to Artificial Intelligence. Review

CS 520: Introduction to Artificial Intelligence. Review CS 520: Introduction to Artificial Intelligence Prof. Louis Steinberg Lecture 2: state spaces uninformed search 1 What is AI? A set of goals Review build an artificial intelligence useful subgoals A class

More information

Uninformed Search. Problem-solving agents. Tree search algorithms. Single-State Problems

Uninformed Search. Problem-solving agents. Tree search algorithms. Single-State Problems Uninformed Search Problem-solving agents Tree search algorithms Single-State Problems Breadth-First Search Depth-First Search Limited-Depth Search Iterative Deepening Extensions Graph search algorithms

More information

Planning. Chapter 11. Chapter 11 1

Planning. Chapter 11. Chapter 11 1 Planning hapter 11 hapter 11 1 Outline Search vs. planning STRIPS operators Partial-order planning hapter 11 2 Search vs. planning onsider the task get milk, bananas, and a cordless drill Standard search

More information

Recursive Definitions

Recursive Definitions Recursion Objectives Explain the underlying concepts of recursion Examine recursive methods and unravel their processing steps Explain when recursion should and should not be used Demonstrate the use of

More information

Final Solution. CS510, Fall 2012, Drexel University Ariel Stolerman

Final Solution. CS510, Fall 2012, Drexel University Ariel Stolerman CS510 Final Solution 1 Ariel Stolerman Final Solution CS510, Fall 2012, Drexel University Ariel Stolerman 1) There is a refinement of the algorithm called the algorithm. Assume that you are given a heuristic

More information

Probabilistic Belief. Adversarial Search. Heuristic Search. Planning. Probabilistic Reasoning. CSPs. Learning CS121

Probabilistic Belief. Adversarial Search. Heuristic Search. Planning. Probabilistic Reasoning. CSPs. Learning CS121 CS121 Heuristic Search Planning CSPs Adversarial Search Probabilistic Reasoning Probabilistic Belief Learning Heuristic Search First, you need to formulate your situation as a Search Problem What is a

More information

! A* is best first search with f(n) = g(n) + h(n) ! Three changes make it an anytime algorithm:

! A* is best first search with f(n) = g(n) + h(n) ! Three changes make it an anytime algorithm: Anytime A* Today s s lecture Lecture 5: Search - 4 Hierarchical A* Jiaying Shen CMPSCI 683 Fall 2004 Other Examples of Hierarchical Problem Solving Reviews of A* and its varations 2 Anytime algorithms

More information

PROFESSOR: Last time, we took a look at an explicit control evaluator for Lisp, and that bridged the gap between

PROFESSOR: Last time, we took a look at an explicit control evaluator for Lisp, and that bridged the gap between MITOCW Lecture 10A [MUSIC PLAYING] PROFESSOR: Last time, we took a look at an explicit control evaluator for Lisp, and that bridged the gap between all these high-level languages like Lisp and the query

More information

Branch & Bound (B&B) and Constraint Satisfaction Problems (CSPs)

Branch & Bound (B&B) and Constraint Satisfaction Problems (CSPs) Branch & Bound (B&B) and Constraint Satisfaction Problems (CSPs) Alan Mackworth UBC CS 322 CSP 1 January 25, 2013 P&M textbook 3.7.4 & 4.0-4.2 Lecture Overview Recap Branch & Bound Wrap up of search module

More information

CS 4700: Foundations of Artificial Intelligence. Bart Selman. Search Techniques R&N: Chapter 3

CS 4700: Foundations of Artificial Intelligence. Bart Selman. Search Techniques R&N: Chapter 3 CS 4700: Foundations of Artificial Intelligence Bart Selman Search Techniques R&N: Chapter 3 Outline Search: tree search and graph search Uninformed search: very briefly (covered before in other prerequisite

More information

Formal Methods of Software Design, Eric Hehner, segment 1 page 1 out of 5

Formal Methods of Software Design, Eric Hehner, segment 1 page 1 out of 5 Formal Methods of Software Design, Eric Hehner, segment 1 page 1 out of 5 [talking head] Formal Methods of Software Engineering means the use of mathematics as an aid to writing programs. Before we can

More information

Operational Semantics

Operational Semantics 15-819K: Logic Programming Lecture 4 Operational Semantics Frank Pfenning September 7, 2006 In this lecture we begin in the quest to formally capture the operational semantics in order to prove properties

More information

Lecture 18: Planning and plan execution, applications

Lecture 18: Planning and plan execution, applications Lecture 18: Planning and plan execution, applications Planning, plan execution, replanning Planner as a part of an autonomous robot: robot architectures The subsumption architecture The 3-tier architecture:

More information

Hierarchical Task Network (HTN) Planning

Hierarchical Task Network (HTN) Planning Sec. 12.2 p.1/25 Hierarchical Task Network (HTN) Planning Section 12.2 Sec. 12.2 p.2/25 Outline Example Primitive vs. non-primitive operators HTN planning algorithm Practical planners Additional references

More information

AI Planning. Introduction to Artificial Intelligence! CSCE476/876, Spring 2012:! Send questions to Piazza!

AI Planning. Introduction to Artificial Intelligence! CSCE476/876, Spring 2012:!  Send questions to Piazza! AI! CSCE476/876, Spring 2012:! www.cse.unl.edu/~choueiry/s12-476-876/! Send questions to Piazza! Berthe Y. Choueiry (Shu-we-ri)! Avery Hall, Room 360! Tel: +1(402)472-5444! 1 Reading! Required reading!

More information

PROPOSITIONAL LOGIC (2)

PROPOSITIONAL LOGIC (2) PROPOSITIONAL LOGIC (2) based on Huth & Ruan Logic in Computer Science: Modelling and Reasoning about Systems Cambridge University Press, 2004 Russell & Norvig Artificial Intelligence: A Modern Approach

More information

6. Hoare Logic and Weakest Preconditions

6. Hoare Logic and Weakest Preconditions 6. Hoare Logic and Weakest Preconditions Program Verification ETH Zurich, Spring Semester 07 Alexander J. Summers 30 Program Correctness There are many notions of correctness properties for a given program

More information

Planning Chapter

Planning Chapter Planning Chapter 11.1-11.3 Some material adopted from notes by Andreas Geyer-Schulz and Chuck Dyer Typical BW planning problem A C B A B C Blocks world The blocks world is a micro-world consisting of a

More information

CS 4649/7649 Robot Intelligence: Planning

CS 4649/7649 Robot Intelligence: Planning CS 4649/7649 Robot Intelligence: Planning Hierarchical Network Planning Sungmoon Joo School of Interactive Computing College of Computing Georgia Institute of Technology S. Joo (sungmoon.joo@cc.gatech.edu)

More information

Module 6. Knowledge Representation and Logic (First Order Logic) Version 2 CSE IIT, Kharagpur

Module 6. Knowledge Representation and Logic (First Order Logic) Version 2 CSE IIT, Kharagpur Module 6 Knowledge Representation and Logic (First Order Logic) Lesson 15 Inference in FOL - I 6.2.8 Resolution We have introduced the inference rule Modus Ponens. Now we introduce another inference rule

More information

6.001 Notes: Section 8.1

6.001 Notes: Section 8.1 6.001 Notes: Section 8.1 Slide 8.1.1 In this lecture we are going to introduce a new data type, specifically to deal with symbols. This may sound a bit odd, but if you step back, you may realize that everything

More information

To achieve their goals, agents often need

To achieve their goals, agents often need An Introduction to Least Commitment Planning Daniel S. Weld Recent developments have clarified the process of generating partially ordered, partially specified sequences of actions whose execution will

More information

Week 7 Prolog overview

Week 7 Prolog overview Week 7 Prolog overview A language designed for A.I. Logic programming paradigm Programmer specifies relationships among possible data values. User poses queries. What data value(s) will make this predicate

More information

Problem Solving Agents Solving Problems through Search CIS 32

Problem Solving Agents Solving Problems through Search CIS 32 Problem Solving Agents Solving Problems through Search CIS 32 Today: Behavior Based AI Functionally Next Class - In 2 Wednesdays (Could Meet on Tuesday Next Week) No Thursday Office Hours (any more) -

More information

MITOCW MIT6_172_F10_lec18_300k-mp4

MITOCW MIT6_172_F10_lec18_300k-mp4 MITOCW MIT6_172_F10_lec18_300k-mp4 The following content is provided under a Creative Commons license. Your support will help MIT OpenCourseWare continue to offer high quality educational resources for

More information

Unit 1: Understanding Production Systems

Unit 1: Understanding Production Systems Unit 1: Understanding Production Systems Section 1.1: The ACT-R Production System ACT-R is a production system theory that tries to explain human cognition by developing a model of the knowledge structures

More information