I have tried my hand at creating a simple bitboard teaching engine. I expect to finish it in about 3 months, and only then make an official release, but since in the meantime it reached 2700+ on the CCRL scale, I can as well show it. It is available at: https://github.com/nescitus/publius
"Simple" and "teaching engine" are vague concepts, so explanation of constraints is in order:
- eval is done, if not necessarily tuned. It takes into account material, bishop pair, piece/square tables, mobility, passed, doubled and isolated pawns, intentionally primitive king safety and some detection of drawish endgames.
- quiescence search is probably done, unless I make delta pruning work
- search is under active developement and there will be more stuff added
- board update relies on four functions: AddPiece, DeletePiece, MovePiece and ChangePiece
- apart from the hash key, there are no incremental updates of evaluation stuff. If someone wants to slap NNUE on top of my code, there will be no need to delete them. If not, at least eval can be read in one piece.
- movegen is slow, there is no specialized popcount. Simple kindergarten bitboard stuff would be a welcome addition.
- I'm still not sure whether to generate discovered checks
- more comments will be added.
Why am I doing that? Because CPW-engne is old and because I want to learn about more modern search techniques. If search gets good enough, I might be tempted to fork it and do Rodent V, but don't read it as a promise.
Enjoy!
Publius - public domain teaching engine
Moderator: Ras
-
- Posts: 903
- Joined: Mon Jan 15, 2007 11:23 am
- Location: Warsza
-
- Posts: 2639
- Joined: Fri Nov 26, 2010 2:00 pm
- Location: Czech Republic
- Full name: Martin Sedlak
Re: Publius - public domain teaching engine
nice and clean - great job Pawel!
also a great name
also a great name

-
- Posts: 903
- Joined: Mon Jan 15, 2007 11:23 am
- Location: Warsza
Re: Publius - public domain teaching engine
Thank you for confirming that this approach makes sense. I have a history of writing messy code (see Rodent) and need to change that. If you have some ideas to make this code even cleaner, I'm all ears.
Pawel Koziol
http://www.pkoziol.cal24.pl/rodent/rodent.htm
http://www.pkoziol.cal24.pl/rodent/rodent.htm
-
- Posts: 673
- Joined: Sat Jun 08, 2013 10:07 am
- Location: France
- Full name: Roland Chastain
Re: Publius - public domain teaching engine
Thank you for that new project Pawel!
There is a tabulation at end of line 12 of makefile that prevents it to work by me.
After correction, I can compile the program under Linux.
There is a tabulation at end of line 12 of makefile that prevents it to work by me.

After correction, I can compile the program under Linux.
Qui trop embrasse mal étreint.
-
- Posts: 903
- Joined: Mon Jan 15, 2007 11:23 am
- Location: Warsza
Re: Publius - public domain teaching engine
Took me a while and it will certainly require more comments, but kindergarten bitboards were added for a nice speedup:
without: Bench at depth 15 took 32391 milliseconds, searching 28402034 nodes at 876849 nodes per second.
with: Bench at depth 15 took 23922 milliseconds, searching 28402034 nodes at 1187276 nodes per second.
without: Bench at depth 15 took 32391 milliseconds, searching 28402034 nodes at 876849 nodes per second.
with: Bench at depth 15 took 23922 milliseconds, searching 28402034 nodes at 1187276 nodes per second.
Pawel Koziol
http://www.pkoziol.cal24.pl/rodent/rodent.htm
http://www.pkoziol.cal24.pl/rodent/rodent.htm