As you can see, it basically checks if we can fail-high earlier at a cut-node rather than fail-low earlier at an all-node.
It works for me - what do you think?
Matthew:out
This is already done in Komodo and I think in most of the other top programs. It's a special case of null move pruning but without the "null move" part It essentially says, if your score is so good you can take a big hit and still get the beta cutoff, go for it. Null move pruning is the same idea but the "big hit" you take is that if the score is so good you can give the opponent 2 moves in a row and still be happy, then take the cutoff.
Michel wrote:However that may be too pessimistic. So you could also decide to
return something in between eval-margin and eval.
If you can afford that, you should have set margin smaller...
What you propose causes inconsistency when you get a hash hit on that same position later, with higher beta. It would behave as if the margin is smaller than anyway.
It's too early to say, but so far it seems this improvement is quite useless.
When the test finishes, I'll try to return eval-margin, as suggested by Michel. From what I saw in StockFish, returniing eval instead of eval - margin was supposedly better (it's somewhere in a comment on the razoring code in SF). But all that's very hocus-pocus and unproven, so I guess the only right way is the one that works
PS: I don't think this idea is any novelty. I saw it in the first versions of Toga, and I'm sure Thomas Gaksh didn't invent anything and it was already tested in Crafty years ago
What you propose causes inconsistency when you get a hash hit on that same position later, with higher beta. It would behave as if the margin is smaller than anyway.
That's a nice point! Only testing can show whether this "inconsistency" is really a problem.
Michel wrote:It seems to me that there is a distinction between taking a cutoff (a drastic decision) and making a statistical guess at a good evaluation bound.
The problem is that that statistical guess will later, when you encounter that position again, (or a parent to which the score propagated), and find the guess in the hash table, be used to take again that same drastic decision.
In fact the guess will never be used for anything else. Being a bound, it could never propagate to the root, or become the score of a PV node.