1. Gyanastra
  2. Artificial Intelligence
  3. Planning
  4. Planning Systems and Goal Stack
Free lesson, no account needed 10 min read 29 practice questions after it
Asked in past papers2 times
  • UGC NET20172013

Artificial Intelligence · Planning

Planning Systems and Goal Stack

Overview

Planning is the process of deciding a course of action before acting, so that an agent can move from a given situation to a desired situation.
A planning problem is specified by an initial state, a goal description, and a set of actions/operators; a plan is a sequence or partial order of actions that achieves the goal.
In the UGC NET Computer Science syllabus, this lesson sits in the Planning area and requires clear understanding of STRIPS, blocks world, goal stack planning, means-ends analysis, and operator subgoaling. The student should already know basic state-space search, sets, and simple first-order logic notation.

Key concepts

  • A planning problem has four parts: initial state, goal description, action set, and plan. The plan transforms the initial state into a state satisfying the goal.
  • A planning system is a deliberative system: it reasons about future actions using a model of the world. A reactive agent instead maps perception directly to action, usually without constructing a multi-step plan.
  • Classical planning assumes deterministic actions, full observability, finite states, and a static world. The closed-world assumption says any proposition not listed in the current state is false.
  • STRIPS stands for STanford Research Institute Problem Solver. It was developed at SRI in the early 1970s and used to control the robot Shakey. It is a planning representation and implementation formalism, not a natural language processing formalism.
  • STRIPS representation is action-centric: it describes operators/actions. Each operator schema has a name, preconditions, an add list, and a delete list.
  • A precondition is a proposition that must hold before an action can be applied. An add list contains propositions made true by the action. A delete list contains propositions made false by the action.
  • In basic STRIPS, a state is a set of positive ground literals. Negations are omitted and handled by the closed-world assumption.
  • The blocks world is the standard toy domain used to explain a planning system, not primarily a search technique, constraint satisfaction system, or knowledge-base system.
    Conventional predicates include ON(x,y), ONTABLE(x), CLEAR(x), HOLDING(x), and ARMEMPTY. Typical actions are STACK, UNSTACK, PICKUP, and PUTDOWN.
  • Goal stack planning uses a last-in first-out stack containing goals and operators.
    For a conjunction, the planner pushes the conjuncts as subgoals; for an unsatisfied simple goal, it finds an operator that adds that goal, pushes the operator, then pushes the operator’s preconditions as new subgoals.
  • Means-ends analysis compares the current state with the goal state, finds a difference, and selects an operator whose effects can reduce that difference.
    If the operator’s preconditions are not true, it sets up subgoals to establish them.
  • Operator subgoaling is the backward-chaining process in which operators are selected first, and then subgoals are created to establish the preconditions of those operators.
    This is the concept named in the standard means-ends analysis description.
  • A linear plan is a totally ordered sequence of actions: each action is placed before the next. A non-linear plan or partial-order plan leaves some actions unordered and allows interleaving or concurrency.
  • The Sussman anomaly is a blocks-world example showing that solving subgoals independently and concatenating the results can fail or produce unnecessary work when subgoals interact.
    Correct planning may need to interleave actions for different subgoals.
  • Goal ordering matters in goal stack planning. Different orders of the conjuncts can lead to different search paths, extra actions, or backtracking.

How it works

Goal stack planning is best understood as a loop over a stack. The planner keeps a current state and a stack whose top item is processed next.

  1. Initialize the stack with the overall goal.
  2. Inspect the top item.
  3. If the top item is a goal:
    • If the goal is already satisfied in the current state, pop it.
    • If the goal is a compound conjunction, push its conjuncts as subgoals in a chosen order. Because the stack is LIFO, the last conjunct pushed is processed first.
    • If the goal is a simple unsatisfied literal, find an operator whose add list contains that literal. Push the operator, then push the operator’s preconditions as subgoals. The operator stays below its preconditions.
  4. If the top item is an operator:
    • If all preconditions are satisfied, apply the operator: delete its delete-list propositions from the state and add its add-list propositions. Then pop the operator.
    • If some preconditions are not satisfied, push those unsatisfied preconditions as subgoals.
  5. Repeat until the stack is empty. If the final state satisfies the original goal, the sequence of applied operators is a plan.
  6. If a chosen operator leads to failure, the planner may backtrack and try another operator or another ordering of subgoals.

