Offline experiment · detector ai-workspace/game-story-prod-review/regen/positional-detect.mjs · chess.js only, no engine call, no Python change · 2026-09-04

Can plain board rules (passed pawn, king cover, open file, trapped piece...) explain the 58 pending moments? Result: about a third, not all.

1. What I built

A Node script reads each pending moment: the position before the move, the move played, the better move, and the engine's 6-ply line after each. It computes board facts for both sides at each ply of both lines, and fires a rule when the played line is worse on a fact and the move that caused it is the played move or the reply. Fuzzy facts (piece mobility, checks available, attackers near the king) are kept apart as weak signals.

RuleIn wordsPrimary hits
perpetual-check-missedA draw by perpetual check was there3
piece-trappedA piece is attacked and has no safe square3
piece-pinnedA piece is pinned2
forced-queen-tradeThe reply forces a queen trade0
forced-rook-tradeThe reply forces a rook trade0
needless-tradeThe move trades off a good piece for nothing0
king-walks-from-coverThe king walks away from its pawn cover1
king-to-centerThe king walks into the open1
king-cover-lostA pawn in front of the king is gone1
passed-pawn-for-themThe move gives them a passed pawn1
passed-pawn-lostThe better move made a passed pawn1
their-passer-advancesTheir passed pawn runs1
best-was-rook-to-open-fileThe better move puts a rook on the open file7
rook-leaves-open-fileThe rook leaves the open file2
their-rook-takes-file-or-7thTheir rook takes the open file or the 7th rank1
piece-hangingA piece is attacked and must move (tempo)4
knight-to-rimThe knight goes to the edge1
pawn-structureThe move makes doubled or isolated pawns0
their-outpostTheir piece gets an outpost0
pawn-attacked-more-than-defendedA pawn has more attackers than defenders5
makes-wayThe better move clears a square for the next move4
king-under-attackMore attackers near the king (fuzzy)1
more-checks-on-meThey get many more checks (fuzzy)1
less-activeYour pieces have far fewer moves (fuzzy)4

2. The numbers

Pending moments58
A concrete rule fires38
Only a fuzzy rule fires6
Nothing fires14

A rule that fires is not a rule that is right. I checked 14 of the concrete hits by hand on the board. 11 of 14 name the real reason or a fair part of it. 3 name a side fact and miss the real reason.

So the honest estimate is: the concrete rules give a true, simple sentence for about 30 of the 58 moments. Of those, some already appear in today's story as a fact appendix (for example "It gives them a passed pawn on c3"). The other 28 need something else: a forcing line the story rejects today, the threat search, or a reason no board rule can name.

3. Where the wrong hits come from

The wrong hits share one shape: the rule sees a true fact that is not the point. A king-cover rule fires on a pawn push far from any danger. A hanging-rook rule fires when the real story is a rook trade into a pawn ending. A knight-guard rule fires when the real miss is a mating attack. Board rules cannot rank facts by importance. The engine score says how bad the move is, but not why.

Two wrong hits pointed at rules I did not have. Both are now in the script and both are Node-only: a perpetual check that was there (the better move gives check after check, or the line repeats, and the score is level), and a reply that forces a queen or rook trade into a lost ending.

4. Every pending moment

