Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Plan-Space Planning: Overcoming Search Limitations in Automated Planning, Slides of Computer Science

Lecture slides on plan-space planning (psp), a technique used in automated planning to overcome the limitations of state-space search. Psp is a forward-chaining, goal-driven planning method that searches for a partially ordered plan to achieve a goal. It involves identifying open goals and threats, and resolving them through the use of causal links and constraints. Examples and explanations of the psp algorithm and its advantages.

Typology: Slides

2012/2013

Uploaded on 03/21/2013

dharmpaal
dharmpaal 🇮🇳

3.9

(10)

87 documents

1 / 21

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Chapter 5
Plan-Space Planning
Lecture slides for
Automated Planning: Theory and Practice
Docsity.com
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15

Partial preview of the text

Download Plan-Space Planning: Overcoming Search Limitations in Automated Planning and more Slides Computer Science in PDF only on Docsity!

Chapter 5

Plan-Space Planning

Lecture slides for

Automated Planning: Theory and Practice

Motivation

  • Problem with state-space search
    • In some cases we may try many different orderings of the same actions before realizing there is no solution
  • Least-commitment strategy: don’t commit to

orderings, instantiations, etc., until necessary

a b c b a

b a^ b a c b c (^) a c b

goal

dead end dead end

dead end dead end dead end dead end

Plan-Space Planning - Basic Idea

  • Backward search from the goal
  • Each node of the search space is a partial plan
    • A set of partially-instantiated actions
    • A set of constraints
  • Make more and more refinements, until we have a solution
  • Types of constraints:
    • precedence constraint : a must precede b
    • binding constraints :
      • inequality constraints, e.g., v 1 ≠ v 2 or v ≠ c
      • equality constraints (e.g., v 1 = v 2 or v = c ) and/or substitutions
    • causal link :
      • use action a to establish the precondition p needed by action b
  • How to tell we have a solution: no more flaws in the plan
    • Will discuss flaws and how to resolve them

foo( x ) Precond: … Effects: p( x )

bar(y) Precond: ¬p( y ) Effects: …

baz( z ) Precond: p( z ) Effects: …

p( z )

x ≠ y

x = z

Flaws: 1. Open Goals

• Open goal:

  • An action a has a precondition p that we haven’t

decided how to establish

• Resolving the flaw:

  • Find an action b
    • (either already in the plan, or insert it)
  • that can be used to establish p
    • can precede a and produce p
  • Instantiate variables and/or

constrain variable bindings

  • Create a causal link

foo( x ) Precond: … Effects: p( x )

baz( z ) Precond: p( z ) Effects: …

p( z )

foo( x ) Precond: … Effects: p( x )

baz( x ) Precond: p( x ) Effects: …

p( x )

The PSP Procedure

  • PSP is both sound and complete
  • It returns a partially ordered solution plan
    • Any total ordering of this plan will achieve the goals
    • Or could execute actions in parallel if the environment permits it

Example

  • Similar (but not identical) to an example in Russell and Norvig’s Artificial Intelligence: A Modern Approach (1st edition)
  • Operators:
    • Start Precond: none Effects: At(Home), sells(HWS,Drill), Sells(SM,Milk), Sells(SM,Banana)
    • Finish Precond: Have(Drill), Have(Milk), Have(Banana), At(Home)
    • Go( l,m ) Precond: At( l ) Effects: At( m ), ¬At( l )
    • Buy( p , s ) Precond: At( s ), Sells( s , p ) Effects: Have( p )

Start and Finish are dummy actions that we’ll use instead of the initial state and goal

Example (continued)

  • The first three refinement steps
    • These are the only possible ways to establish the Have preconditions

At( s 1 ) At( s 2 )^ At( s 3 )

Buy(Drill, s 1 ) Buy(Milk, s 2 ) Buy(Bananas,^ s 2 )

Have(Drill)

Start

Buy(Drill, s 1 )

Finish

Have(Milk) (^) Have(Bananas)

Sells( s 1 , Drill) Sells( s 2 ,Milk)^ Sells( s 3 ,Bananas)

At(Home)

Why don’t we use Start to establish At(Home)?

