OptaPlanner logo
  • Download
  • Learn
    • Documentation
    • Videos
    • Slides
    • Training

    • Use cases
    • Compatibility
    • Testimonials and case studies
  • Get help
  • Blog
  • Source
  • Team
  • Services
  • KIE
    • Drools
    • OptaPlanner
    • jBPM
    • Kogito
  • Star
  • T
  • L
  • F
  • YT
Fork me on GitHub

Solve planning and scheduling problems with OptaPlanner

An easy-to-use, open source constraint solver with AI algorithms

Video thumbnail
Download
Try OptaPlanner
Download 8.14.0.Final
  1. Download and unzip.
  2. Run runQuickstarts.sh (Linux/macOS)
    or runQuickstarts.bat (Windows).
Requires JDK 11 or higher to run.
Documentation
Get started
User guide 8.14.0.Final
Clone the Quickstarts code.

What can OptaPlanner do?

OptaPlanner optimizes plans and schedules with hard constraints and soft constraints.
It reduces costs substantially, improves service quality, fulfills employee wishes and lowers carbon emissions.

Vehicle routing (VRP)

Quicker routes for a fleet of vehicles.

Learn more
Employee rostering

Assign shifts to employees by skills and availability.

Learn more
Maintenance scheduling

Timely upkeep of machinery and equipment.

Learn more
Conference scheduling

Schedule speakers and talks by availability and topic.

Learn more
School timetabling

Compacter schedules for teachers and students.

Learn more
Task assignment

Assign tasks by priority, skills and affinity.

Learn more
Cloud optimization

Bin packing and defragmentation of cloud resources.

Learn more
Job shop scheduling

Reduce makespan for assembly lines.

Learn more

Modern mathematical optimization

OptaPlanner is a lightweight, embeddable planning engine. It enables everyday programmers to solve optimization problems efficiently. Constraints apply on plain domain objects and can call existing code. It is Object Oriented Programming (OOP) and Functional Programming (FP) friendly. There’s no need to input constraints as mathematical equations.

OptaPlanner supports
  • Continuous planning to weekly publish the schedule, 3 weeks before execution
  • Non-disruptive replanning for changes to an already published schedule
  • Real-time planning to react on real-time disruptions in the plan within milliseconds
  • Overconstrained planning when there are too few resources to cover all the work
  • Pinning so the user is still in control over the schedule

Under the hood, OptaPlanner combines sophisticated Artificial Intelligence optimization algorithms (such as Tabu Search, Simulated Annealing, Late Acceptance and other metaheuristics) with very efficient score calculation and other state-of-the-art constraint solving techniques for NP-complete or NP-hard problems.

Compatibility

OptaPlanner works directly from:
  • Java
  • Kotlin
  • Scala
  • Python (experimental)
OptaPlanner integrates seamlessly with:
  • Quarkus
  • Spring Boot
For a full Business Automation stack, combine OptaPlanner with:
  • workflows and processes in Kogito
  • decision tables and DMN in Drools

OptaPlanner is open source software, released under the Apache License.

Code example

To optimize a problem from Java™ code, add the optaplanner-core jar and call Solver.solve():

SolverFactory<MyRoster> factory = SolverFactory.create(...);

// My domain specific class as input
MyRoster problem = ...;

Solver<MyRoster> solver = factory.buildSolver();
// My domain specific class as output
MyRoster solution = solver.solve(problem);

for (MyShift shift : solution.getShifts()) {
    // Each shift is now assigned to an employee
    assertNotNull(shift.getEmployee());
}

Try the hello world application.

Latest blog posts
  • OptaPlanner documentation turns over a new leaf
    Tue 26 October 2021
    Radovan Synek
  • Order picking optimization in warehouses and supermarkets with OptaPlanner
    Thu 14 October 2021
    Walter Medvedeo
  • Monitor OptaPlanner solvers through Micrometer
    Tue 12 October 2021
    Christopher Chianelli
  • A new AI constraint solver for Python: OptaPy
    Tue 5 October 2021
    Christopher Chianelli
  • How much faster is Java 17?
    Wed 15 September 2021
    Geoffrey De Smet
  • Constraint Streams get some more love
    Thu 19 August 2021
    Lukáš Petrovický
  • Let’s OptaPlan your jBPM tasks (part 2) - BPM Task assigning in the cloud
    Mon 26 July 2021
    Walter Medvedeo
  • Blog archive
Latest videos
  • AI lesson scheduling on Quarkus with OptaPlanner
    Thu 18 November 2021
    Geoffrey De Smet
  • Maintenance scheduling
    Fri 12 November 2021
    Geoffrey De Smet
  • Optimized order picking in warehouses and supermarkets
    Tue 26 October 2021
    Walter Medvedeo
  • A modern OO/FP constraint solver
    Tue 14 September 2021
    Geoffrey De Smet
  • Business processes task optimization in Kogito
    Tue 7 September 2021
    Walter Medvedeo
  • School timetable optimization
    Mon 6 September 2021
    Geoffrey De Smet
  • Schedule incoming calls real-time
    Mon 23 August 2021
    Radovan Synek
  • Video archive
Upcoming events
  • DevConf.CZ
    Brno, Czech Republic (virtual) - Fri 28 January 2022
    • Artificial Intelligence on Quarkus: I love it when an OptaPlan comes together by Geoffrey De Smet
  • JFokus
    Stockholm, Sweden - Mon 7 February 2022
    • AI maintenance scheduling with OptaPlanner on Quarkus by Geoffrey De Smet
  • Add event / Archive
Latest release
  • 8.14.0.Final released
    Wed 8 December 2021
Paid support and consulting

Want to talk to the experts? Red Hat offers certified binaries with enterprise consulting. Contact optaplanner-info for more information.

OptaPlanner is open. All dependencies of this project are available under the Apache Software License 2.0 or a compatible license. OptaPlanner is trademarked.

This website was built with JBake and is open source.

Community

  • Blog
  • Get Help
  • Team
  • Governance
  • Academic research

Code

  • Build from source
  • Issue tracker
  • Release notes
  • Upgrade recipes
  • Logo and branding

KIE projects

  • Drools rule engine
  • OptaPlanner constraint solver
  • jBPM workflow engine
  • Kogito Business Automation platform
CC by 3.0 | Privacy Policy
Sponsored by Red Hat