Fortress Positions

Discussion of anything and everything relating to chess playing software and machines.

Moderator: Ras

peter
Posts: 3672
Joined: Sat Feb 16, 2008 7:38 am
Full name: Peter Martan

Re: Fortress Positions

Post by peter »

To not expatiate the problem theoretically only, I once in a while gave it a practical try again, to automate the search for fotresses in big databases.

Took the first 1000 positions (not to start with too big data at once) out of HHdbVII, copied those of them being drawn ones, exported them with pgn2epd to .epd and let SF19 then search for best moves with 10"/pos single threaded. On 4 instances only, that was done in a few minutes, because I set the Extra Depth in Shredder GUI to 2 only, letting the GUI load next position always already if correct best move was found and kept stable for 2 iterations, so the 10" were used fully only in case bm was not found by engine.
Indeed that way I found one more somewhat useful (for engine- testing) fortress- position, I hadn't known so far, at least hadn't stored in my big problem- database and couldn't remember it neither:
[pgn][Event "3.hm 12th Polish Chess Fed ty 2024"]
[Site "; Polish Chess Fed ty#3280 4-"]
[Date "2024.12.04"]
[Round "?"]
[White "Tarasiuk=V"]
[Black "(=3111.66a4e3)"]
[Result "1/2-1/2"]
[Annotator ""]
[SetUp "1"]
[FEN "8/qp6/p1p1p3/1PP2p2/KRP3p1/P1N1k3/1PP5/4B3 w - - 0 1"]
[PlyCount "12"]
[GameId "2362877199570320"]
[EventDate "2024.12.04"]