Example (continued)

  • Three more refinement steps
    • The only possible ways to establish the Sells preconditions

At(HWS) At(SM)^ At(SM)

Buy(Drill, s 1 ) (^) Buy(Milk, SM) Buy(Bananas, SM)

Have(Drill)

Start

Buy(Drill, HWS)

Finish

Have(Milk) (^) Have(Bananas)

Sells(HWS,Drill) Sells(SM,Milk)^ Sells(SM,Bananas)

At(Home)

Example (continued)

  • Finally, a nondeterministic choice: how to resolve the threat to At( s 1 )?
    • Our choice: make Buy(Drill) precede Go(SM)
    • This also resolves the other two threats

At(SM)

Buy(Drill, s 1 )

Have(Drill)

Start

Finish

Have(Milk) (^) Have(Bananas)

Sells(SM,Milk) (^) Sells(SM,Bananas)

Go( l 2 , SM)

At(Home)

At( l 2 ) At( l 1 )

Go( l 1 ,HWS)

At(HWS) Sells(HWS,Drill) At(SM)

Buy(Drill, HWS) Buy(Milk, SM) Buy(Bananas, SM)

Example (continued)

  • Nondeterministic choice: how to establish At( l 1 )?
    • We’ll do it from Start, with l 1 =Home

At(Home)

At(SM)

Buy(Drill, s 1 )

Have(Drill)

Start

Finish

Have(Milk) (^) Have(Bananas)

Sells(SM,Milk) (^) Sells(SM,Bananas)

Go( l 2 , SM)

Go(Home,HWS)

At(Home)

At( l 2 )

At(HWS) Sells(HWS,Drill) At(SM)

Buy(Drill, HWS) Buy(Milk, SM) Buy(Bananas, SM)

Example (continued)

  • The only possible way to establish At(Home) for Finish
    • This creates a bunch of threats

Go( l 3 , Home)

At(Home)

At(SM)

Buy(Drill, s 1 )

Have(Drill)

Start

Finish

Have(Milk) (^) Have(Bananas)

Sells(SM,Milk) (^) Sells(SM,Bananas)

Go(HWS, SM)

Go(Home,HWS)

At(Home)

At(HWS)

At(HWS) Sells(HWS,Drill) At(SM)

Buy(Drill, HWS) Buy(Milk, SM) Buy(Bananas, SM)

Example (continued)

  • To remove the threats to At(SM) and At(HWS), make them precede Go( l 3 ,Home)
    • This also removes the other threats

Go( l 3 , Home)

At(Home)

At(SM)

Buy(Drill, s 1 )

Have(Drill)

Start

Finish

Have(Milk) (^) Have(Bananas)

Sells(SM,Milk) (^) Sells(SM,Bananas)

Go(HWS, SM)

Go(Home,HWS)

At(Home)

At(HWS)

At(HWS) Sells(HWS,Drill) At(SM)

Buy(Drill, HWS) Buy(Milk, SM) Buy(Bananas, SM)

Discussion

  • How to choose which flaw to resolve first and how to resolve it? - We’ll return to these questions in Chapter 10
  • PSP doesn’t commit to orderings and instantiations until necessary - Avoids generating search trees like this one:
  • Problem: how to prune infinitely long paths?
    • Loop detection is based on recognizing states we’ve seen before
    • In a partially ordered plan, we don’t know the states
  • Can we prune if we see the same action more than once?
    • No. Sometimes we might need the same action several times in different states of the world (see next slide)

a b c b a

b a^ b a c b c (^) a c b

goal

  • • •^ go(b,a)^ go(a,b)^ go(b,a)^ at(a)

Example

  • 3-digit binary counter starts at 000, want to get to 110

s 0 = { d 3 =0, d 2 =0, d 1 =0} g = { d 3 =1, d 2 =1, d 1 =0}

  • Operators to increment the counter by 1:

incr Precond: d 1 = Effects: d 1 =

incr Precond: d 2 =0, d 1 = Effects: d 2 =1, d 1 =

incr Precond: d 3 =0, d 2 =1, d 1 = Effects: d 3 =1, d 2 =0, d 1 =0 Docsity.com