Drools Planner or automated planning optimizes the process including the NP-hard planning problems.