Means-ends analysis is a more general control strategy. It first computes the difference between the current state and the goal. It then selects an operator known to reduce that difference.
If the operator cannot be applied, the missing preconditions become subgoals; this is operator subgoaling. Goal stack planning can be viewed as one implementation mechanism for such subgoal processing.

Figure. Notice the repeated return to inspecting the top item after popping a satisfied goal, pushing subgoals or preconditions, and applying an operator. For an operator, satisfied preconditions lead to applying it and popping; unsatisfied ones are pushed.

Formulas

  • Let SS be the current state, represented as a set of true propositions. Let Pre(a)Pre(a), Add(a)Add(a), and Del(a)Del(a) be the precondition set, add list, and delete list of action aa.

  • An action aa is applicable in state SS exactly when: Pre(a)⊆SPre(a)\subseteq S

  • After applying an applicable action aa, the new state is: S′=(S∖Del(a))∪Add(a)S'=(S\setminus Del(a))\cup Add(a)

  • Here S∖Del(a)S\setminus Del(a) removes the deleted propositions, and ∪Add(a)\cup Add(a) adds the new propositions. If a proposition appears in both lists, the set formula lets the add list win; standard STRIPS examples avoid this overlap.

  • A goal GG is satisfied in state SS when: G⊆SG\subseteq S

  • For a conjunctive goal G1∧G2∧⋯∧GnG_1\land G_2\land\cdots\land G_n, every GiG_i must hold in the final state.

Worked examples

Example 1: STRIPS state update.
An action has preconditions {P,Q}\{P,Q\}, add list {R}\{R\}, and delete list {P}\{P\}. The current state is {P,Q,S}\{P,Q,S\}.
Check applicability: {P,Q}⊆{P,Q,S}\{P,Q\}\subseteq\{P,Q,S\}, so the action is applicable.
Compute: S′=({P,Q,S}∖{P})∪{R}={Q,S,R}S'=(\{P,Q,S\}\setminus\{P\})\cup\{R\}=\{Q,S,R\}.
Final state: {Q,S,R}\{Q,S,R\}.

Example 2: Goal stack pop count.
A stack contains, from bottom to top, [G1,G2,O1,G3][G_1,G_2,O_1,G_3]. The top item G3G_3 is a goal already satisfied in the current state, so it is popped. The next top item is the operator O1O_1.
Number of goal items popped before O1O_1 is processed: 11.

Example 3: Interacting operators.
Op1 has precondition {P}\{P\}, add {Q}\{Q\}, delete {P}\{P\}. Op2 has precondition {Q}\{Q\}, add {P}\{P\}, delete {Q}\{Q\}. The initial state is {P}\{P\}, and the goal is {P,Q}\{P,Q\}.
Apply Op1: state becomes {Q}\{Q\}. Apply Op2: state becomes {P}\{P\}. This cycles forever. No state contains both PP and QQ.
Final answer: no plan exists using only these two operators. This illustrates that achieving subgoals one by one can destroy an earlier subgoal.

Example 4: Match-the-list style.
Match: A. Precondition, B. Add list, C. Delete list, D. Goal stack.
Definitions: i. propositions made false by an action; ii. propositions that must hold before an action; iii. propositions made true by an action; iv. a LIFO list of goals and operators.
Correct matching: A-ii, B-iii, C-i, D-iv.

