first principles planning in bdi systems
play

First Principles Planning in BDI Systems Sebastian Sardina - PowerPoint PPT Presentation

First Principles Planning in BDI Systems Sebastian Sardina Department of Computer Science and Information Technology RMIT University, Melbourne, Australia Joint work with Lavindra de Silva and Lin Padgham 1 / 25 Motivation The B elief, D


  1. A Mars Rover BDI Agent ExploreSoilLocation (? dst ) Event-goal P 0 − → BDI plan Navigate (? src , ? dst ) PerformSoilExperiment (? dst ) Action P 1 − → Move (? src , ? dst ) Calibrate P 2 − → ObtainSoilResults (? dst ) TransmitSoilResults (? dst ) P 3 − → PickSoilSample (? dst ) AnalyseSoilSample (? dst ) DropSoilSample P 5 − → P 4 SendResults (? dst ) EstablishConn BreakConn − → GetMoistureContent (? dst ) GetSoilParticleSize (? dst ) 14 / 25

  2. A Mars Rover BDI Agent ExploreSoilLocation (? dst ) Event-goal P 0 − → BDI plan Navigate (? src , ? dst ) PerformSoilExperiment (? dst ) Action P 1 − → Move (? src , ? dst ) Calibrate P 2 − → ObtainSoilResults (? dst ) TransmitSoilResults (? dst ) P 3 − → PickSoilSample (? dst ) AnalyseSoilSample (? dst ) DropSoilSample P 5 − → P 4 SendResults (? dst ) EstablishConn BreakConn − → GetMoistureContent (? dst ) GetSoilParticleSize (? dst ) 14 / 25

  3. A Mars Rover BDI Agent ExploreSoilLocation (? dst ) Event-goal P 0 − → BDI plan Navigate (? src , ? dst ) PerformSoilExperiment (? dst ) Action P 1 − → Move (? src , ? dst ) Calibrate P 2 − → ObtainSoilResults (? dst ) TransmitSoilResults (? dst ) P 3 − → PickSoilSample (? dst ) AnalyseSoilSample (? dst ) DropSoilSample P 5 − → P 4 SendResults (? dst ) EstablishConn BreakConn − → GetMoistureContent (? dst ) GetSoilParticleSize (? dst ) 14 / 25

  4. A Mars Rover BDI Agent ExploreSoilLocation (? dst ) Event-goal P 0 − → BDI plan Navigate (? src , ? dst ) PerformSoilExperiment (? dst ) Action P 1 − → Move (? src , ? dst ) Calibrate P 2 − → ObtainSoilResults (? dst ) TransmitSoilResults (? dst ) P 3 − → PickSoilSample (? dst ) AnalyseSoilSample (? dst ) DropSoilSample P 5 − → P 4 SendResults (? dst ) EstablishConn BreakConn − → GetMoistureContent (? dst ) GetSoilParticleSize (? dst ) 14 / 25

  5. A Mars Rover BDI Agent ExploreSoilLocation (? dst ) Event-goal P 0 − → BDI plan Navigate (? src , ? dst ) PerformSoilExperiment (? dst ) Action P 1 − → Move (? src , ? dst ) Calibrate P 2 − → ObtainSoilResults (? dst ) TransmitSoilResults (? dst ) P 3 − → PickSoilSample (? dst ) AnalyseSoilSample (? dst ) DropSoilSample P 5 − → P 4 SendResults (? dst ) EstablishConn BreakConn − → GetMoistureContent (? dst ) GetSoilParticleSize (? dst ) 14 / 25

  6. Hybrid-Solutions in the Mars Rover Goal state = locations rock 2 and rock 3 have been explored. 1. Navigate(rock1, rock2) 2. PerformSoilExperiment(rock2) 3. Navigate(rock2, rock3) 4. PerformSoilExperiment(rock3) Hybrid-solution h 15 / 25

  7. Hybrid-Solutions in the Mars Rover Goal state = locations rock 2 and rock 3 have been explored. 1. Navigate(rock1, rock2) (A) Calibrate (B) Move(rock1, rock2) 2. PerformSoilExperiment(rock2) (A) ObtainSoilResults(rock2) 1. Navigate(rock1, rock2) (i) PickSoilSample(rock2) 2. PerformSoilExperiment(rock2) (ii) AnalyseSoilSample(rock2) 3. Navigate(rock2, rock3) (a) GetMoistureContent(rock2) 4. PerformSoilExperiment(rock3) (b) GetSoilParticleSize(rock2) (iii) DropSoilSample (B) TransmitSoilResults(rock2) (i) EstablishConn (ii) SendResults(rock2) (iii) BreakConn 3. Navigate(rock2, rock3) (A) Calibrate (B) Move(rock2, rock3) 4. PerformSoilExperiment(rock3) (A) ObtainSoilResults(rock3) (i) PickSoilSample(rock3) (ii) AnalyseSoilSample(rock3) (a) GetMoistureContent(rock3) (b) GetSoilParticleSize(rock3) (iii) DropSoilSample (B) TransmitSoilResults(rock3) (i) EstablishConn (ii) SendResults(rock3) (iii) BreakConn Hybrid-solution h Execution of h 15 / 25

  8. Hybrid-Solutions in the Mars Rover Goal state = locations rock 2 and rock 3 have been explored. 1. Navigate(rock1, rock2) (A) Calibrate (B) Move(rock1, rock2) 2. PerformSoilExperiment(rock2) (A) ObtainSoilResults(rock2) 1. Navigate(rock1, rock2) (i) PickSoilSample(rock2) 2. PerformSoilExperiment(rock2) (ii) AnalyseSoilSample(rock2) 3. Navigate(rock2, rock3) (a) GetMoistureContent(rock2) 4. PerformSoilExperiment(rock3) (b) GetSoilParticleSize(rock2) (iii) DropSoilSample (B) TransmitSoilResults(rock2) (i) EstablishConn (ii) SendResults(rock2) (iii) BreakConn ⇐ redundant 3. Navigate(rock2, rock3) (A) Calibrate (B) Move(rock2, rock3) 4. PerformSoilExperiment(rock3) (A) ObtainSoilResults(rock3) (i) PickSoilSample(rock3) (ii) AnalyseSoilSample(rock3) (a) GetMoistureContent(rock3) takes too long (b) GetSoilParticleSize(rock3) (iii) DropSoilSample (B) TransmitSoilResults(rock3) (i) EstablishConn ⇐ redundant (ii) SendResults(rock3) (iii) BreakConn Hybrid-solution h Execution of h 15 / 25

  9. Hybrid-Solutions in the Mars Rover Goal state = locations rock 2 and rock 3 have been explored. 1. Navigate(rock1, rock2) (A) Calibrate (B) Move(rock1, rock2) 2. PerformSoilExperiment(rock2) 1. Navigate(rock1, rock2) (A) ObtainSoilResults(rock2) 2. ObtainSoilResults(rock2) 1. Navigate(rock1, rock2) (i) PickSoilSample(rock2) 3. EstablishConn 2. PerformSoilExperiment(rock2) (ii) AnalyseSoilSample(rock2) 4. SendResults(rock2) 3. Navigate(rock2, rock3) (a) GetMoistureContent(rock2) 5. Navigate(rock2, rock3) 4. PerformSoilExperiment(rock3) (b) GetSoilParticleSize(rock2) 6. ObtainSoilResults(rock3) (iii) DropSoilSample 7. SendResults(rock3) (B) TransmitSoilResults(rock2) 8. BreakConn (i) EstablishConn ⇑ Non-redundant + maximally- (ii) SendResults(rock2) abstract (iii) BreakConn ⇐ redundant 3. Navigate(rock2, rock3) (A) Calibrate (B) Move(rock2, rock3) 4. PerformSoilExperiment(rock3) (A) ObtainSoilResults(rock3) (i) PickSoilSample(rock3) (ii) AnalyseSoilSample(rock3) (a) GetMoistureContent(rock3) takes too long (b) GetSoilParticleSize(rock3) (iii) DropSoilSample (B) TransmitSoilResults(rock3) (i) EstablishConn ⇐ redundant (ii) SendResults(rock3) (iii) BreakConn Hybrid-solution h ′ Hybrid-solution h Execution of h 15 / 25

  10. Creating Abstract Operators We translate event-goals into abstract planning operators by using an adaptation and extension of the “summary algorithms” of [Clement&Durfee,07]. 16 / 25

  11. Creating Abstract Operators We translate event-goals into abstract planning operators by using an adaptation and extension of the “summary algorithms” of [Clement&Durfee,07]. • The name of the event-goal becomes the name of the operator. • The disjunction of the context conditions of the event-goal’s associated plans are taken as the precondition of the operator. • The postcondition of an operator is computed based on the structure of the corresponding event-goal’s hierarchy, combined with knowledge about the effects of primitive actions. • In particular, we use the definite effects of event-goals as the postconditions of operators. 16 / 25

  12. Computing Preconditions and Postconditions e 3 Event-goal OR BDI plan φ 1 P 1 φ 2 P 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  13. Computing Preconditions and Postconditions e 3 φ 1 ∨ φ 2 Event-goal OR BDI plan φ 1 P 1 φ 2 P 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  14. Computing Preconditions and Postconditions e 3 φ 1 ∨ φ 2 Event-goal OR BDI plan φ 1 P 1 φ 2 P 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  15. Computing Preconditions and Postconditions e 3 φ 1 ∨ φ 2 Event-goal OR BDI plan P 1 ¬ r φ 1 φ 2 P 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  16. Computing Preconditions and Postconditions e 3 φ 1 ∨ φ 2 Event-goal OR BDI plan P 1 ¬ r φ 1 φ 2 P 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  17. Computing Preconditions and Postconditions e 3 φ 1 ∨ φ 2 Event-goal OR BDI plan P 1 ¬ r P 2 q ∧ ¬ r φ 1 φ 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  18. Computing Preconditions and Postconditions e 3 φ 1 ∨ φ 2 Event-goal OR BDI plan P 1 ¬ r P 2 q ∧ ¬ r φ 1 φ 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  19. Computing Preconditions and Postconditions e 3 ¬ r φ 1 ∨ φ 2 Event-goal OR BDI plan P 1 ¬ r P 2 q ∧ ¬ r φ 1 φ 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r 17 / 25

  20. Computing Preconditions and Postconditions e 3 ¬ r φ 1 ∨ φ 2 Event-goal OR BDI plan P 1 ¬ r P 2 q ∧ ¬ r φ 1 φ 2 → Action a 1 ¬ r a 2 q ∧ r a 1 ¬ r Abstract operators computed are used for first principles planning. Hybrid-plans obtained need to be validated because we do not take into account possible effects (e.g., q ) of event-goals. 17 / 25

  21. Basic Notions for Hybrid-Solutions Definition (Perfect Justification [Fink & Yang,‘92]) A primitive solution σ for some planning problem is a perfect justification if there does not exist a proper subsequence σ ′ of σ such that σ ′ is a primitive solution for the problem. 18 / 25

  22. Basic Notions for Hybrid-Solutions Definition (Perfect Justification [Fink & Yang,‘92]) A primitive solution σ for some planning problem is a perfect justification if there does not exist a proper subsequence σ ′ of σ such that σ ′ is a primitive solution for the problem. Definition (Non-redundant Hybrid-Solutions) A hybrid-solution is a non-redundant hybrid-solution if it can produce at least one perfect justification via decomposition. 18 / 25

  23. Basic Notions for Hybrid-Solutions Definition (Perfect Justification [Fink & Yang,‘92]) A primitive solution σ for some planning problem is a perfect justification if there does not exist a proper subsequence σ ′ of σ such that σ ′ is a primitive solution for the problem. Definition (Non-redundant Hybrid-Solutions) A hybrid-solution is a non-redundant hybrid-solution if it can produce at least one perfect justification via decomposition. Definition (Maximally-Abstract) A hybrid-plan h is maximally-abstract if there is no other hybrid-plan h ′ such that one can reach h from h ′ via decomposition, and h ′ produces any of the solutions of interest that are produced by h . 18 / 25

  24. Basic Notions for Hybrid-Solutions Definition (Perfect Justification [Fink & Yang,‘92]) A primitive solution σ for some planning problem is a perfect justification if there does not exist a proper subsequence σ ′ of σ such that σ ′ is a primitive solution for the problem. Definition (Non-redundant Hybrid-Solutions) A hybrid-solution is a non-redundant hybrid-solution if it can produce at least one perfect justification via decomposition. Definition (Maximally-Abstract) A hybrid-plan h is maximally-abstract if there is no other hybrid-plan h ′ such that one can reach h from h ′ via decomposition, and h ′ produces any of the solutions of interest that are produced by h . Ideal hybrid-solution = non-redundant + maximally-abstract 18 / 25

  25. Results Theorem 1 Whenever a hybrid planning problem can be solved, there is at least one ideal hybrid-solution. • Unfortunately, it is not clear how ideal hybrid-solutions can be computed in polynomial time. • Instead, we focus on improving a given hybrid-solution. • To this end, we extract a non-redundant and most abstract hybrid-solution from the decomposition tree. • An improvement of a hybrid-solution is called a preferred specialization. 19 / 25

  26. Example Consider initial state p and goal state t . e 0 e 5 Event-goal P 0 P 6 BDI plan − → − → e 1 e 2 s a 5 r s a 6 t Action P 1 P 2 − → p a 1 q ∧ u e 3 e 4 OR P 3 P 4 P 5 − → q a 3 r p a 2 q q a 3 r r a 4 s Hybrid-solution Non-redundant Maximally-absract Ideal √ √ √ e 2 · a 6 √ e 0 · e 5 × × √ e 1 · e 2 · a 6 × × e 0 · a 5 · a 6 × × × 20 / 25

  27. Example Consider initial state p and goal state t . e 0 e 5 Event-goal P 0 P 6 BDI plan − → − → e 1 e 2 s a 5 r s a 6 t Action P 1 P 2 − → p a 1 q ∧ u e 3 e 4 OR P 3 P 4 P 5 − → q a 3 r p a 2 q q a 3 r r a 4 s Hybrid-solution Non-redundant Maximally-absract Ideal √ √ √ e 2 · a 6 √ e 0 · e 5 × × √ e 1 · e 2 · a 6 × × e 0 · a 5 · a 6 × × × 20 / 25

  28. Example Consider initial state p and goal state t . e 0 e 5 Event-goal P 0 P 6 BDI plan − → − → e 1 e 2 s a 5 r s a 6 t Action P 1 P 2 − → p a 1 q ∧ u e 3 e 4 OR P 3 P 4 P 5 − → q a 3 r p a 2 q q a 3 r r a 4 s Hybrid-solution Non-redundant Maximally-absract Ideal √ √ √ e 2 · a 6 √ e 0 · e 5 × × √ e 1 · e 2 · a 6 × × e 0 · a 5 · a 6 × × × 20 / 25

  29. Example Consider initial state p and goal state t . e 0 e 5 Event-goal P 0 P 6 BDI plan − → − → e 1 e 2 s a 5 r s a 6 t Action P 1 P 2 − → p a 1 q ∧ u e 3 e 4 OR P 3 P 4 P 5 − → q a 3 r p a 2 q q a 3 r r a 4 s Hybrid-solution Non-redundant Maximally-absract Ideal √ √ √ e 2 · a 6 √ e 0 · e 5 × × √ e 1 · e 2 · a 6 × × e 0 · a 5 · a 6 × × × 20 / 25

  30. Example Consider initial state p and goal state t . e 0 e 5 Event-goal P 0 P 6 BDI plan − → − → e 1 e 2 s a 5 r s a 6 t Action P 1 P 2 − → p a 1 q ∧ u e 3 e 4 OR P 3 P 4 P 5 − → q a 3 r p a 2 q q a 3 r r a 4 s Hybrid-solution Non-redundant Maximally-absract Ideal √ √ √ e 2 · a 6 √ e 0 · e 5 × × √ e 1 · e 2 · a 6 × × e 0 · a 5 · a 6 × × × 20 / 25

  31. Example Consider initial state p and goal state t . e 0 e 5 Event-goal P 0 P 6 BDI plan − → − → e 1 e 2 s a 5 r s a 6 t Action P 1 P 2 − → p a 1 q ∧ u e 3 e 4 OR P 3 P 4 P 5 − → q a 3 r p a 2 q q a 3 r r a 4 s Hybrid-solution Non-redundant Maximally-absract Ideal √ √ √ e 2 · a 6 √ e 0 · e 5 × × √ e 1 · e 2 · a 6 × × e 0 · a 5 · a 6 × × × 20 / 25

  32. Example Consider initial state p and goal state t . e 0 e 5 Event-goal P 0 P 6 BDI plan − → − → e 1 e 2 s a 5 r s a 6 t Action P 1 P 2 − → p a 1 q ∧ u e 3 e 4 OR P 3 P 4 P 5 − → q a 3 r p a 2 q q a 3 r r a 4 s Hybrid-solution Non-redundant Maximally-absract Ideal √ √ √ e 2 · a 6 √ e 0 · e 5 × × √ e 1 · e 2 · a 6 × × e 0 · a 5 · a 6 × × × 20 / 25

  33. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  34. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  35. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  36. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  37. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  38. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  39. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 4 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  40. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 4 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  41. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 4 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  42. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 5 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  43. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 5 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  44. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 5 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  45. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 6 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  46. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 6 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  47. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 7 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  48. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 7 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  49. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 7 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  50. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  51. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 2 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  52. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 2 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  53. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 2 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  54. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 3 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  55. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 3 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  56. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  57. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 1 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  58. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . u= e 1 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  59. Preferred Specializations Find-Preferred-Specialization( h , H , T ) e 1 h= 1 Input : Hybrid-solution h ; hybrid problem H ; and ∈ π decomposition tree T of h . 2 Output : A preferred specialization of h w.r.t. H and T . 3 σ ⇐ leaf-level primitive solution in T . e 1 4 σ ′ ⇐ Get-Perfect-Justification ( σ, H ). 5 π ⇐ { a i | a i ∈ σ ′ } e 2 e 3 6 for ℓ ⇐ 1 to height ( T ) do e 4 e 5 e 6 e 7 • for each node u at level ℓ in tree T do if children ( u , T ) ⊆ π , then π ⇐ ( π \ children ( u , T )) ∪ { u } a 1 a 2 a 3 a 4 a 5 a 6 a 7 a 8 7 Return π 21 / 25

  60. Results Theorem 2 Given a perfect justification, the algorithm computes a preferred specialization in polynomial time on the size of the given decomposition tree. 22 / 25

  61. Results Theorem 2 Given a perfect justification, the algorithm computes a preferred specialization in polynomial time on the size of the given decomposition tree. Theorem 3 Whenever a hybrid-solution exists for some hybrid planning problem, there is at least one preferred specialisation for some decomposition tree of the hybrid-solution. 22 / 25

  62. Results Theorem 2 Given a perfect justification, the algorithm computes a preferred specialization in polynomial time on the size of the given decomposition tree. Theorem 3 Whenever a hybrid-solution exists for some hybrid planning problem, there is at least one preferred specialisation for some decomposition tree of the hybrid-solution. Theorem 4 Whenever an ideal hybrid-solution occurs in a decomposition tree of a given hybrid-solution h , and the ideal hybrid-solution yields a perfect justification in the decomposition tree, then the ideal hybrid-solution is guaranteed to be a preferred specialisation of h . 22 / 25

  63. Conclusion • We provided algorithms for converting BDI event-goals into (abstract) planning operators. • We characterized different notions of “goodness” for hybrid-plans, such as non-redundancy and maximal-abstraction. • We proved certain properties of “good” hybrid-plans, in particular, that ideal hybrid-plans are also preferred specializations in certain situations. • We provided algorithms for obtaining preferred specializations. 23 / 25

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend