Chris Mair

Sprachauswahl

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

  1. FEN at Wikipedia ↩︎

  2. https://www.chessprogramming.org/Alpha-Beta ↩︎

  3. UCI at Wikipedia ↩︎

  4. https://lichess.org/api#tag/Bot ↩︎

  5. https://codeberg.org/chris-mair ↩︎

Menü

Sprachauswahl