Example 5: Sussman anomaly.
Initial blocks world: CC on AA, AA on table, BB on table. Goal: ON(A,B)ON(A,B) and ON(B,C)ON(B,C).
If the planner first achieves ON(A,B)ON(A,B), it may move CC off AA, then stack AA on BB. Now BB is not clear, so to achieve ON(B,C)ON(B,C) it must unstack AA, stack BB on CC, and then restack AA on BB.
A better non-linear order is: move CC off AA, stack BB on CC, then stack AA on BB.
The anomaly shows that independent subgoal solving in a fixed order can be inefficient or can fail without reconsideration.

Comparison

ConceptMeaningKey exam point
PreconditionMust hold before actionCheck before applying action
Add listPropositions made trueAdded after deletion
Delete listPropositions made falseRemoved before addition
Goal stackLIFO list of goals and operatorsOrder of pushing affects search
Goal stack planningMeans-ends analysis
Uses a stack of goals and operatorsUses differences between current and goal state
Achieves goals by pushing subgoals and operatorsSelects operator to reduce a difference
Operator subgoaling is a step inside itOperator subgoaling is central to the strategy
Can suffer from bad conjunct orderingAlso needs subgoal interaction handling
Linear planNon-linear plan
Totally ordered sequence of actionsPartial order; some actions may interleave
Every action is before the nextNot every pair is ordered
Simple to executeBetter for interacting subgoals
Planning systemReactive agent
Builds a multi-step plan using a world modelMaps perception directly to action
Deliberative and future-orientedStimulus-response style
Can reason about preconditions and effectsUsually does not construct a plan

Revision summary

  • STRIPS is action-centric, not feature-centric.
  • Precondition = must be true; Add = becomes true; Delete = becomes false.
  • Apply action only if Pre(a)⊆SPre(a)\subseteq S.
  • State update: remove delete list, then add add list.
  • Closed-world assumption: unlisted propositions are false.
  • Goal stack is LIFO; last pushed item is processed first.
  • For a conjunction, push conjuncts as subgoals; ordering matters.
  • Operator subgoaling selects an operator and then sets subgoals for its preconditions.
  • Means-ends analysis centers on differences between current state and goal.
  • Sussman anomaly shows independent subgoal solving can fail when subgoals interact.
  • Blocks world is used to explain planning systems.
  • Linear plan = fixed total order; non-linear plan = partial order.

Previous-year exam insights

  • Direct concept questions ask what a planning system does, what a plan is, and which information an action description specifies.
  • STRIPS questions test the action-centric representation and the roles of precondition, add list, and delete list.
  • History-based questions test that STRIPS was developed at SRI for Shakey and is not a natural language processing formalism.
  • Match-the-list questions pair initial state, goal description, action, plan, precondition, add list, delete list, and goal stack with their definitions.
  • Statement and assertion-reason questions test Sussman anomaly, goal-stack ordering, linear plans, and independent subgoal solving.
  • Numeric questions ask for the resulting state after a STRIPS action or the number of stack items popped before an operator is processed.
  • A common trap is reversing add and delete lists, or applying an action without checking its preconditions.
  • Another trap is treating goal stack planning as always complete without backtracking; interacting subgoals can require reordering.

Practice at PARIKSHA

You are ready for the PARIKSHA tests of this sub-topic when you can:

  • Define a planning problem using initial state, goal description, actions, and plan.
  • Write a STRIPS operator with preconditions, add list, and delete list for a simple action.
  • Apply a STRIPS action to a state and compute the new state correctly.
  • Trace a goal stack through several push and pop steps on a small block-world goal.
  • Explain the difference between means-ends analysis and goal stack planning.
  • Explain operator subgoaling in your own words.
  • Describe the Sussman anomaly and why non-linear planning helps.
  • Distinguish linear plans from partial-order plans.
  • Match planning terms such as precondition, add list, delete list, and goal stack with definitions.
  • Identify the correct plan or failure when two operators interfere with each other.

Attempt the sub-topic test first, then the subject test.

Pages 1–2 of 2