Choco3 is an open-source Java library for Constraint Programming.

Choco3 is not the continuation of Choco2, but a completely rewritten version and there is no backward compatibility.

Current stable version is 3.3.3 (22 Dec 2015).

Choco3 comes with:

Code Quality Rank: L3
Programming language: Java
License: BSD 4-Clause "Original" or "Old" License
Latest version: v4.10.10

Choco alternatives and similar libraries

Based on the "Constraint Satisfaction Problem Solver" category.
Alternatively, view Choco alternatives based on common mentions on social networks and blogs.

Do you think we are missing an alternative of Choco or a related project?

Add another 'Constraint Satisfaction Problem Solver' Library



Discord Maven Central javadoc.io

Build codecov.io Total alerts Codacy Badge

Choco-solver is an open-source Java library for Constraint Programming.

Current stable version is 4.10.10 (11 Oct 2022).

Choco-solver comes with:

  • various type of variables (integer, boolean, set, graph and real),
  • various state-of-the-art constraints (alldifferent, count, nvalues, etc.),
  • various search strategies, from basic ones (first_fail, smallest, etc.) to most complex (impact-based and activity-based search),
  • explanation-based engine, that enables conflict-based back jumping, dynamic backtracking and path repair,

But also, facilities to interact with the search loop, factories to help modelling, many samples, etc.

Choco-solver is distributed under BSD 4-Clause License (Copyright (c) 1999-2022, IMT Atlantique).



// 1. Create a Model
Model model = new Model("my first problem");
// 2. Create variables
IntVar x = model.intVar("X", 0, 5);
IntVar y = model.intVar("Y", 0, 5);
// 3. Create and post constraints thanks to the model
model.element(x, new int[]{5,0,4,1,3,2}, y).post();
// 3b. Or directly through variables
// 4. Get the solver
Solver solver = model.getSolver();
// 5. Define the search strategy
solver.setSearch(Search.inputOrderLBSearch(x, y));
// 6. Launch the resolution process
// 7. Print search statistics

Documentation, Support and Issues

The latest release points to binaries and source code.

You can get help on our google group. Most support requests are answered very fast.

Use the issue tracker here on GitHub to report issues. As far as possible, provide a Minimal Working Example.


Anyone can contribute to the project, from the source code to the documentation. In order to ease the process, we established a [contribution guide](CONTRIBUTING.md) that should be reviewed before starting any contribution as it lists the requirements and good practices to ease the contribution process.

And thank you for giving back to choco-solver. Please meet our team of cho-coders :

Supporting Choco with financial aid favors long-term support and development. Our expenses are varied: fees (GitHub organization, Domain name, etc), funding PhD students or internships, conferences, hardware renewal, ...


Download and installation


  • JDK 8+
  • maven 3+

Choco-solver is available on Maven Central Repository, or directly from the latest release.

Snapshot releases are also available for curious.

In the following, we distinguish two usages of Choco:

  • as a standalone library: the jar file includes all required dependencies,
  • as a library: the jar file excludes all dependencies.

The name of the jar file terms the packaging:

  • choco-solver-4.XX.Y-jar-with-dependencies.jar or
  • choco-solver-4.XX.Y.jar.
  • choco-parsers-4.XX.Y-jar-with-dependencies.jar or
  • choco-parsers-4.XX.Y-light.jar or
  • choco-parsers-4.XX.Y.jar.

The light tagged jar file is a version of the jar-with-dependencies one with dependencies from this archive.

A [Changelog file](./CHANGES.md) is maintained for each release.

Inside a maven project

Choco is available on Maven Central Repository. So you only have to edit your pom.xml to declare the following library dependency:


Note that if you want to test snapshot release, you should update your pom.xml with :


As a stand-alone library

The jar file contains all required dependencies. The next step is simply to add the jar file to your classpath of your application. Note that if your program depends on dependencies declared in the jar file, you should consider using choco as a library.

As a library

The jar file does not contains any dependencies, as of being used as a dependency of another application. The next step is to add the jar file to your classpath of your application and also add the required dependencies.


To declare continuous constraints, Ibex-2.8.7 needs to be installed (instructions are given on Ibex website).

Building from sources

The source of the released versions are directly available in the Tag section. You can also download them using github features. Once downloaded, move to the source directory then execute the following command to make the jar:

$ mvn clean package -DskipTests

If the build succeeded, the resulting jar will be automatically installed in your local maven repository and available in the target sub-folders.

Choco-solver dev team

*Note that all licence references and agreements mentioned in the Choco README section above are relevant to that project's source code only.