UGI of the project (developed with C++)

This project implements SARSA and Monte Carlo reinforcement learning algorithms to approximate an optimal policy for playing chess against an opponent.

๐Ÿ™ Project Details

This project comes with a ready-to-run executable, primarily developed for macOs in C++, but it should be compatible with any Unix-based system. The full code is on my Github Repository

Available Gameplay Modes

Upon running the executable, you can choose from the following options:

  • Play as White: Face the AI while controlling the white pieces
  • Play as Black: Face the AI while controlling the black pieces
  • Play Stockfish as White: Play against Stockfish while controlling the white pieces
  • Play Stockfish as Black: Play against Stockfish while controlling the black pieces

๐ŸงฉHandling New Positions

The AI utilizes Zobrist hashing to encode board positions efficiently. When encountering an unfamiliar position, it simulates multiple games against Stockfish to analyze the position and determine the best move. This process may cause a slight delay before making a move, particularly in novel board states

๐Ÿ“Š Results

The AI model that I trained reached an Elo rating of 1350 in one hour.