A program to generate a chess program. Since chess is such a complex game with many branching paths, it is impossible to write a program for it by hand.
This tool provides a CLI to generate a simple terminal chess program.
pip install chess-program-generator
To generate the runnable chess program:
chess-program-generator [depth] > chess.py
To run the produced chess program
python chess.py
For example:
$ chess-program-generator 6 > chess.py
$ # Several hours later
$ wc -l chess.py
1509877878 chess.py
A pre-compiled program, generated to a depth of 4 ply, can be downloaded from the releases page on GitHub.