A Self-Trained Chess Engine for Crazyhouse Chess
Hämtar...
Ladda ner
Publicerad
Typ
Examensarbete på kandidatnivå
Bachelor Thesis
Bachelor Thesis
Program
Modellbyggare
Tidskriftstitel
ISSN
Volymtitel
Utgivare
Sammanfattning
This thesis investigates the development of a self-trained chess engine for the Crazy
house chess variant, inspired by the AlphaZero framework. Crazyhouse extends
classical chess with a drop mechanic, where captured pieces can be collected and
reintroduced onto the board, fundamentally altering strategic evaluation and significantly increasing the branching factor compared to classical chess. The absence
of established opening theory makes Crazyhouse a particularly suitable domain for
self-learning approaches, as chess engines cannot rely on accumulated human knowledge and must instead discover effective strategies entirely through self-play.
The engine was implemented using a C-based game engine for efficient move generation and rule enforcement, combined with a Python-based Monte Carlo Tree Search
(MCTS) algorithm guided by a neural network. Four distinct convolutional neural
network architectures were designed and compared, a shallow non-residual baseline,
a shallow residual network, a deep residual network and a wide shallow residual
network. All architecture were trained through an iterative self-play process and
evaluated using a round-robin tournament.
The results showed that residual architectures consistently outperformed the non
residual baseline, confirming that skip connections provide significant benefits for
gradient flow and learning stability in the context of Crazyhouse position evaluation.
Among the residual architectures, the shallow residual network, using 128 channels
and 6 residual blocks, demonstrated the strongest learning trajectory, having a more
upwards going regression trend compared to the other neural network models. The
deep residual architecture underperformed relative to its theoretical capacity, which
suggests that the project’s computational and time constraints resulted in insufficient
training data. While all trained architectures demonstrated clear strategic intent
beyond random play, none were able to win consistently against Stockfish at any
tested skill level, indicating that the scale of training required to reach competitive
strength exceeds what was achievable within a single academic semester.
Beskrivning
Ämne/nyckelord
Crazyhouse Chess, Machine Learning, Monte Carlo Tree Search (MCTS), Reinforcement Learning, Convolutional Neural Networks, Residual Networks, Alp haZero, Chess Engine, Neural Network Architecture.
