top of page

Interview with John Stanback author of the Wasp chess engine.

Hosted by Darius, founder of Chessengeria.com, March 2023.


„(…) I'm still having fun experimenting with changes to my NN structure and training new nets using training data from recent games.”.

John Stanback is a well-known creator of strong chess engines who has made significant contributions to the field of computer chess over several decades!


First Zarkov and then Wasp, both of these chess engines have been successful and have many fans. With his knowledge and experience in computer chess programming, John Stanback continues to push the boundaries of what is possible in this field and inspire future generations of computer chess enthusiasts.



1. Darius:

Where did your passion for programming chess engines come from?


John Stanback:

I've been programming chess engines since 1978. I'm not a good chess player, but I like to think up algorithms and code them. I started by writing a routine in Basic to generate moves, then wrote a text interface and had the engine make random moves. Next, I started adding some really simple evaluation heuristics and a one ply search.


And 45 years later I'm still at it :)



2. Darius:

What are the biggest difficulties you have faced in developing chess engines?


John Stanback:

I guess the only thing I would view as a difficulty is sometimes failing to improve playing strength after many months of trying out various ideas. Also, occasionally running out of ideas to code and test. Since I've never tried to make a living writing a chess engine, I view most obstacles as fun challenges rather than difficulties.



3. Darius:

Are there any special algorithms or techniques that your chess engine uses to be so powerful?


John Stanback:

I don't think there is anything unusual about the algorithms I use. I rarely look at the code for other chess engines and never copy anything, but occasionally I get an idea to try out.



4. Darius:

Artificial intelligence is a trendy and frequently used phrase. In the context of chess engines, will AI be applicable in the future ? What could be the benefits of it ?


John Stanback:

Perhaps AI will be able to suggest better neural network architectures for chess or better ways to train the *NN.



5. Darius:

Does your chess engine use recently trending technologies such as machine learning?


6. Darius:

What is your experience with implementing *NNUE in your chess engine? What are the advantages and disadvantages of this technique?


John Stanback:

I'll provide a combined response to these questions.


Wasp uses a neural network for position evaluation, as do all of the top engines today. I was amazed when Alpha Zero demonstrated how strong an engine using neural network evaluation in combination with a Monte-Carlo tree search could be, and further impressed with the huge gain in strength when Stockfish implemented the NNUE evaluation.


I thought I might be too old or not motivated enough to learn how neural networks work, but after reading just a little bit about them I started writing some functions in C to generate inputs from a board position, and do a "forward pass" to produce an evaluation.


Initially I didn't worry at all about making the routines computationally efficient. I wrote a back-propogation routine and tested and debugged it using the training positions I had been using to tune my hand-crafted evaluation and found that even a fairly small network could get within about 100 Elo of my best handcrafted evaluation.

Initially I tried using a net with 2 hidden layers, but I found that the small 2nd layer I was using didn't help at all, so I changed to a single layer. I then improved the efficiency of the network evaluation and training functions by using SIMD (single instruction, multiple data) instructions and using integers for the forward pass except during training.


I've continuously added training positions taken from games between Wasp and other engines of similar strength and scored them using a short search using the latest NN evaluation. I've done a lot of experimenting with various training parameters such as minibatch size and learn rate and have tried to pick what works best for my engine.



7. Darius:

What features or characteristics of your chess engine help it deal with the so-called "horizon effect" - a problem in which it is impossible/difficult to predict further best moves and game outcomes?


John Stanback:

I don't have anything special for this. I think that today's fast CPU's and the various tree pruning techniques allow a deep enough search that horizon effect is rarely a problem. Having a stronger evaluation at the leaf nodes also helps a lot.



8. Darius:

What are your favorite/used development tools for creating and testing the Wasp engine?


John Stanback:

I develop under Windows using Notepad++ and use the gcc compiler from the command line, no *IDE.