official-stockfish / Stockfish

A free and strong UCI chess engine
https://stockfishchess.org/
GNU General Public License v3.0
11.38k stars 2.25k forks source link

The Prison Theme #2117

Closed VezirChess closed 5 years ago

VezirChess commented 5 years ago

I will try to explain an Idea that Stockfish doesn't has. This is THE PRİSON THEME. The idea contains incarcerating opponent's pieces for draws or wins. You can find some example positions in https://lichess.org/study/loM3CfBK AlphaZero used this strategy a lot and this means Leela can use too. I believe that If Stockfish developers adapts this idea in Stockfish, the elo gain will be more than 200...

ddugovic commented 5 years ago

Stockfish already has this: https://hxim.github.io/Stockfish-Evaluation-Guide/

https://github.com/official-stockfish/Stockfish/blob/6373fd56e90bc6114230a70cacad804248d955e2/src/evaluate.cpp#L134-L154 https://github.com/official-stockfish/Stockfish/blob/6373fd56e90bc6114230a70cacad804248d955e2/src/evaluate.cpp#L90-L106

VezirChess commented 5 years ago

Then why Stockfish can't solve that tactics in my study? Why SF couldn't saw AlphaZero's moves or beat it. There is something missing...

VezirChess commented 5 years ago

I am not talking about mobility. I am talking about Locking one of opponent's piece. I am sure that Stockfish hasn't this strategy... Please examine this study well. https://lichess.org/study/loM3CfBK

ddugovic commented 5 years ago

Duplicate of 7 other "fortress" issues: https://github.com/official-stockfish/Stockfish/issues?utf8=✓&q=is%3Aissue+fortress

VezirChess commented 5 years ago

No it is not. I have examined those issues and this is not same. I am a international chess player and I can tell this theme is important. Marco, protonspring and others can you look at this issue? Thank you

ianfab commented 5 years ago

One of the main problems with this thread is that you write

I believe that If Stockfish developers adapts this idea in Stockfish, the elo gain will be more than 200...

since after reading this sentence most people will perhaps just ignore the thread, since it indicates that you do not have much experience with engine development in practice. There is a huge difference between having a good idea for a pattern/technique that could be implemented into an engine in theory and finding an implementation that actually gains Elo in practice.

Most of the time the overhead for wasting time on evaluating a positional factor that does not apply in 99.9% of positions exceeds the gain from improving the evaluation of such 0.1% (or less) of positions. All the failed attempts on fortresses are typical examples.

Furthermore, such topics better fit into the forum than here.

acdemiralp commented 5 years ago

Dude you are 1.3k. Anybody who has a brain is 1.3k. Take a look at code before you come up with "I'm the next hot shit" threads. And tame that ego down. Its too high for your age.

VezirChess commented 5 years ago

This is not about %0.01 positions. For example, in many positions, the best answer for Nb6 is b3. Because it blocks the knight. I think blocking is a very good technique and you should use it. Best regards.

VezirChess commented 5 years ago

@acdemiralp What are you talking about? I just give them a technique

ddugovic commented 5 years ago

Stockfish already has bonuses for unblocked pieces. They're even called CorneredBishop, LongDiagonalBishop, MinorBehindPawn, and RestrictedPiece: https://github.com/official-stockfish/Stockfish/blob/6373fd56e90bc6114230a70cacad804248d955e2/src/evaluate.cpp#L134-L154

If you really think these should be increased, download the source code, try out different values, and submit a patch with the right values.

VezirChess commented 5 years ago

I don't know C language. But when I learn, I will try. Whatever. You are developing Stockfish, not me. Thanks anyway.

VezirChess commented 5 years ago

Just one more question. How can I test my Patches?

xoto10 commented 5 years ago

There's a wiki page describing how to do a first test: https://github.com/ddugovic/Stockfish/wiki/Creating-my-first-test It's a good idea to watch fishtest for a while to see how others do things

Spill-The-Tea commented 5 years ago

That lichess study was garbage... you are presenting well known fortress positions, including the Behting Study, and a modified version of Sir Roger Penrose's position as something novel without citing them. Not to mention, terrible commentary on alpha zero games.

For future reference, what you are calling "prison theme," is known by the chess world as fortress positions. The position shown from alpha zero games, are known as zugzwangs, which are different.

VezirChess commented 5 years ago

https://ailab.si/matej/doc/Detecting_Fortresses_in_Chess.pdf

Spill-The-Tea commented 5 years ago

Please read papers before citing them. In the abstract alone, it states that this method is not viable for tournament play. The "computational heuristic" they are prescribing in the paper is to avoid move pruning if the evaluation remains identical over large depths, and look at all possible moves to a certain depth x to reevaluate alternative moves. This just isn't feasible. However, you may be interested in matefinder, a stockfish fork found here, that does something similar, and can be useful for infinite analysis of difficult positions, such as fortresses:

https://github.com/jhellis3/Stockfish/tree/mate_finder