14 lines
398 BLFS
Plaintext
14 lines
398 BLFS
Plaintext
name: generate-plan
|
|
description: Generate a plan for a PDDL problem object.
|
|
inputs:
|
|
- problem: unified_planning problem object
|
|
outputs:
|
|
- plan: plan object
|
|
implementation: python
|
|
script: |
|
|
def skill(problem):
|
|
from unified_planning.shortcuts import OneshotPlanner
|
|
with OneshotPlanner(name="pyperplan") as planner:
|
|
result = planner.solve(problem)
|
|
return result.plan
|