{(EG#26441); source: Polish Chess Fed ty#3280 4-12-2024} 1. b6 (1. Bg3 $2 Qxc5 2. bxa6 bxa6 3. Bc7 Kf3 4. Bb6 Qe5 5. Nd1 Qe2 6. Rb3+ Kf4 7. Ne3 Ke4) 1... Qb8 2. Rb3 $1 (2. Ka5 $2 Qe5 3. Rb3 Qxc5+) 2... f4 $1 (2... e5 3. Ka5 Qg8 4. Nd5+ $1 Ke2 5. Re3+ Kd1 6. Rxe5 g3 7. Bc3 cxd5 8. c6 Qc8 9. Rxd5+ Kxc2 10. c7) 3. Ka5 $1 (3. Bh4 $2 Qe5 4. Bf6 Qxc5 5. Be7 Qf5 6. Nb5+ Kf2) (3. Nb1+ $2 Ke2 4. Kb4 f3) 3... g3 (3... Qd8 4. Na4+ Ke2 5. Bb4 f3 6. c3 Qxb6+ 7. cxb6 $1 f2 8. Nc5 f1=Q 9. Nxb7) 4. Na4+ $1 (4. Nd5+ $2 Ke2) 4... Ke2 5. Bb4 g2 6. c3 g1=Q 1/2-1/2
[/pgn]

Pity, SF19 with 30 threads and 8G hash "finds" 1.b6 within a few seconds yet too, just with -+ eval and not staying stable on this one best move, that was why it wasn't solved in Shredder- GUI within 10" single threaded neither, but if you have a look at the output, the problem of the position for getting used for engine- testing is to be seen clearly:

Code: Select all

8/qp6/p1p1p3/1PP2p2/KRP3p1/P1N1k3/1PP5/4B3 w - - 0 1

Analysis by Stockfish 19:

1.b6 Db8 2.Tb3 f4 3.Sb1+ Ke2 4.Lh4 Dh8 
  Schwarz steht deutlich besser.  
  -/+ (-1.56)  Tiefe: 10/19   00:00:00
...
1.bxc6 bxc6 2.Lg3 Dxc5 3.Lc7 Kf3 4.Tb3 e5 5.Ld6 Dxc4+ 6.Ka5 f4 7.Lxe5 Dc5+ 8.Sb5+ Ke2 9.Lxf4 axb5 10.Le5 
  Schwarz hat entscheidenden Vorteil.  
  -+ (-3.48)  Tiefe: 18/73   00:00:05  191MN
1.b6 Db8 2.Lh4 De5 3.Tb3 f4 4.Sb5+ Ke2 5.Sd6 g3 6.Sxb7 g2 7.Sa5 g1D 8.Le7 f3 9.Ld6 De4 10.b7 f2 11.b8D f1D 12.Tc3 Dg5 13.Sb3 Kf2 14.Ka5 e5 15.Kxa6 Dgf5 
  Schwarz steht auf Gewinn.  
  -+ (-3.53)  Tiefe: 19/73   00:00:07  252MN
...
1.b6 Db8 2.Tb3 f4 3.Lh4 De5 4.Sb5+ Ke2 5.Sd6 g3 6.Sxb7 g2 7.Le7 g1D 8.Ld6 De4 9.Sa5 f3 10.b7 f2 11.b8D f1D 12.Td3 Da1 
  Schwarz steht klar auf Gewinn.  
  -+ (-4.36 --)  Tiefe: 23/30   00:00:40  1368MN
1.bxc6 
  Schwarz steht klar auf Gewinn.  
  -+ (-4.36 ++)  Tiefe: 23/72   00:00:50  1715MN
Then engine is on 1.b6 after 7", and keeps it on top till output at 50", then changing to bxc6? again instead. If the hardware- TC for this one position fits to that SMP- run and gets judged automatically in a suite, it's pure accident, if SMP- output will have correct or wrong one move on top, when max. time is over (if it was 30" SMP e.g. it would have been counted "solved" by Shredder), that's as bad for a single best move test- position as having more than one solution, because you can't even test it MEA- like correctly, there's only one move to get the full amount of points, but it's random, if engine, hardware- TC and evalutating- tool will count the position in single run + or -.

Crystal9 at three trials always was around 10" stable on 1.b6, then already getting eval down to 0.00 soon, so even worse, one engine would solve for correct reasons, another one maybe would get a solved- count too, but incorrectly so.

All in all, yes, there are still treasures to be discovered that way of "automated" filtering of big databases , and for those, who own HHdb, which is the gold standard for endgame studies anyhow to me still, such ways of searching the very very many composed puzzles for some single ones, that are usable for testing modern engines, isn't fully and only frustrating yet still, but seeing the much work of one's own, having to sit at PC by yourself also, and the much hardware- time it yet would take to find such single positions of engine-testing- interest out of the really big data, I don't think I'll go that way much more often than I already had done so far till now. Even more, seeing the positions you'll find that way, to a big part are already known in engines' problem- databases, test- suites and fora then still anyhow, I don't think that to be a really clever way of automation
:)
Peter.
peter
Posts: 3672
Joined: Sat Feb 16, 2008 7:38 am
Full name: Peter Martan

Re: Fortress Positions

Post by peter »

And even if I still don't think the method to be a clever one, of course I couldn't stop going on with it for at least the next 1000 positions more in HHdb, within these I found even 4 more or less usable fortresses (for engine- testing):

Code: Select all

Q5r1/4p1PP/4P2p/1p4b1/8/4pp1q/p1p1p3/k1Kbr2n w - - bm h8=B; am hxg8=Q; hmvc 0; id "Gatti=D_(=4663.38c1a1)_Phenix 2024, 1403";
1Kbkrbn1/P2pp3/P2ppR1p/P3p2P/8/4n3/8/8 w - - bm Rf1; am Rxf8; hmvc 0; id "Gatti=D_(=0466.46b8d8)_Problem Paradise 2024, 1426";
r5NK/p1P1p3/P5PP/n4k2/2N1q3/4p1p1/4P1P1/2R5 w - - bm Nd6+; am g7; hmvc 0; id "Eilazyan=E_(=3405.64h8f5)_no ty, 1580";
rnb1k3/r2p1p2/q1nP1PpP/p3p1PB/4p3/B3p1p1/5Q2/4b1K1 w q - bm Qb2; am Qc2; hmvc 0; id "Murdzia=P Piliczewski=B_(=4686.48g1e8)_sp.c The Problemist 2024, 1669";
First three are a little too easy for collections of some difficulty on average, SF needs little hardware- time, Crystal solves at once, but the fourth one is really tricky indeed again:
[pgn][Event "sp.c The Problemist 2024"]
[Site "; The Problemist#1432 no.12 1"]
[Date "2024.??.??"]
[Round "?"]
[White "Murdzia=P Piliczewski=B"]
[Black "(=4686.48g1e8)"]
[Result "1/2-1/2"]
[Annotator ""]
[SetUp "1"]
[FEN "rnb1k3/r2p1p2/q1nP1PpP/p3p1PB/4p3/B3p1p1/5Q2/4b1K1 w q - 0 1"]
[PlyCount "24"]
[GameId "2362928712427676"]
[EventDate "2024.??.??"]

{source: The Problemist#1432 no.12 11/2024} 1. Qb2 $1 (1. Qc2 $2 e2 $1 2. Kg2 Bf2 3. Bxe2 Nd4 4. h7 Ne6 5. h8=Q+ Nf8 6. Bxa6 Bxa6 7. Bc5 Bxc5 8. Qxc5 Nc6) (1. Qxe1 $2 Nb4 $1 2. Qd1 e2 $1) (1. Qxg3 $2 Bf2+ $1 2. Kg2 Qf1+ $1 3. Kxf1 Ba6+ 4. Kg2 Bf1+ $1 5. Kxf1 Na6 6. Qg2 O-O-O 7. Bg4 (7. Be2 Nab4 8. Qxe4 Kb8 9. Qc4 Nd4 10. Qxf7 Rb7 11. Qc4 Nbc6 12. Bc5 Ne6 13. Bd3 Nxg5 14. Bxg6 e4 15. Bxe4 Nxe4 16. Qxe4 Rb5) 7... Kb8 8. Qxe4 Nab4 9. Qc4 e4 10. Bxb4 (10. Qxe4 Rb7 11. Be2 Bg3 12. Bc4 Bxd6 13. Bxf7 Rb5 14. Qxe3 Rf5+ 15. Kg2 Bf4 16. Qb6+ Kc8 17. Bxb4 Nxb4 18. h7 Rxg5+) 10... axb4 11. Bxd7 Raxd7 12. Qxc6 Rxd6 13. Qb5+ Kc7 14. Qc5+ Kd7) 1... Bf2+ (1... e2 2. Kg2 $1 Bd2 3. Qxd2 Qb6 4. Qxe2 Nb4 5. Qd2 $1) (1... Nd4 2. h7 Nf3+ 3. Bxf3 Bf2+ 4. Kg2 exf3+ 5. Kh3 $1 Qf1+ 6. Kg4 Qc4+ 7. Kh3 Qf1+) 2. Kg2 Qf1+ $1 3. Kxf1 Ba6+ 4. Kg2 $1 (4. Be2 $2 Bxe2+ 5. Qxe2 Na6) 4... Bf1+ $1 5. Kxf1 Na6 6. Qb8+ $1 (6. h7 $2 O-O-O) 6... Rxb8 7. h7 Rb1+ 8. Bc1 $1 Rxc1+ 9. Kg2 Rg1+ 10. Kh3 Rh1+ 11. Kg4 Rxh5 (11... gxh5+ 12. Kf5 Nd4+ 13. Kxe5 Nf3+ 14. Kf4 $1 Rh4+ 15. Kf5 Nd4+ 16. Ke5 Nc6+ 17. Kf5 Nd4+ 18. Ke5 Nf3+ 19. Kf5) 12. h8=Q+ $1 Rxh8 1/2-1/2
[/pgn]
For this one even Crystal9 takes either much hardware- time SMP (didn't wait long enough to know exactly how much, broke off after 5 minutes at a single try) or some Forward- Backward to keep best move with 0.00- eval in output
:)
Peter.
peter
Posts: 3672
Joined: Sat Feb 16, 2008 7:38 am
Full name: Peter Martan

Re: Fortress Positions

Post by peter »

peter wrote: ↑Thu Oct 08, 2026 2:11 pm For this one even Crystal9 takes either much hardware- time SMP (didn't wait long enough to know exactly how much, broke off after 5 minutes at a single try) or some Forward- Backward to keep best move with 0.00- eval in output
Crystal 9 with 30 threads of 16x4.3GHz- CPU with 32Gb hash and MultiPV=4:

Code: Select all

rnb1k3/r2p1p2/q1nP1PpP/p3p1PB/4p3/B3p1p1/5Q2/4b1K1 w q -

Engine: Crystal9 (32768 MB)
von the Stockfish developers (see AUTHORS f

-----
 14	 0:01 	-3.20 	1.Db2 Lf2+ 2.Kg2 Df1+ 3.Kxf1 La6+ 4.Kg2 Lf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1 La6+ 4.Kg2 Kd8 5.h7 Kc8 6.Dc2 Lb5 7.Le2 Kb7 8.Lxb5 e2 9.Dxe2 Sa6 10.Dc4 Sab4 11.Lxb4 axb4 12.Lxc6+ dxc6 13.Dxf7+ Kb6 14.Dxg6 (28.794.401.724) 55136
 25	 8:42 	-2.85 	1.Dxg3 Lf2+ 2.Kg2 Df1+ 3.Kxf1 La6+ 4.Kg2 Lf1+ 5.Kxf1 Sa6 6.Dg2 O-O-O 7.Lg4 Kb8 8.Dxe4 Sab4 9.Dc4 e4 10.Le2 Tb7 11.Dxe4 Th8 12.Lc4 Sd8 13.Le2 (28.794.401.724) 55136
 25	 8:42 	-6.40 	1.Dxe1 Sb4 2.Dc1 e2 3.Lxe2 Db6+ 4.Kh1 La6 5.h7 Dxd6 6.h8D+ Df8 7.Dxf8+ Kxf8 8.Ld1 S8c6 9.Kg2 Ke8 10.De3 Tb8 11.Kxg3 d6 12.Dxe4 Sd4 13.Lc1 Lb7 14.Dg4 (28.794.401.724) 55136
 24	 8:42 	-7.95 	1.Dc2 Lf2+ 2.Kg2 e2 3.Lxe2 Sd4 4.h7 Se6 5.h8D+ Sf8 6.Lxa6 Lxa6 7.Lb2 Sc6 8.Dxe4 Lb7 9.Kf1 O-O-O 10.Lxe5 Se6 11.Dhh4 Sxe5 12.Dxe5 Lc6 13.Dc4 Th8 14.Ke2 (28.794.401.724) 55136
So 1'10" to stay stable on 1.Qb2 at an eval already near to 0.00, which than is reached soon too.

Lc0 shines with net BT4 6147500PT332 on a RTX5070 Nvidia- GPU:

Code: Select all

rnb1k3/r2p1p2/q1nP1PpP/p3p1PB/4p3/B3p1p1/5Q2/4b1K1 w q -

Engine: Lc0v0.32.1trt (0 MB)
von The LCZero Authors.

1/02   0:00   -1.02    1.h7 exf2+ (2) 0 
...

3/07   0:00   -1.61    1.Dxe1 Sb4 2.h7 Dxd6 3.h8D+ Df8 
                       4.Dxf8+ (14) 0 

...

23/52  0:30   -1.71    1.Dc2 Lf2+ 2.Kg2 e2 3.Lxe2 Sd4 4.h7 Se6 
                       5.h8D+ Sf8 6.Lxa6 Lxa6 7.Dd1 e3 
                       8.Dg4 Lb7+ 9.Kh3 g2 10.De6+ fxe6 
                       11.Dg7 g1S+ 12.Kh2 Sf3+ 13.Kh3 Sxg5+ 
                       14.Kh2 (451.810) 14 

23/52  0:31   -0.13    1.Db2 Lf2+ 2.Kg2 Df1+ 3.Kxf1 La6+ 
                       4.Kg2 Lf1+ 5.Kxf1 Sa6 6.Db8+ Txb8 
                       7.h7 Tb1+ 8.Lc1 Txc1+ 9.Kg2 Tg1+ 
                       10.Kh3 Th1+ 11.Kg4 gxh5+ 12.Kf5 Sd4+ 
                       13.Kxe5 Sf3+ 14.Kf4 (497.613) 16 

24/52  0:31   -0.12    1.Db2 Lf2+ 2.Kg2 Df1+ 3.Kxf1 La6+ 
                       4.Kg2 Lf1+ 5.Kxf1 Sa6 6.Db8+ Txb8 
                       7.h7 Tb1+ 8.Lc1 Txc1+ 9.Kg2 Tg1+ 
                       10.Kh3 Th1+ 11.Kg4 gxh5+ 12.Kf5 Sd4+ 
                       13.Kxe5 Sf3+ 14.Kf4 (522.029) 16 

24/53  0:31   -0.11    1.Db2 Lf2+ 2.Kg2 Df1+ 3.Kxf1 La6+ 
                       4.Kg2 Lf1+ 5.Kxf1 Sa6 6.Db8+ Txb8 
                       7.h7 Tb1+ 8.Lc1 Txc1+ 9.Kg2 Tg1+ 
                       10.Kh3 Th1+ 11.Kg4 gxh5+ 12.Kf5 Sd4+ 
                       13.Kxe5 Sf3+ 14.Kf4 (551.041) 17 

...

29/59  0:59   -0.08    1.Db2 Lf2+ 2.Kg2 Df1+ 3.Kxf1 La6+ 
                       4.Kg2 Lf1+ 5.Kxf1 Sa6 6.Db8+ Txb8 
                       7.h7 Tb1+ 8.Lc1 Txc1+ 9.Kg2 Tg1+ 
                       10.Kh3 Th1+ 11.Kg4 gxh5+ 12.Kf5 Sd4+ 
                       13.Kxe5 Sf3+ 14.Kf4 (2.381.470) 40 
31" to stay stable on 1.Qb2, regards
Peter.
User avatar
towforce
Posts: 13366
Joined: Thu Mar 09, 2006 12:57 am
Location: Birmingham UK
Full name: Graham Laight

Re: Fortress Positions

Post by towforce »

A suggestion for automation:

* with the help of a chatbot, write a chess database query that might find blocked positions

Repeat:

- get 10 matches to that query

- for each one that's not suitable, explain to the chatbot why it's not and have it amend the query to filter out that issue

Until all 10 found are suitable positions.

Use that final query to get a large number of suitable positions.
Human chess is partly about tactics and strategy, but mostly about memory
peter
Posts: 3672
Joined: Sat Feb 16, 2008 7:38 am
Full name: Peter Martan

Re: Fortress Positions

Post by peter »

towforce wrote: ↑Thu Oct 08, 2026 4:51 pm A suggestion for automation:

* with the help of a chatbot, write a chess database query that might find blocked positions

Repeat:

- get 10 matches to that query

- for each one that's not suitable, explain to the chatbot why it's not and have it amend the query to filter out that issue

Until all 10 found are suitable positions.

Use that final query to get a large number of suitable positions.
And then make the chatbot learn the difference between a blocked position and a game deciding fortress and make it use Stockfish to judge, if the remaining found fortresses are hard enough to be not too easy and not too difficult for test positions, especially if they are single best move ones
:)
Seriously, I don't say, AI wouldn't be able to help here, I just doubt, it would spare much work of user's own, finding not again much to much positions out of bigger database that you have to judge with engines' output then yet still by yourself.
Fortresses I easily found 400 in HHdb out of first 1000 positions, 390 out of second 1000, 1 was usable as test position out of first 400, 4 out of second 390, so...
I'll have a talk with Claude about it, regards
Peter.
User avatar
Ajedrecista
Posts: 2277
Joined: Wed Jul 13, 2011 9:04 pm
Location: Madrid, Spain.

Re: Fortress positions.

Post by Ajedrecista »

Hello Peter:
peter wrote: ↑Thu Oct 08, 2026 11:40 am[...]
Indeed that way I found one more somewhat useful (for engine- testing) fortress- position, I hadn't known so far, at least hadn't stored in my big problem- database and couldn't remember it neither:
[pgn][Event "3.hm 12th Polish Chess Fed ty 2024"]
[Site "; Polish Chess Fed ty#3280 4-"]
[Date "2024.12.04"]
[Round "?"]
[White "Tarasiuk=V"]
[Black "(=3111.66a4e3)"]
[Result "1/2-1/2"]
[Annotator ""]
[SetUp "1"]
[FEN "8/qp6/p1p1p3/1PP2p2/KRP3p1/P1N1k3/1PP5/4B3 w - - 0 1"]
[PlyCount "12"]
[GameId "2362877199570320"]
[EventDate "2024.12.04"]

{(EG#26441); source: Polish Chess Fed ty#3280 4-12-2024} 1. b6 (1. Bg3 $2 Qxc5 2. bxa6 bxa6 3. Bc7 Kf3 4. Bb6 Qe5 5. Nd1 Qe2 6. Rb3+ Kf4 7. Ne3 Ke4) 1... Qb8 2. Rb3 $1 (2. Ka5 $2 Qe5 3. Rb3 Qxc5+) 2... f4 $1 (2... e5 3. Ka5 Qg8 4. Nd5+ $1 Ke2 5. Re3+ Kd1 6. Rxe5 g3 7. Bc3 cxd5 8. c6 Qc8 9. Rxd5+ Kxc2 10. c7) 3. Ka5 $1 (3. Bh4 $2 Qe5 4. Bf6 Qxc5 5. Be7 Qf5 6. Nb5+ Kf2) (3. Nb1+ $2 Ke2 4. Kb4 f3) 3... g3 (3... Qd8 4. Na4+ Ke2 5. Bb4 f3 6. c3 Qxb6+ 7. cxb6 $1 f2 8. Nc5 f1=Q 9. Nxb7) 4. Na4+ $1 (4. Nd5+ $2 Ke2) 4... Ke2 5. Bb4 g2 6. c3 g1=Q 1/2-1/2
[/pgn]

[...]
Nice find and awesome problem! Reminds me one that I posted back in 2013 and is YACPDB #274105, though this one involves more pieces and is difficult for engines.

Regards from Spain.

Ajedrecista.
User avatar
chrisw
Posts: 5154
Joined: Tue Apr 03, 2012 4:28 pm
Location: Digital Nomad. Anywhere but the Western Empire
Full name: Christopher Whittington

Re: Fortress Positions

Post by chrisw »

peter wrote: ↑Thu Oct 08, 2026 6:01 pm
towforce wrote: ↑Thu Oct 08, 2026 4:51 pm A suggestion for automation:

* with the help of a chatbot, write a chess database query that might find blocked positions

Repeat:

- get 10 matches to that query

- for each one that's not suitable, explain to the chatbot why it's not and have it amend the query to filter out that issue

Until all 10 found are suitable positions.

Use that final query to get a large number of suitable positions.
And then make the chatbot learn the difference between a blocked position and a game deciding fortress and make it use Stockfish to judge, if the remaining found fortresses are hard enough to be not too easy and not too difficult for test positions, especially if they are single best move ones
:)
Seriously, I don't say, AI wouldn't be able to help here, I just doubt, it would spare much work of user's own, finding not again much to much positions out of bigger database that you have to judge with engines' output then yet still by yourself.
Fortresses I easily found 400 in HHdb out of first 1000 positions, 390 out of second 1000, 1 was usable as test position out of first 400, 4 out of second 390, so...
I'll have a talk with Claude about it, regards
Well, as a project proposal (realistic, I hope), it would be nice to have a NN that could figure out if a position was or wasn't a fortress. Positions from real games, not constructed ones. Humungous size of training set (fortresses and non-fortresses) excludes human labelling. Might be feasible for positions restricted so say, fewer than 16 pieces, which is I guess where most real game fortresses will reside.
Suppose we defined "fortress" as position where the first iterations give large V, and the last iteration gives 0.0 or close.
To reduce the number of positions we need to give our 30 second search to, we screen our initial dataset of less than 16 pieces, to those candidate positions where abs(V) more than 100 cp but Res = 0.0
For each one of those we pass it by SF for 30 secs, and label fortress true or false.
We can get sample game positions with V and Res from SF binpacks.

Claude Code could run that proposal and tell you the counts of total positions, 16 man or fewer positions, simple (V, Res) screened positions, SF generated candidate positions.

Claude is on it now, will produce some stats on a limited sample in a few minutes ....
User avatar
chrisw
Posts: 5154
Joined: Tue Apr 03, 2012 4:28 pm
Location: Digital Nomad. Anywhere but the Western Empire
Full name: Christopher Whittington

Re: Fortress Positions

Post by chrisw »

chrisw wrote: ↑Thu Oct 08, 2026 8:29 pm
peter wrote: ↑Thu Oct 08, 2026 6:01 pm
towforce wrote: ↑Thu Oct 08, 2026 4:51 pm A suggestion for automation:

* with the help of a chatbot, write a chess database query that might find blocked positions

Repeat:

- get 10 matches to that query

- for each one that's not suitable, explain to the chatbot why it's not and have it amend the query to filter out that issue

Until all 10 found are suitable positions.

Use that final query to get a large number of suitable positions.
And then make the chatbot learn the difference between a blocked position and a game deciding fortress and make it use Stockfish to judge, if the remaining found fortresses are hard enough to be not too easy and not too difficult for test positions, especially if they are single best move ones
:)
Seriously, I don't say, AI wouldn't be able to help here, I just doubt, it would spare much work of user's own, finding not again much to much positions out of bigger database that you have to judge with engines' output then yet still by yourself.
Fortresses I easily found 400 in HHdb out of first 1000 positions, 390 out of second 1000, 1 was usable as test position out of first 400, 4 out of second 390, so...
I'll have a talk with Claude about it, regards
Well, as a project proposal (realistic, I hope), it would be nice to have a NN that could figure out if a position was or wasn't a fortress. Positions from real games, not constructed ones. Humungous size of training set (fortresses and non-fortresses) excludes human labelling. Might be feasible for positions restricted so say, fewer than 16 pieces, which is I guess where most real game fortresses will reside.
Suppose we defined "fortress" as position where the first iterations give large V, and the last iteration gives 0.0 or close.
To reduce the number of positions we need to give our 30 second search to, we screen our initial dataset of less than 16 pieces, to those candidate positions where abs(V) more than 100 cp but Res = 0.0
For each one of those we pass it by SF for 30 secs, and label fortress true or false.
We can get sample game positions with V and Res from SF binpacks.

Claude Code could run that proposal and tell you the counts of total positions, 16 man or fewer positions, simple (V, Res) screened positions, SF generated candidate positions.

Claude is on it now, will produce some stats on a limited sample in a few minutes ....
CLAUDE:
The pilot finished: all 240 sampled candidates got a 30-second Stockfish 18 search (median final depth 46).

Counts

These come from the 1 MB sample binpack bundled with nnue-pytorch, because there are no real binpacks on this machine.

Stage Count Share
Total positions 434,921
16 men or fewer 177,574 40.8% of total
Fewer than 16 men 163,493 37.6% of total
Screened: drawn game and |V| > 100 19,805 4.6% of total, 11.2% of the 16-or-fewer set
Distinct episodes (consecutive screened positions from one game collapsed to one) 6,326 1.5% of total
Given 30 s of Stockfish 240 (random sample of episodes)
Label split on the 240
Outcome Count Share
Never big: Stockfish 18 scores it under 100 cp from the first iterations and ends near zero 105 44%
Fortress by the proposal’s definition: early |V| > 100, final within 20 cp of zero 60 25%
Still above 100 cp after 30 s, though the game was drawn 46 19%
In between (final 20–100 cp) 29 12%

With only 240 positions, each share is good to roughly ±6 points.

The fortress share is sensitive to the thresholds:

Tighter zero (within 5 cp): 51 positions (21%).
Higher “large” bar (above 200 cp early): 25 positions (10%).

Scaled to the sample file, 25% of episodes is roughly 1,600 fortress-labelled episodes per 435k positions, or about 0.36% of all positions.

What this says about the proposal
The (V, Res) screen is loose. Nearly half the candidates are positions Stockfish 18 sees as drawn immediately. The binpack score is a shallow search in Stockfish’s internal units, not centipawns, so “above 100” is a low bar.
The definition excludes the hardest cases. In 19% of candidates Stockfish still shows a big advantage after 30 seconds in a game that was drawn. These are either fortresses Stockfish can’t resolve or games where the winning side slipped. I’d keep them as a third class rather than label them “not a fortress”.
30 seconds per candidate doesn’t scale to a full binpack. At this rate a billion-position file gives about 15 million episodes. On this laptop with 6 engines that is over two years, so a real run has to sample, shorten the search, or tighten the screen first.
Most of the 30 seconds may be unnecessary. I saved the full per-depth score trace for every position, so I can check how early the label settles without rerunning anything.
User avatar
chrisw
Posts: 5154
Joined: Tue Apr 03, 2012 4:28 pm
Location: Digital Nomad. Anywhere but the Western Empire
Full name: Christopher Whittington

Re: Fortress Positions

Post by chrisw »

  • File Positions Contents
    candidates_all.epd 6,326 Every screened episode (16 men or fewer, drawn game, |V| > 100), not yet searched
    fortress_resolved.epd 60 Fortress by the proposal’s definition: early |V| > 100, final within 20 cp of zero
    still_big.epd 46 Still above 100 cp after 30 s although the game was drawn
    flat_draw.epd 105 Stockfish 18 sees a draw from the first iterations
    in_between.epd 29 Final score between 20 and 100 cp
The four labelled files together are the 240 positions that got the 30-second search. Each line carries the final score (ce), depth reached (acd), Stockfish’s best move (bm, in UCI notation rather than SAN), the half-move clock, and a comment with the early peak and the binpack score.
User avatar
chrisw
Posts: 5154
Joined: Tue Apr 03, 2012 4:28 pm
Location: Digital Nomad. Anywhere but the Western Empire
Full name: Christopher Whittington

Re: Fortress Positions

Post by chrisw »

After a bit if pruning of resolved.epd, we get:

23 of the 60 are left. My earlier flags ended in “and others”, so rather than guess I applied them as two explicit rules to the whole list:

Any queen on the board: 21 removed (7, 9, 13, 14, 16, 19, 22, 23, 24, 25, 31, 35, 41, 42, 43, 45, 52, 53, 55, 56, 58).
Pure rook endings (only rooks, pawns and kings): 16 removed (8, 15, 17, 18, 21, 27, 30, 33, 38, 39, 46, 48, 49, 50, 57, 60).

The “tablebase-size” flag removed nothing extra; the two I named (15 and 21) are both rook endings.

What’s left, with the original numbering:

# FEN Early Final Depth
1 6k1/r5p1/4p1B1/3p4/p2b1B2/1n1N3P/6K1/3R4 w - - 0 46 147 2 33
2 2r3k1/R4p2/4n1p1/7p/4p3/4K1P1/P4P2/5B2 b - - 0 37 102 17 29
3 2R5/5kp1/3Bnp1p/7P/2P1K3/5P2/2r5/8 w - - 11 55 309 0 58
4 5R2/1p6/3p4/P1pN1np1/r1P3k1/8/3K2P1/8 w - - 6 51 115 0 43
5 4k3/1P2b1p1/nN2pp1p/3p4/3P4/7P/4KPP1/4B3 w - - 2 38 149 2 31
6 4k3/1R6/8/p1KP4/P1P2n1p/1P3P2/8/4r3 b - - 0 57 152 0 40
10 3r4/P7/2k5/8/8/r5P1/2p1NK2/2R5 b - - 1 61 249 3 50
11 R7/5p1k/4p1p1/3pN2p/3Pn3/4P1PP/5r2/6K1 w - - 4 45 102 0 57
12 8/8/2p2kp1/8/1nB4P/p3K3/P7/8 b - - 9 63 190 0 60
20 8/3R3p/p1N2k2/8/1pPb4/6PK/5r1P/8 b - - 1 50 127 0 38
26 8/1rB3p1/1P4R1/2k5/8/4n2P/7K/8 b - - 0 49 138 0 57
28 8/6p1/8/5K1p/4N2P/4k1P1/4n3/8 b - - 11 60 109 0 72
29 3k4/5p2/2P1p3/7p/1K4p1/6P1/5P1P/8 w - - 0 46 116 0 70
32 2r5/8/P2b4/8/1P2P3/1K2k3/5R2/8 w - - 1 60 142 0 54
34 8/8/2Bp3k/4p1p1/4P1RP/4b1P1/5r2/7K b - - 1 46 184 0 77
36 8/1p1r2pk/5p1p/P1b5/2R2PP1/3p3P/3B4/4K3 b - - 4 43 487 2 36
37 8/1K6/4k2p/6pP/6n1/6P1/8/5R2 w - - 3 72 467 0 58
40 8/5p1k/6p1/7n/4R2P/5P1P/4P1BK/r7 w - - 2 39 145 0 64
44 6R1/3k4/8/P1b5/2BnK3/3P3r/8/8 b - - 1 66 525 7 32
47 4k3/8/8/1R1P4/8/Bp1r3p/8/6K1 w - - 6 63 107 0 69
51 8/1R3p2/5pb1/1p2p1k1/1P2P1P1/4NPK1/3r4/8 b - - 0 43 131 0 50
54 8/2nk4/6p1/2P1pp1p/1NKn3P/3B2P1/5P2/8 w - - 6 52 102 14 37
59 1K1R4/2P5/6B1/4k2p/6b1/2r5/6P1/8 b - - 0 54 159 0 66

These are a material-based cut, not a verified fortress list. Number 29 is a pure pawn ending, which is a calculation draw rather than a fortress, and several others (1, 4, 10, 20) still have enough active pieces that the draw is probably tactical. On the board alone, the more fortress-shaped ones are 12, 28, 34 and 37.