Skip to content

Latest commit

 

History

History
34 lines (24 loc) · 1.45 KB

README.md

File metadata and controls

34 lines (24 loc) · 1.45 KB

Chess Minimax

I've decided to continue my adventure after minimax implementation for tic tac toe.

"ex_play"

Implemented

  • board state evaluation based on pieces weights (pretty base solution)
  • minimax search algorithm for best move/optional depth
  • alpha-beta search tree pruning
  • game class for games with different players
  • game result stats

Problems

  • Bots don't know how to end a game, so it almost always ends in a draw. Possible solution: endgame tablebase.
  • Minimax for depth > 4 execution takes forever even with alpha-beta pruning and move sorting by pieces importance. Possible solution: tree caching, better heuristic, parallelization (oh that's hard), build tree only for some promising moves (for example in some range from the opponent).

TODO:

  • player class & methods for human play
  • game loop for random player & human player
  • simple func for game generations and saving result stats
  • add minimax method for simple eval by pieces weigths
  • different weights for board eval -> stats bot vs bot
  • alpha-beta pruning
  • too long - sort possible moves by pieces: more weight at first -> better pruning
  • caching (???)

Inspiration: