lichess.org
Donate

Stockfish 6 missed mate in 1 in my game, how likely it is?

Of course SF level 6 plays suboptimally. What's the point of having a full strength SF there that murders everyone who tries to play against it.
@savagechess2k Which is the reason why SF level 8 still is a severely handicapped version, it's possible for a human to beat it.
You can find the Stockfish skill levels as well as the time and depth limits for the different levels in the code:
github.com/niklasf/fishnet/blob/788aebb701c614959703185f201d7ef44365df1b/fishnet.py#L109-L111

This e.g. means that level 6 on lichess uses Stockfish's internal skill level 16 (20 is max strength) and search is limited to a depth of 8 and a move time of 400ms. The code for how Stockfish intentionally plays bad moves depending on the skill level can be found here:
github.com/ddugovic/Stockfish/blob/d6468f15a0e6d0ff5598a6dac6af076625c3deed/src/search.cpp#L1812-L1843

The code includes a pseudo-random number generator, so the blunders it makes also occur (pseudo-)randomly based on a probability distribution that depends on the evaluation of the moves. A bad move has a lower probability of being chosen, but it still rarely/frequently happens depending on how high/low the skill level is.

This topic has been archived and can no longer be replied to.