Core definitions for the STRIPS formalism #
We define some basic definitions of the STRIPS formalism for automated planning (TODO : cite).
This file only contains the definitions that belong to the trusted core of the project,
i.e. definitions that are needed to define planning problems themselves and unsolvability
of planning problems. Additional definitions can be found in Validator.PlanningTask.Basic.
Implementation Notes #
Some definitions in this file have two version:
- an primed version which uses a representation that is efficient for representing instances at run-time, and
- an unprimed version which is more suited for theoretical results (usually using
Finset).
Exceptions are Action and STRIPS which can be used for both purposes.
Sets of variables #
Variables have type Fin n, and sets of variables therefore have type Finset(Fin n).
At runtime we use an Array instead of Finset.
Equations
- Validator.convertVarSet V = ↑(↑V).toFinset
Instances For
States and sets of states #
From a theoretical perspective states are just set of variables, but at runtime they are represented by a vector with boolean values to indicate which variables are in the set.
TODO : sets of states at runtime
Actions and sets of actions #
Actions in the STRIPS formalism
- name : String
The name of the action.
- pre' : VarSet' n
The preconditions of the action. See
Action.prefor the version usingVarSet. - add' : VarSet' n
The adding effects of the action. See
Action.addfor the version usingVarSet. - del' : VarSet' n
The deleting effects of the action. See
Action.prefor the version usingVarSet. - cost : ℕ
The cost of the action.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- Validator.instReprAction = { reprPrec := Validator.instReprAction.repr }
Equations
Instances For
Equations
Instances For
Equations
Instances For
Equations
Instances For
Equations
Instances For
Applicability and successor states #
An action is applicable in a state if all its preconditions are true in the state.
Equations
- Validator.Applicable s a = (a.pre ⊆ s)
Instances For
STRIPS planning problems #
A planning problem in the STRIPS formalism. The variables of the planning task are all elements of
Fin n.
The names of the variables.
- actions' : Actions' n
The actions of the planning problem. See
STRIPS.actionsfor the version usingActions. - init' : State' n
The initial state of the planning problem. See
STRIPS.initfor the version usingState. - goal' : VarSet' n
The goal of the planning problem, indicating which variables need to be true in a goal state. See also
GoalStateandSTRIPS.goal_statesinValidator.PlanningTask.Basic.
Instances For
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- Validator.instReprSTRIPS = { reprPrec := Validator.instReprSTRIPS.repr }
Equations
- pt.actions = ↑(List.toFinset pt.actions')
Instances For
Equations
- pt.init = Validator.convertState pt.init'
Instances For
Paths in state space and plans #
Given a STRIPS planning task pt, Path s1 s2 is a path form the state s1 to the state s2
in the state space of pt.
- empty
{n : ℕ}
{pt : STRIPS n}
(s : State n)
: Path pt s s
The empty path consisting of a single node
s. - cons
{n : ℕ}
{pt : STRIPS n}
(a : Action n)
{s1 : State n}
(s2 : State n)
{s3 : State n}
(ha : a ∈ pt.actions)
(succ : Successor a s1 s2)
(π : Path pt s2 s3)
: Path pt s1 s3
The path consisting of the node
s, and the pathπ, wheres[a]is the first node ofπ.
Instances For
Unsolvability #
A state is unsolvable if there is no plan for that state.
Equations
- Validator.UnsolvableState pt s = IsEmpty (Validator.Plan pt s)
Instances For
A planning task is unsolvable if the initial state is unsolvable.