CaseSidePlayedBetterDropPrimary ruleDetailOther hitsHand check
1b858313:31
positional-gives-material
wQd4Qc4520A piece is attacked and has no safe squarepiece-trapped@2 qd4 after Qe5+piece-hanging@2, forced-queen-trade@4right Qe5+ forces the queen trade into a lost pawn ending.
43b0c5fa:16
positional-no-material
ba4Rg7130nothing fires
43b0c5fa:27
lines-too-short
wd7Qe6100A pawn in front of the king is goneking-cover-lost@1 shield 0 vs 1 after d7pawn-attacked-more-than-defended@2wrong The pawn push is far from any danger. The real point is the a-pawn run after Qe6.
43b0c5fa:30
positional-gives-material
bQf3+Rg3+114nothing fires
1ee86237:9
positional-gives-material
wQxa4Ng5-nothing fires
ce5469b0:2
positional-no-material
bRb5Rbd8113The better move puts a rook on the open filebest-was-rook-to-open-file@1 Rbd8their-rook-takes-file-or-7th@2right Rbd8 doubles rooks on the d-file. Rb5 lets their rook swing to f2.
aaf8f107:4
last-move-no-reply
bRc7Rfe8109The better move puts a rook on the open filebest-was-rook-to-open-file@1 Rfe8rook-leaves-open-file@1
8d0b0f46:7
last-move-no-reply
wBf4Nh5187Your pieces have far fewer moves (fuzzy)less-active@2 mob 31-43 vs 40-44
material changes in the line at ply 6
67088156:6
positional-no-material
bd3Rac8140The better move puts a rook on the open filebest-was-rook-to-open-file@1 Rac8pawn-attacked-more-than-defended@1right Rac8 takes the open c-file.
67088156:12
positional-gives-material
bKh8Kxh7248Your pieces have far fewer moves (fuzzy)less-active@1 mob 56-34 vs 57-27
material changes in the line at ply 1
more-checks-on-me@2
9f68fbe5:1
positional-gives-material
wQh4Qg3226The better move clears a square for the next movemakes-way@1 Qg3 clears f2 for Rxf8+
material changes in the line at ply 3
passed-pawn-for-them@2, their-passer-advances@2, piece-hanging@2right f4 hits the bishop with tempo. The story already says it.
9f68fbe5:7
last-move-no-reply
wBh6Kf2485A piece is attacked and has no safe squarepiece-trapped@2 bh6 after Qg4+
material changes in the line at ply 5
piece-hanging@2
4661effb:14
positional-no-material
bBxd4Qa2+140A piece is pinnedpiece-pinned@1 bd4>q after Bxd4makes-way@1, less-active@1, more-checks-on-me@2
4661effb:46
positional-gives-material
bQb2+Bxg3+211A piece is attacked and must move (tempo)piece-hanging@2 bd6 after Kh1
material changes in the line at ply 1
4661effb:49
positional-no-material
wQc5+Qc4+317The better move clears a square for the next movemakes-way@1 Qc4+ clears d5 for Qg8+piece-hanging@2wrong The knight guard is a side point. The real miss is the mating attack after Qc4+.
4661effb:50
last-move-no-reply
bKd8Kb8251The king walks away from its pawn coverking-walks-from-cover@1 shield 0 vs 1king-to-center@1, piece-trapped@2, more-checks-on-me@2, less-active@2
60a3b89d:2
positional-gives-material
bBxf3e5103The better move clears a square for the next movemakes-way@1 e5 clears e6 for Qg4+needless-trade@2right Bxf3 trades off the strong bishop for nothing (needless trade). The hanging rule alone was wrong.
b8eb8d2e:4
positional-gives-material
bg5Rb8129The better move puts a rook on the open filebest-was-rook-to-open-file@1 Rb8
material changes in the line at ply 2
more-checks-on-me@1, less-active@1, passed-pawn-for-them@2
1eb7a1d5:10
positional-no-material
bRd8Kg8122Their passed pawn runstheir-passer-advances@2 a5right The a-pawn runs. The story already says it.
1eb7a1d5:12
positional-no-material
bRa8Rb8103The rook leaves the open filerook-leaves-open-file@1 Ra8
1eb7a1d5:15
positional-gives-material
wRe7a7121The rook leaves the open filerook-leaves-open-file@1 Re7piece-hanging@2, less-active@2
bead1460:5
positional-no-material
wQf4Bxf7+208Your pieces have far fewer moves (fuzzy)less-active@1 mob 45-38 vs 39-1
material changes in the line at ply 1
bead1460:11
positional-gives-material
wQxh5Qe5+300A pawn has more attackers than defenderspawn-attacked-more-than-defended@1 pe4 after Qxh5
material changes in the line at ply 4
makes-way@1, less-active@1, passed-pawn-for-them@2
7cda97b2:1
positional-no-material
wb3Re4180The move gives them a passed pawnpassed-pawn-for-them@2 c3 vs - after c3
material changes in the line at ply 3
their-passer-advances@2right c3 makes a passed pawn. The story already says it.
f55d277e:23
last-move-no-reply
wKg1Re8+133The better move puts a rook on the open filebest-was-rook-to-open-file@1 Re8+
material changes in the line at ply 5
less-active@1
94a9fa9c:1
positional-no-material
wNe5+Qd5+194A pawn has more attackers than defenderspawn-attacked-more-than-defended@2 pd4 after Bxe5
material changes in the line at ply 2
32f1cb86:1
positional-no-material
wRc2Qe4175A piece is attacked and must move (tempo)piece-hanging@2 qf4 after Nd5
32f1cb86:5
last-move-no-reply
wRcb2Rxb7+329A draw by perpetual check was thereperpetual-check-missed@1 best line gives 12 checks in a row, repeats 5
material changes in the line at ply 1
rook-leaves-open-file@1, less-active@1
bd4f3950:13
positional-no-material
wQh3+Qe7141A pawn has more attackers than defenderspawn-attacked-more-than-defended@2 pe5 after Kg7less-active@2
fd99145d:19
positional-gives-material
wNh5Ne4152The knight goes to the edgeknight-to-rim@1 Nh5
material changes in the line at ply 5
right The knight goes to the edge. Ne4 goes to the centre.
1962fb77:4
positional-gives-material
bc3d3+125A piece is attacked and must move (tempo)piece-hanging@2 qc5 after Qa3
material changes in the line at ply 5
less-active@1, forced-queen-trade@4
272bfb10:2
positional-gives-material
bR7g5Qd5+294A pawn has more attackers than defenderspawn-attacked-more-than-defended@1 pf6 after R7g5
material changes in the line at ply 2
more-checks-on-me@1, less-active@1, piece-trapped@2, passed-pawn-lost@3
a3bbe4cb:25
positional-gives-material
wRd2+c6+127A piece is attacked and must move (tempo)piece-hanging@2 rd2 after Ke7forced-rook-trade@4wrong Rd2+ trades rooks into a pawn ending. The rule names a hanging rook instead.
a3bbe4cb:33
positional-gives-material
wh4Kg3103nothing fires
22d12591:9
positional-no-material
wNc2Qxc5110nothing fires
material changes in the line at ply 1
22d12591:14
positional-no-material
bQd7+Qe2+213nothing fires
material changes in the line at ply 3
6f76c4ae:26
positional-no-material
bQg5Qd7623They get many more checks (fuzzy)more-checks-on-me@2 10 vs 1less-active@2
6f76c4ae:27
positional-no-material
wQa7+Qd3+426nothing fires
6f76c4ae:28
positional-no-material
bKg6Kh6621A draw by perpetual check was thereperpetual-check-missed@1 best line gives 6 checks in a row, repeats 2
material changes in the line at ply 4
piece-trapped@2, piece-pinned@2, less-active@2
6f76c4ae:32
last-move-no-reply
bQf6Kh5609A piece is pinnedpiece-pinned@1 qf6>k after Qf6
material changes in the line at ply 2
less-active@1, king-under-attack@2, more-checks-on-me@2, forced-queen-trade@4
db8a2113:15
positional-no-material
wgxf4Qc7+292A draw by perpetual check was thereperpetual-check-missed@1 best line gives 12 checks in a row, repeats 3pawn-structure@1, less-active@1, pawn-attacked-more-than-defended@2, more-checks-on-me@2right Qc7+ was a perpetual check, a draw in a lost position. The pawn-structure hit alone was wrong.
43af0bc8:6
last-move-no-reply
bKf7Kg8102The king walks into the openking-to-center@1 Kf7
material changes in the line at ply 5
piece-trapped@2, more-checks-on-me@2
977851fe:11
positional-no-material
wRh5+Re5100The better move puts a rook on the open filebest-was-rook-to-open-file@1 Re5rook-leaves-open-file@1, their-rook-takes-file-or-7th@2
c41cdcae:6
last-move-no-reply
bRe7Rf8194Their rook takes the open file or the 7th ranktheir-rook-takes-file-or-7th@2 Rc1plausible Rc1 takes the open c-file and later hits the queen from c4.
2a899703:4
positional-gives-material
bQh3+Rxf4126nothing fires
material changes in the line at ply 1
4fd0f10c:5
positional-no-material
wNxd3Rxd3112The better move clears a square for the next movemakes-way@1 Rxd3 clears d2 for Rxd3
f1bb4037:5
positional-gives-material
wb7Nxf7128nothing fires
material changes in the line at ply 1
right Be5 hits the queen. The story already says it.
9744412f:18
positional-no-material
bKh6Qd6238nothing fires
c7dbddd0:9
last-move-no-reply
wQc7Qd6107nothing fires
material changes in the line at ply 3
35b8cf0e:2
positional-gives-material
bQh7Qc6221nothing fires
material changes in the line at ply 2
a76b4a7b:7
positional-no-material
wQd7Qa4247The better move made a passed pawnpassed-pawn-lost@3 best line makes a2 with Qa4 Re6 Qxa6
material changes in the line at ply 3
more-checks-on-me@2
a76b4a7b:11
positional-no-material
wQd2Qd4351Your pieces have far fewer moves (fuzzy)less-active@1 mob 24-21 vs 27-15
material changes in the line at ply 5
more-checks-on-me@2
e8fe4db8:23
positional-no-material
wQg7+Re1+144The better move puts a rook on the open filebest-was-rook-to-open-file@1 Re1+pawn-attacked-more-than-defended@2
f2a38c62:6
positional-gives-material
bQf7Qd6236nothing fires
material changes in the line at ply 3
da9088aa:2
positional-no-material
bNe7Qc7253A piece is attacked and has no safe squarepiece-trapped@1 ne7 after Ne7
material changes in the line at ply 4
piece-pinned@2
da9088aa:10
last-move-no-reply
bKg6Kh6112More attackers near the king (fuzzy)king-under-attack@1 zone attacks 6 vs 3more-checks-on-me@2
ac42ef5a:6
positional-gives-material
bBf6Bxg3110nothing fires
material changes in the line at ply 1
ac42ef5a:12
positional-no-material
bg6Bd4151A pawn has more attackers than defenderspawn-attacked-more-than-defended@1 pg6 after g6makes-way@1

5. What I would do

Ship the rules that were right every time I checked them, each as one fixed sentence, only when the engine line agrees (the rule's move is in the line):

Do not ship the fuzzy rules (mobility, checks, king-zone attackers). They fire often and name nothing a reader can see.

Expected effect: a true, simple sentence for about 30 of the 58 pending moments, with zero engine time. The other 28 stay as they are unless the threat search comes back for the 21 sharp-threat cases, which overlap with these in part.