#genetic #education


Perestroika is a library for genetic algorithms

3 releases

0.1.2 Sep 20, 2023
0.1.1 Sep 17, 2023
0.1.0 Sep 19, 2022

#170 in Science

48 downloads per month

GPL-3.0 license




Perestroika is a perhaps naive library that provides primitives to design simulations that are based on genetic algorithms.

It can be used to generate Genomes (i.e., Brains) from Nodes and Connections and simulate propagation from given input to output. It is also possible to simulate mutation events which are the main engine of evolution.


Add this to your Cargo.toml:

perestroika = "0.1"


cargo add perestroika


See the crate's documentation for the docs.

Check out the examples directory for examples to get going.


The current roadmap is to figure an API within the 0.1.* versions and stabilize it.

This means that until 0.2, the API and functionality will probably change, break or differ in one way or another between versions.

Issues, bugs, suggestions

For issues, bugs, suggestions, comments or anything of the sort feel free to open a new issue on the repository.

Perestroika's Zulip might be a place for more direct communication, although it is pretty empty at the moment.


The motivation behind this project is to make a full scale project in Rust, while integrating many more other fields such as game development in Bevy, DevOps (GitLab CI/CD) and, of course, neural networks.


Currently being used in an in-development game that I prototype in my spare time.

More projects that employ perestroika will be listed below.


"Perestroika" is the Russian word for "Reconstruction" and serves as a double pun: Perestroika was a late USSR political movement trying to reconstruct the regime; it is also a very fitting description for Genetic recombination (or genetic reshuffling) which is the target of this library.

Bibliography and sources

Efficient Evolution of Neural Networks through Complexification as the paper and background.

The Bibites provide a good overview of an already implemented game that follows similar principles.