Computing System: The bot uses a custom Python engine built around the python-chess library. Game states are modeled as a tree, where each node represents a possible board state and edges represent legal moves. The core decision-making logic uses a minimax algorithm to recursively evaluate this tree and select the best possible move. To reduce computation time, alpha-beta pruning is implemented. This technique discards branches of the game tree that are guanteed to be non-optimal, allowing the bot to evaluate more branches in less time.
Evaluation Function: Each board state is scored using a heuristic function combining two metrics:
- Material Value: weighted sum of remaining pieces (e.g., Queen = 9, Rook = 5)
- Piece Activity: score modifiers based on how active or developed a piece is on the board
Special conditions such as checkmate, stalemate, and threefold repetition are also handled by assigning large positive/negative scores.
User Interaction: We built a custom UI to enable users to play against our bot. This included an evaluation bar, a preview of legal moves, and a piece graveyard. The board and piece art design are attributed to Dani Maccari.