My troubles with MultiPV and Syzygy in Stockfish 7
Posted: Tue Feb 16, 2016 10:42 pm
Recently I was analyzing lots of chess studies with Stockfish 7 (or with its Matefinder version) from the latest Endgame Study Database V ( http://hhdbv.nl/). These engines make a very good job, but I have encountered a disturbing problem when analyzing positions with 5 or 6 men. Given some conditions, in the MultiPV output not only the drawing or losing moves but even some of the winning moves could be missing...
Case 1: Cursed Wins
Studies don't respect the 50 move rule, so I leave Syzygy50MoveRule unchecked. That way the engine can report a win. E.g.
[D]2R5/8/8/8/B3n3/3n4/K2k4/8 w - - 0 1
Stockfish reports only one move (Ka1) even in MultiPV mode. Does it means that only Ka1!! wins? It would be nice, but no! According to the online syzygy tablebases, there are 4 winning moves. https://syzygy-tables.info/?fen=2R5/8/8 ... 3n4/K2k4/8 w - - 0 1
Maybe it reports only the best move? Let's see! The following position has 17 winning moves, see https://syzygy-tables.info/?fen=2R5/8/8 ... /3nk3/8/K7 w - - 0 1.
[D]2R5/8/8/8/B3n3/3nk3/8/K7 w - - 0 1
Guess, how many of the are shown by the engine? Well, the winner is: 2! The two best moves Rd8 and Re8, both with equal DTZ, are reported.
Case 2: Repetitions
Many engine report 0.00 if a position is reached the second/third time. Even if sometimes disturbing, that could seem logical. But I have observed a different phenomenon regarding repetitions. If early in the game there was a repetition, after that MultiPV outputs only the best DTZ move/moves in the entire game. Example: starting with position A let us reach position B in two ways.
Position A
[D]4n3/6p1/6R1/1b6/8/8/1K1k4/8 w - - 0 1
Position B
[D]4n3/6p1/4R3/1b6/8/8/1K1k4/8 b - - 0 1
First way: 1.Re6
Second way (after a repetition): 1. Rg5 Bc6 2. Rg6 Bb5 3. Re6
There are only two winning moves in the Position B:
https://syzygy-tables.info/?fen=4n3/6p1 ... /8/1K1k4/8 b - - 0 1
In the first case Stockfish shows both of them (Nf6 and Kd3), but when reaching Position B by the second method, reports only the best move (Nf6).
The two problems seems to be related.
If a user wants to analyze a position seting MultiPV to some value N, that means he/she would like to see N variations, no matter what! (Of course, with the only exception of not having enough legal moves). Unlike Stockfish, Komodo is fine, but that engine has other issues... It is sad that both these great playing engines are not as good as analysis tools.
Case 1: Cursed Wins
Studies don't respect the 50 move rule, so I leave Syzygy50MoveRule unchecked. That way the engine can report a win. E.g.
[D]2R5/8/8/8/B3n3/3n4/K2k4/8 w - - 0 1
Stockfish reports only one move (Ka1) even in MultiPV mode. Does it means that only Ka1!! wins? It would be nice, but no! According to the online syzygy tablebases, there are 4 winning moves. https://syzygy-tables.info/?fen=2R5/8/8 ... 3n4/K2k4/8 w - - 0 1
Maybe it reports only the best move? Let's see! The following position has 17 winning moves, see https://syzygy-tables.info/?fen=2R5/8/8 ... /3nk3/8/K7 w - - 0 1.
[D]2R5/8/8/8/B3n3/3nk3/8/K7 w - - 0 1
Guess, how many of the are shown by the engine? Well, the winner is: 2! The two best moves Rd8 and Re8, both with equal DTZ, are reported.
Case 2: Repetitions
Many engine report 0.00 if a position is reached the second/third time. Even if sometimes disturbing, that could seem logical. But I have observed a different phenomenon regarding repetitions. If early in the game there was a repetition, after that MultiPV outputs only the best DTZ move/moves in the entire game. Example: starting with position A let us reach position B in two ways.
Position A
[D]4n3/6p1/6R1/1b6/8/8/1K1k4/8 w - - 0 1
Position B
[D]4n3/6p1/4R3/1b6/8/8/1K1k4/8 b - - 0 1
First way: 1.Re6
Second way (after a repetition): 1. Rg5 Bc6 2. Rg6 Bb5 3. Re6
There are only two winning moves in the Position B:
https://syzygy-tables.info/?fen=4n3/6p1 ... /8/1K1k4/8 b - - 0 1
In the first case Stockfish shows both of them (Nf6 and Kd3), but when reaching Position B by the second method, reports only the best move (Nf6).
The two problems seems to be related.
If a user wants to analyze a position seting MultiPV to some value N, that means he/she would like to see N variations, no matter what! (Of course, with the only exception of not having enough legal moves). Unlike Stockfish, Komodo is fine, but that engine has other issues... It is sad that both these great playing engines are not as good as analysis tools.