Although I had some picture on how to randomize opening selection and diversify or "quickly build an opening book" when playing games from one single opening position, I never saw some data on that. This thing occurs often in handicap games with given opening position or studying specific opening in the opening theory. From a EPD file of openings, I took one normal opening position and played 400 games in different conditions (fixed depth, fixed nodes, fixed time) on 1 thread, then on 2 threads of a Stockfish dev. Then, I used PGN-Extract to count number of different games to move 10 of these 400-game matches. I wanted to see what diversity from 1 opening position is achieved.
1 initial opening position
400 games
10 moves
1 thread
Code: Select all
number of different games out of 400
depth 9 1
depth 11 1
nodes 2k 1
nodes 20k 1
nodes 200k 1
1s+0.01s 373
5s+0.05s 13
25s+0.25s 6
The only acceptable randomization occurs at hyper-fast 1s+0.01s due to time granularity. But for all reasonable conditions, 1-thread Stockfish doesn't randomize well for an opening diversity.
2 threads
Code: Select all
number of different games out of 400
depth 7 399
depth 9 396
depth 11 385
depth 13 367
nodes 2k 397
nodes 20k 391
nodes 200k 360
1s+0.01s 378
5s+0.05s 307
25s+0.25s 270
2-thread Stockfish randomizes fairly well in every condition. Curious thing, fixed depth result seems the most diverse. So, to build an opening repertoire from one single opening position, one can set play at fixed depth=7 Stockfish on 2 threads to 5-10 moves, then use thus built PGN file as opening book. The depth=7 games are very fast, but they are not that dumb to ruin the openings. I had some bad experiences with a complete randomizer engine, as in certain conditions it skews very much the openings.