This project is the bases for solver.planning.domains -- a web service that provides access to an automated planner. Please report any bugs or feature requests you may have on the [issue list] for the project.
This project should get you from zero to having your own hosted planner in the cloud (heroku to be specific) in under 5 minutes (yes, I've timed myself). It could be considerably less if you already have a heroku account and the appropriate software installed. The steps to having things setup and running are as follows:
git clone https://github.com/AI-Planning/cloud-solver.git; cd cloud-solver
heroku create
from the directory this file exists. Take note of the URL.git push heroku master
to deploy the software.Et voila! You now have your very own planner-in-the-cloud.
If you need to install dependencies such as libboost, you should:
heroku buildpacks:add --index 1 heroku-community/apt
Aptfile
, and enter the dependencies. For example:
libboost-python-dev
libboost-program-options-dev
git add Aptfile
git commit -am 'added apt dependencies'
git push heroku master
to deploy the dependencies.You can test things by running heroku open
and then appending the appropriate URL to solve a problem:
http://<your project name>.herokuapp.com/solve?domain=http://www.haz.ca/planning-domains/classical/blocks/domain.pddl&problem=http://www.haz.ca/planning-domains/classical/blocks/probBLOCKS-4-1.pddl
The most simple change -- putting in your own compiled planner -- can be done by modifying the ./plan
file, which is just a bash script that accepts the IPC-style command line (<planner> <domain> <problem> <output>
). This file also controls the time and memory resource limits allotted to the planner.
Most of the magic happens in web.js, routes.js, and process_solution.py. For example, the app.solve
method in web.js is what invokes the planner, and you can modify the command line string used, the timeout, etc. If you want to run some other planner or type of software, app.parsePlan
is the method that parses the output. It assumes that properly formatted JSON is sent to the standard output, and all you need to do is replace process_solution.py with your own script to parse any custom output of the planner / software.
heroku run
may need to change to heroku run:detached
to get some commands working if your proxy / firewall is particularly restrictive.There are none. Have fun, play nice, and feel free to share any cool things you create.