Chess Bot

Engine Evaluation

0.0

Game Status

Ready
FEN:
startpos
PGN:

How it Works

For this project, I used chessboard.js to display the board, and FastBitboardEngine to generate all the possible moves including castling, en passant, etc.

This program makes the best moves using a custom-made FEN evaluation algorithm. It parses the FEN string into an 8x8 grid using a for loop, and then runs it through all possible moves.

So, for example, the first ply (singular move) has a total of 20 possible moves/paths. On the second move, the number would increase to 400. And by the third ply calculation, there are over 8000 possible moves. Since this would take a very long time to calculate this, I decided to use a alpha-beta algorithm with minimax that largely cuts out the useless or bad moves.

Note: Note: The performance of this chess bot is reliant on the processing power. You can see how many moves deep it is searching, along with node information by checking out the console tab. (right-click -> Inspect -> switch over to console)

Below is an image showing how Minimax works.

Source: wikipedia.org

I plan on updating this chess bot so it is more efficient; while it is good enough, it cannot consistently beat higher level bots (~1500+ ELO) like wally on chess.com. It also takes a lot of time for it to think and that could be something to build on.