Chris Mair


A chess engine in Go: part 1 - the idea

Go book and chess pieces

I’ve started learning Go!

As a toy project I plan to program a simple chess engine. Here’s what I want to code:

  • a board representation with input/output to FEN1,
  • a simple evaluation function (maybe just counting material),
  • a move generator,
  • an alpha-beta tree search algorithm2,
  • an implementation of the UCI protocol3.

Let’s keep it simple! All this should be possible in a few thousand lines of code.

Once the engine works and speaks the UCI protocol, it should be easy to bring it online as a Lichess bot4 - so you’ll be able to play against it :)

As soon as I have a name for it (that’s the hardest part), I’ll open a Codeberg5 repository for it.

Go gophers at work
Gopher (C) CC BY 3.0 Renee French