[Paper Review] KnightCap: A chess program that learns by combining TD(lambda) with game-tree search
This paper introduces TDLeaf(λ), a novel temporal difference learning algorithm that trains a chess program's evaluation function by learning from leaf nodes in minimax search trees during online play. KnightCap, using TDLeaf(λ), improved from a 1650 to a 2150 rating in just 308 games over three days by playing against real human and computer opponents on the Internet Chess Server, demonstrating the effectiveness of online, non-self-play learning for deterministic games like chess.
In this paper we present TDLeaf(lambda), a variation on the TD(lambda) algorithm that enables it to be used in conjunction with game-tree search. We present some experiments in which our chess program ``KnightCap'' used TDLeaf(lambda) to learn its evaluation function while playing on the Free Internet Chess Server (FICS, fics.onenet.net). The main success we report is that KnightCap improved from a 1650 rating to a 2150 rating in just 308 games and 3 days of play. As a reference, a rating of 1650 corresponds to about level B human play (on a scale from E (1000) to A (1800)), while 2150 is human master level. We discuss some of the reasons for this success, principle among them being the use of on-line, rather than self-play.
Motivation & Objective
- To address the challenge of training effective evaluation functions in deterministic, deep-search games like chess using temporal difference learning.
- To overcome the limitations of self-play in deterministic games, which leads to repetitive, non-diverse game sequences and poor generalization.
- To develop a method that enables online, real-opponent learning to improve exploration and accelerate convergence in reinforcement learning for chess programs.
- To investigate whether learning from diverse, real human and computer opponents yields faster and higher-quality policy improvement than self-play.
Proposed method
- TDLeaf(λ) extends TD(λ) by updating the evaluation function based on the leaf nodes of the principal variation in minimax search trees, rather than game states.
- The algorithm uses temporal difference updates on the evaluation of leaf positions, backpropagating rewards using eligibility traces to efficiently update feature weights.
- KnightCap’s linear evaluation function is trained in real time during online games, with weights adjusted after each game using the TD(λ) update rule applied to principal variation leaves.
- The system uses a rich board representation to compute complex positional features, enabling high-quality evaluation despite slower computation.
- Learning occurs during actual play on public servers (FICS and ICC), exposing KnightCap to diverse, non-redundant opponent strategies.
- The method avoids premature convergence by leveraging the exploration inherent in real opponent play, which provides varied and informative game states.
Experimental results
Research questions
- RQ1Can temporal difference learning be effectively applied to deep minimax search in deterministic board games like chess, where self-play leads to poor exploration?
- RQ2Does online learning against real human and computer opponents yield faster and better convergence than self-play in chess evaluation function training?
- RQ3How does the choice of initial weight values affect the rate and quality of learning in a TD(λ)-based evaluation function?
- RQ4What role does the λ parameter play in balancing immediate reward prediction and long-term value estimation during learning?
- RQ5Can a linear evaluation function trained via TDLeaf(λ) achieve master-level performance in a relatively small number of games?
Key findings
- KnightCap improved from a 1650 rating (B-level human play) to a 2150 rating (master-level) in just 308 games and three days of online play on FICS.
- The performance gain was significantly faster than in a self-play experiment, where KnightCap scored only 11% against the FICS-trained version after 600 games.
- Starting from zero-initialized weights, KnightCap achieved a 500-point rating increase in a short time, indicating strong learning efficiency from real opponent play.
- Initializing weights to a pawn value (1250 rating) led to a much slower improvement (to ~1550 after 1000 games), highlighting the importance of good initial conditions.
- The use of online play, as opposed to self-play, provided richer and more diverse experience, effectively solving the exploration problem inherent in deterministic games.
- TDLeaf(λ) successfully enabled a linear evaluation function to learn complex positional features through interaction with real opponents, achieving master-level performance without deep neural networks.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.