Deep Pepper: Expert Iteration based Chess agent in the Reinforcement Learning Setting

Sai Krishna G. V., Kyle Goyette, Ahmad Chamseddine, Breandan ConsidinearXiv 2018

TL;DR

This paper introduces "Deep Pepper," a novel chess agent that accelerates reinforcement learning training by incorporating expert knowledge and a custom feature representation, diverging from Alpha Zero's purely self-play approach. The work aims to make state-of-the-art chess AI more accessible and efficient to train.

What Problem Does This Paper Address?

Achieving "almost-perfect" play in chess has been a long-standing goal in Artificial Intelligence. While systems like Deep Blue and more recently Alpha Zero have demonstrated remarkable progress, particularly Alpha Zero's ability to learn from self-play, there are challenges. Alpha Zero's "tabula rasa" approach, while powerful, can be computationally expensive and time-consuming to train. Furthermore, there have been criticisms regarding the fairness of comparisons between Alpha Zero and traditional chess engines, suggesting that a hybrid approach might be beneficial. This paper addresses the need for faster training of self-play reinforcement learning agents in chess, while also leveraging existing chess knowledge to potentially improve efficiency and performance.

Methods

Deep Pepper combines several key techniques:

  • Expert Iteration Framework: The training process is framed within the Classification-based Approximate Policy Iteration (CAPI) framework, which is a standard approach for reinforcement learning.
  • Deep Neural Networks: A neural network is used for both policy prediction (suggesting moves) and value prediction (evaluating board states).
  • Monte Carlo Tree Search (MCTS): MCTS is employed to explore possible moves and improve the policy. Deep Pepper uses a variant of the Polynomial Upper Confidence Trees (PUCT) algorithm for MCTS selection.
  • Custom Feature Representation: Instead of Alpha Zero's full board representation, Deep Pepper uses a handcrafted 353-dimensional feature vector. This representation incorporates expert knowledge about piece values, threats, defenses, and mobility, aiming to be more efficient and potentially more robust to adversarial attacks than a raw board input.
  • Embedded Knowledge: The system leverages existing chess knowledge in several ways:
  • Pretraining: Models can be optionally pretrained using professional games and Stockfish evaluations.
  • Stockfish for Early Game Termination: Stockfish is used to accelerate training by ending games early if the evaluation indicates a high probability of a win or loss, reducing the number of full games that need to be played out.
  • Multiple Network Architectures: The authors experimented with different neural network architectures, including shared vs. separate networks for policy and value, and different connection patterns within the network layers.

Datasets

  • Professional Chess Games: Used for optional pretraining. Specific players mentioned include Kasparov, Karpov, Ivanchuk, and Aronian.
  • Stockfish Evaluations: Used for optional pretraining and for accelerating game termination during training.

Key Insights and Ideas

  • Expert Knowledge Accelerates Training: Incorporating handcrafted features and optional pretraining with expert data significantly speeds up the training process compared to a pure "tabula rasa" approach. This suggests that even with powerful self-play, leveraging human expertise can be a valuable shortcut.
  • Custom Feature Representation is Efficient: The 353-dimensional feature vector, inspired by Giraffe, is shown to be faster to train and potentially more robust than a full board representation, while still achieving good results. This highlights the trade-off between input complexity and training efficiency.
  • Hybrid Approach is Promising: By combining deep learning, MCTS, and expert knowledge, Deep Pepper offers a compelling alternative to purely self-play agents, potentially bridging the gap between traditional engines and modern ML approaches.
  • Early Game Termination Speeds Up Learning: Using Stockfish to resign games early based on its evaluation is a practical method to generate more training data in less time.

Key Results

  • Improved Performance with Training: Experiments showed that trained networks consistently improved over previous iterations. For example, a model trained for 100 iterations with pretraining beat a purely pretrained model in 56% of games.
  • Pretraining Benefits: A pretrained model won against a randomly initialized model in 64% of games, demonstrating the value of initial guidance.
  • Performance Against Previous Iterations: Figure 2 shows that the current model was observed to be better than its previous iteration about 70% of the time as training progressed.
  • Comparison to Random Play: Table 1 shows win rates against random play, with models achieving higher win rates as training progressed (e.g., Pretrain0: 0.55, Pretrain50: 0.55, Pretrain100: 0.64, Pretrain150: 0.64).

Limitations and Future Work

  • Limited Evaluation Metrics: The current evaluation primarily relies on testing against past models and pre-trained versions. The authors acknowledge the need to expand evaluations to include objective metrics like ELO rating to better assess skill.
  • System Optimization: The training pipeline could be further accelerated by optimizing MCTS computation, potentially through parallelization and GPU utilization. Sharing node statistics among MCTS processes is also suggested.
  • Hyper-parameter Tuning: Extensive hyper-parameter optimization is needed, as initial values were borrowed from other systems. This includes exploring batch normalization and alternative activation functions.
  • Extensive Testing: More comprehensive testing is required to determine the optimal number of games for each training epoch and to explore a wider range of network architectures.

Summary updated

BibTeX
@misc{v2018deep,
  author = {Sai Krishna G. V. and Kyle Goyette and Ahmad Chamseddine and Breandan Considine},
  title = {{Deep Pepper: Expert Iteration based Chess agent in the Reinforcement Learning Setting}},
  year = {2018},
  eprint = {1806.00683},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1806.00683},
}
Figure