__ __
/ //_/__ ____ _____ __ __
/ ,< / _ \/ __ `/ __ \/ / / /
/ /| / __/ /_/ / / / / /_/ /
/_/ |_\___/\__,_/_/ /_/\__,_/
Keanu is a general purpose probabilistic programming library built in Java and developed by Improbable's research team. It enables you to build Bayesian networks through which you can make probabilistic predictions about large, complex and multifaceted problems.
This is an early stage, pre-alpha version of Keanu. We have an ambitious team attempting to build an even more ambitious product with the help of the open source community.
We have decided to open source Keanu at such an early stage in order to solicit user feedback and help guide the product to success.
Whilst we will always welcome contributions, we would value your time more if it were spent applying Keanu to challenging problems and locating its strengths and weaknesses.
Please create a Github Issue if you encounter any bugs or have a feature request.
- Slack: #keanu
- Issue Tracker: GitHub Issues
- Probabilistic Programming Operators and Distributions
- Auto-differentiation
- Inference
- Maximum a posteriori
- Metropolis Hastings
- Hamiltonian Monte Carlo
- Sequential Monte Carlo (Particle Filtering)
- Support for Kotlin
Want to see an example and run it yourself? Head over to Getting Started.
Want to learn more? Head over to the Documentation. You can also see our JavaDocs or our Python Docs
What does the future entail for Keanu? Find out at Future.
Interested in more technical examples? Explore the examples repo at /keanu-examples
.
We use Gradle, so running ./gradlew build
(or gradlew.bat build
on Windows) will compile all the code and run all the tests. You can also run the JMH performance benchmarks with ./gradlew runAllBenchmarks
.
We use Lombok annotations, which you will need to enable in your IDE.
For IntelliJ:
- Install the Lombok plugin
- Settings > Build, Execution, Deployment > Compiler > Annotation Processors - Enable annotation processing
We use Spotless and yapf to automatically enforce some basic code style checks. If your build fails due to a formatting issue, simply run ./gradlew formatApply
and commit the changes. You need to have run ./gradlew build
or test
at least once before running formatApply
, as this installs yapf in your virtual environment.
Custom annotations are used for python code generation. It depends on Oracle JDK to build (i.e. does not support open source JDKs). The minimum version requirement is Python 3.6. Simply run ./gradlew codeGen
to generate the code and commit the changes.
Interested in working for Improbable on cool problems? Start here