200 likes | 318 Views
Planning systems and its’ applications in software engineering. Sa ša Tošić , M. Ivanovi ć Risan , 2007. Contents. What are planning systems Agent planning package Planning systems and SE Example. What are planning systems?. Action-based systems that generates plans
E N D
Planning systems and its’ applications in software engineering Saša Tošić,M. Ivanović Risan, 2007
Contents • What are planning systems • Agent planning package • Planning systems and SE • Example
What are planning systems? • Action-based systems that generates plans • Plan is a sequence of parameterized actions which transforms initial states into a goal state • Planning formalisms and languages: Strips, ADL, PDDL … • PDDL (planning domain definition language): standard planning language
Example • Planning sequence • Plan: A(x, y), B(x, y), C(x, y) A(x, y) B(x,y) C(x, y) Goal State Initial State Temporary states
What do we need? • Planning instance • Planning Domain • Actions • Predicates • Functions • Types • Constants • Planning problem • Initial state of a system • Goal (set of tasks to be achieved)
Actions in planning systems • Actions in planning systems • Name • Parameters • Preconditions • Effects • Duration (default 1) • Cost, probability, …
APP – Agent planning package • Developed at University in Novi Sad • Helps to create intelligent agents • Domain independent planning system for PDDL2.1 • Written in Java in form of a Java package • Enables plan creation and execution
APP – Agent planning package • APP can handle several planning instances • Generated plans are part of a planning instance
APP – Agent planning package • Modules • Data manipulation • Plan searching • Plan execution and monitoring • Plan validation and verification
APP – Agent planning package • Types of a plan • SingleAction • Serial plan • Parallel plan • Alternative plan • Multiple plans • Plans can be mixed
Modeling and model checking • We can create a model of our software and check it • Modeling • Initial state must be modeled (using objects, constants, predicates, functions…) • One action in planning domain is one or more actions in our software
Model checking • Planning systems can check if actions are modeled well • Model checking • How we can do something in our software? • What is the plan for that goal? • How we can detect errors? • No plan (it is not possible to do it) • Invalid plan
Example • Planning sequence • Plan: A(x, y), B(x, y), C(x, y) A(x, y) B(x,y) C(x, y) Goal State Initial State Temporary states
Example • (action A :parameters (?x ?y – objects) :precondition (and (point ?x)) :effects (connected ?x ?y)) • (action B :parameters (?x ?y – objects) :precondition (selected ?x ?y) :effects (connected ?x ?y))
Example • (action C :parameters (?x ?y – objects) :precondition (connected ?x ?y) :effects (doneC)) • Initial state: (point x) (point y) • Goal: (doneC)
Example • Plan generated by APP: no plan is found • Reason: (action A :parameters (?x ?y – objects) :precondition (and (point ?x) (point ?y)) :effects (connected ?x ?y))
Example • Plan generated by APP: A(x, y), C(x, y) • Reason: (action A :parameters (?x ?y – objects) :precondition (and (point ?x)(point ?y)) :effects (selected ?x ?y))
Example • Plan generated by APP: • A(x, y), B(x, y), C(x, y) • APP can automatically create plans for large number of goals
Conclusion • Powerful tool for model checking • Detects different kinds of errors • Simulation of plan execution can help to detect errors
The End Thank you for your attention