Thursday night at the Hartwell library. Lena Ortiz turns her phone around so the table can see it.
In This Chapter
- 23.1 The workflow: four questions, in this order
- 23.2 Step 1 — the database: what will actually be played?
- 23.3 Step 2 — the engine: what does each choice lead to?
- 23.4 Step 3 — model games: what is the plan?
- 23.5 Step 4 — must-know positions: where do people like you go wrong?
- 23.6 The engine's blind spots: depth, horizon, and "equal but unplayable"
- 23.7 How deep should you prepare? The data by rating band
- 23.8 Dev's Najdorf fix, continued: what preparation can and cannot repair
- Spaced Review
- Project Checkpoint: prep.py
- Chapter Summary
- What's Next
Chapter 23 — Engine-Assisted Preparation: Using Stockfish and Databases to Prepare Openings at Any Level
Thursday night at the Hartwell library. Lena Ortiz turns her phone around so the table can see it.
Lena: This one again. 1.e4 e5 2.Nf3 Nf6 3.Nxe5 Nc6. I take the knight, he takes back with the d-pawn, and twenty moves later my king is on f1 and there's a bishop on c5 staring at it.
Dev: That's the Stafford Gambit. It's supposed to be bad. Hang on.
Dev types the moves into his laptop. Stockfish 19 thinks for a few seconds at depth 20 and settles on +2.11 (Stockfish 19, depth 20) for White after 4.Nxc6 dxc6 — more than two pawns, a clearly winning evaluation by any engine convention.
Dev: Two pawns. You're winning, Lena.
Lena: I don't feel like I'm winning. I feel like I'm walking through a minefield in the dark.
Sam: In my day we called those "coffee-house openings". Bad on paper, deadly on a Tuesday night.
Sam is right, and we can put a number on "deadly". In our Lichess sample (4 million rated games, October 2026) there are 406 balanced games between players averaging 1400–1799 that reached exactly that position after 4...dxc6. A +2.11 evaluation implies, through the book's win-% model, that White should score about 68.5%. White actually scored 48.3% (95% interval 42.1–54.5). The engine says White is winning; the people who sit behind the white pieces at Lena's level score less than half.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bc1, Bf1, Nb1, a2, b2, c2, d2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Nf6, c6, a7, b7, c7, f7, g7, h7 — White to move. FEN:
r1bqkb1r/ppp2ppp/2p2n2/8/4P3/8/PPPP1PPP/RNBQKB1R w KQkq - 0 5
Nobody at the table is wrong. Stockfish is right that White is objectively winning. Lena is right that the position is hard to play. And the database is right that, at her level, the hard-to-play part wins out. This chapter is about using all three of those voices — the database, the engine and the model games — to prepare openings, and about knowing which voice to trust for which question.
🎭 Composite data: Dev's games are real Lichess games played by anonymous players at his rating, assembled into one "player" so we can demonstrate the method on your own games.
Dev has his own version of the problem. In Chapter 20 his opening statistics seemed to show a Najdorf weakness: 36.0% as White against the Najdorf with 6.Be3 (the English Attack), over 50 games. The confidence interval told the real story — 24.1% to 49.9%, a gap that cannot be told apart from noise — and the population data added that White scores only 44.3% with 6.Be3 in Dev's band anyway (97 games), against 49.0% across all blitz ratings (801 games). The English Attack is hard for 1600-rated players, not just for Dev. He still plays into it often, so it is worth preparing properly. In this chapter he does exactly that, step by step, and we find out what preparation can and cannot fix.
♟️ Improver Track: Read 23.1, 23.2, 23.6 and 23.7 closely. The data in 23.7 answers "how much theory do I need?" for your level, and 23.6 explains why "the engine says it's equal" is not the end of the conversation. Do the 📋 exercises; skim the code.
🏆 Competitor Track: The workflow (23.1–23.5) is your preparation routine. Work through the English Attack example with a board open, then apply it to one line of your own repertoire. Section 23.7's over-the-board table tells you how deep classical opponents at your level stay in theory.
💻 Developer Track: Every step is a function in
outpost/prep.py(Project Checkpoint). Read the definitions of move cost, error rate and must-know score in 23.3 and 23.5 before the code.📊 Analyst Track: Sections 23.6 and 23.7 are two studies on hundreds of thousands of games — eval vs practical score across 331 opening positions, and book-exit ply by band. Check the definitions, the weighting and the selection caveats.
23.1 The workflow: four questions, in this order
Opening preparation has a reputation problem. To most club players it means one of two things: a thick book of variations memorised to move 25 and forgotten by Saturday, or an evening of clicking through Stockfish's top line until the bar on the left turns a reassuring shade of white. The first is too much memory for too little understanding. The second is worse, because it feels like work and produces almost nothing you can use at the board.
The workflow this chapter teaches is neither. It asks four questions, always in the same order:
- The database question — what will actually be played? Not what should be played: what the people you meet play, how often, and how it scores for them. Different databases answer this differently, and the difference is the first lesson.
- The engine question — what does each choice lead to? Stockfish 19 evaluates the candidates. You read its numbers as a ranking with error bars, not as a verdict, and you check that the ranking survives a deeper search.
- The model-game question — what is the plan? Strong players' games through the same position show you what to do once the moves you prepared run out. An evaluation of +0.40 is not a plan. Smyslov's pawns marching up the board in Chapter 2 are a plan.
- The must-know question — where do people like me go wrong? Out of the hundreds of positions in a line, a handful are both common and treacherous: one natural move costs a lot, and players at your level choose it often. Those positions are what you actually memorise.
📐 Definition — node, tabiya, book. A node is one position in an opening tree, reached by a specific sequence of moves. A tabiya is a node that serves as the starting point of a whole family of games (after 6.Be3 in the Najdorf, every English Attack game passes through the same tabiya). Book is the set of positions that occur often enough in a reference database to count as "known"; in this chapter, the operational book is every move sequence played at least five times in the 70,452 PGN Mentor master games from 1990 onward. A game leaves book at the first move whose sequence is not in it.
Why this order? Because each step fixes a blind spot of the one before. The engine does not know what humans play: it will happily spend your evening on a line that occurs in one game in two thousand at your level. The database does not know whether a popular move is any good: a move can be played by 70% of masters and still be a slight inaccuracy that nobody at your level will ever punish. Model games supply the plans that neither numbers nor engine lines contain. And the must-know list turns the whole tree into the short list you can carry into a game.
Grace: So the engine is step two, not step one.
Narrator: The engine is step two and the referee in step four. It's just never step one. If you start with Stockfish you end up preparing for opponents who play like Stockfish.
Grace: I've never met one of those in a FIDE open.
Narrator: Exactly. You meet people who play 6...e5 because they saw it in a video.
The rest of the chapter walks the four steps on one real line — the English Attack against the Najdorf, Dev's problem opening from Chapter 20 — and then turns to the engine's traps and to the question every club player really wants answered: how much of this do I need at my level?
23.2 Step 1 — the database: what will actually be played?
The principle. Prepare for the moves your opponents play, weighted by how often they play them. The "main line" is a property of a database, not of the position.
The reasoning. An opening tree branches fast. In our Lichess sample, after just ten plies 44.9% of games already stand in a position no other sampled game reached (the book's data snapshot, a 199,474-game sample; the comparable figure for broadcast over-the-board games is 12.8%). Every hour of preparation spent on a branch nobody plays is an hour not spent on the branch everybody plays. And the branches people play depend on who the people are.
The English Attack tabiya is a perfect test. It arises after 1.e4 c5 2.Nf3 d6 3.d4 cxd4 4.Nxd4 Nf6 5.Nc3 a6 6.Be3, and the bishop on e3 announces White's plan before White has made it: f3, Qd2, castle long, g4–g5, a pawn storm against Black's king.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bf1, Be3, Nc3, Nd4, a2, b2, c2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Nf6, Nb8, a6, d6, b7, e7, f7, g7, h7 — Black to move. FEN:
rnbqkb1r/1p2pppp/p2p1n2/8/3NP3/2N1B3/PPP2PPP/R2QKB1R b KQkq - 1 6
We asked three databases what Black plays here. The masters explorer is the Lichess opening explorer's over-the-board master database, reached through the toolkit's cached wrapper (the Lichess-games explorer now needs a login token, so we use our own Lichess sample instead). The broadcast database is our twelve months of relayed over-the-board games with FIDE ratings. The Lichess sample is our October 2026 snapshot of online games, using the subset with full move text. Games are matched by the exact move order, so a game that reached the same position via 5.Be3 a6 6.Nc3 is not counted (we come back to that in 23.8).
import chessdata as cd
from _ch23_common import board_from_sans, NAJDORF_BE3
b = board_from_sans(NAJDORF_BE3) # replays the line with python-chess
d = cd.explorer([m.uci() for m in b.move_stack]) # masters explorer, cached JSON
for m in d["moves"][:4]:
n = m["white"] + m["draws"] + m["black"]
print(m["san"], n, f"{100 * (m['black'] + m['draws'] / 2) / n:.1f}% for Black")
Masters explorer at the English Attack tabiya (after 6.Be3), Black to move
retrieved 2026-11-20; games at node: 45,847; opening: B90 Sicilian Defense: Najdorf Variation, English Attack
move n share mover_score draw avg_rating
e5 32783 71.5 46.8 64.4 2389
e6 8115 17.7 44.8 43.8 2421
Ng4 4246 9.3 45.4 62.5 2413
Nc6 299 0.7 46.0 37.1 2429
Nbd7 184 0.4 48.6 29.9 2432
At master level the picture is clean: 6...e5 in 71.5% of 45,847 games, 6...e6 in 17.7%, 6...Ng4 in
9.3%, and nothing else above 1%. Now the same question across the three databases and the rating bands
(full script code/01_database_step.py):
Black's 6th move after 6.Be3 — share of games (%) by database and band
e5 e6 Ng4 Nc6 Nbd7 Qc7 g6 b5 other games (raw n)
Masters explorer 71.5 17.7 9.3 0.7 0.4 0.2 0.1 0.1 0.1 45844
OTB <2000 73.6 14.8 6.1 1.4 0.2 0.4 1.6 1.4 0.4 554
OTB 2000–2299 78.5 13.3 6.9 0.2 0.2 0.2 0.0 0.4 0.4 535
OTB 2300+ 73.0 12.8 13.5 0.0 0.5 0.0 0.0 0.0 0.2 430
Lichess <1500 32.9 28.8 0.0 12.3 0.0 0.0 2.7 1.4 21.9 24
Lichess 1500–1799 55.3 23.5 2.9 3.2 5.1 2.6 0.6 1.3 5.5 73
Lichess 1800–2099 55.5 20.7 8.4 5.9 0.0 4.0 4.5 1.0 0.2 167
Lichess 2100+ 59.3 20.7 6.9 1.7 3.5 4.6 0.2 3.1 0.0 164

📊 Figure (described): Stacked bars show Black's sixth move after 6.Be3 in the masters explorer, three FIDE bands of broadcast over-the-board games and four Lichess bands. Over the board, at every level, 6...e5 takes roughly three quarters of the games; online, it takes only 55–59% from 1500 up, while 6...e6 and the "other moves" grey block grow. The Lichess bands rest on 24–167 games (the movetext subset), so read their bars as rough.
Three things jump out, and each changes what you would prepare.
- Over the board, the tree looks like the masters' tree at every level. Even below FIDE 2000, 6...e5 is played in 73.6% of 554 games. Club players who play the Najdorf over the board have usually learned it, and they learned the main line.
- Online, the "other" moves matter. In the Lichess 1500–1799 band, a fifth of the games go 6...e6 and about one in six goes somewhere the masters almost never go (6...Nbd7, 6...Nc6, 6...Qc7). Those Lichess bands are thin — 73 games in Dev's band — but the direction is consistent across bands.
- 6...Ng4 is a master's move. It takes 13.5% of over-the-board games at 2300+ and 9.3% of master games, but 2.9% at Lichess 1500–1799. A 1650 blitz player can postpone preparing it; a 2300 cannot.
The next ply makes the same point from White's side. After 6...e5, the masters reply 7.Nb3 in 86% of games and 7.Nf3 in 13%; club White players (Lichess 1500–2099, 136 games) play 7.Nb3 in only 65% and 7.Nf3 in 22%, with 7.Nf5 and 7.Nde2 making up most of the rest. Your opponents' choices are not a noisy copy of master choices; they are a different distribution.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bf1, Be3, Nb3, Nc3, a2, b2, c2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Nf6, Nb8, e5, a6, d6, b7, f7, g7, h7 — Black to move. FEN:
rnbqkb1r/1p3ppp/p2p1n2/4p3/4P3/1NN1B3/PPP2PPP/R2QKB1R b KQkq - 1 7
And the scores? Here the database has much less to say than its decimal points suggest:
Score for Black after each reply (Wilson 95% CI; Lichess weighted, CI on raw n)
Broadcast OTB (all bands) 6...e5 n= 1142 Black 52.5% [49.6–55.4]
Broadcast OTB (all bands) 6...e6 n= 208 Black 53.1% [46.3–59.8]
Broadcast OTB (all bands) 6...Ng4 n= 129 Black 53.9% [45.3–62.2]
Lichess (all bands) 6...e5 n= 252 Black 56.7% [50.6–62.7]
Lichess (all bands) 6...e6 n= 87 Black 44.6% [34.6–55.0]
Lichess (all bands) 6...Ng4 n= 28 Black 48.0% [30.9–65.6]
Masters explorer 6...e5 n=32783 Black 46.8%
Masters explorer 6...e6 n= 8115 Black 44.8%
Masters explorer 6...Ng4 n= 4246 Black 45.4%
Every interval in the broadcast rows overlaps every other. The Lichess 6...e5 row looks like a twelve-point gap over 6...e6, but the 6...e6 interval runs from 34.6% to 55.0% on 87 games. As Chapter 20 insisted, an opening score without its sample size is not information. Use the database for frequencies (they stabilise fast) long before you trust it for scores (they need hundreds of games per branch, and they mix the opening's merit with who chooses it).
⚠️ Common pitfall: preparing the masters' tree for an online opponent. The masters explorer is the best free database of ideas. It is a poor model of what a 1600 plays. If you prepare only from it you will know 6...Ng4 7.Bg5 h6 8.Bh4 g5 to move 12 and be surprised by 6...Nc6 on move 6. Weight the tree by the database that looks like your opponents: broadcast games for over-the-board events, your own platform's games at your rating for online play.
📋 Try it — Database research. Using
code/01_database_step.py, replace the English Attack with your own main line as White (changeNAJDORF_BE3). For your band, list Black's three most common replies and their raw game counts in the Lichess sample and in broadcast games. Which reply is at least twice as common online as over the board?
Answer
The answer depends on your line, but the method is fixed: share by database, with raw n beside every number. For the English Attack in Dev's band (Lichess 1500–1799, n = 73), 6...e6 is 23.5% online vs 14.8% over the board below FIDE 2000 (n = 554) — about 1.6 times as common, not twice — and the masters-rare moves 6...Nbd7 (5.1%) and 6...Nc6 (3.2%) are roughly twelve and four-and-a-half times as common online as in the masters explorer (0.4% and 0.7%). With 73 games, treat those online shares as ±10 points.
23.3 Step 2 — the engine: what does each choice lead to?
The principle. Ask the engine for a ranking of the candidates (multi-PV), at a stated depth, and read differences smaller than a few tenths of a pawn as ties.
The reasoning. A single engine line tells you what Stockfish would play. It does not tell you how much worse the alternatives are — and in opening preparation, the alternatives are the point: you want to know which of your opponents' likely moves give you something, and which of your own reasonable moves are equally good so you can choose the one that suits you. That is what multi-PV (multiple principal variations) gives you: the engine searches the best k moves separately and reports each one's evaluation.
📐 Definition — multi-PV and move cost. In multi-PV mode with k lines, Stockfish returns the k best moves it found, each with its own evaluation and principal variation (PV). The cost of a move is the mover's win % after the best move minus the mover's win % after this move (both from the book's win-% model of Chapter 1, same depth). A cost of 10 or more win-% points is a mistake in the book's classification.
Here is the English Attack tabiya and the main nodes after it, each at depth 22 with four lines
(code/02_engine_step.py). Evaluations are from White's point of view:
English Attack tabiya: ...6.Be3 (Black to move) — Stockfish 19, depth 22, multi-PV 4
1. Ng4 +0.31 PV: Ng4 Bc1 Nf6 f3 e5 Nb3 Be6
2. e5 +0.32 PV: e5 Nb3 Be7 f3 Be6 Qd2 Nbd7
3. Nc6 +0.36 PV: Nc6 h3 e5 Nb3 Be6 Qf3 Rc8
4. e6 +0.37 PV: e6 Be2 Qc7 Qd2 b5 f3 d5
after 6...Ng4 (White to move) — Stockfish 19, depth 22, multi-PV 4
1. Bc1 +0.38 PV: Bc1 Nf6 f3 e5 Nb3 Be6 Be3
2. Bg5 +0.25 PV: Bg5 h6 Bh4 g5 Bg3 Bg7 Qd2
3. Qe2 -0.06 PV: Qe2 Nxe3 Qxe3 Nc6 Nd5 Rb8 Nb3
4. Qd3 -0.10 PV: Qd3 Nxe3 Qxe3 Nc6 Nd5 Rb8 Nb3
after 6...e6 (White to move) — Stockfish 19, depth 22, multi-PV 4
1. f3 +0.55 PV: f3 Be7 Qd2 h5 Be2 Bd7 g4
2. Qd2 +0.49 PV: Qd2 b5 f3 Nbd7 g4 b4 Na4
3. Be2 +0.48 PV: Be2 Nbd7 f4 b6 Bf3 Bb7 a3
4. a3 +0.41 PV: a3 Be7 g4 d5 exd5 Nxd5 Nxd5
🤖 Engine check: At the tabiya, Black's four candidates sit within 0.06 pawns of each other: 6...Ng4 +0.31, 6...e5 +0.32, 6...Nc6 +0.36, 6...e6 +0.37 (Stockfish 19, depth 22, multi-PV 4). In win-% terms that is about half a point — invisible in practice. The engine is telling Black: pick the structure you understand. ...e5 gives Black the d5-hole and a fixed centre (the structure of Chapter 5); ...e6 keeps the Scheveningen pawns flexible; ...Ng4 grabs the bishop pair. All three are "equal" by the number, and completely different by the plan.
The White-to-move nodes are more instructive, because they are Dev's decisions. After 6...Ng4 the two master moves, 7.Bc1 (+0.38) and 7.Bg5 (+0.25), are both fine. The natural-looking queen moves that let Black take on e3 — 7.Qe2 (−0.06) and 7.Qd3 (−0.10) — hand White's whole edge back. That is a cost of about 4 win-% points: not a blunder, but the kind of quiet concession that adds up.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bf1, Be3, Nc3, Nd4, a2, b2, c2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Ng4, Nb8, a6, d6, b7, e7, f7, g7, h7 — White to move. FEN:
rnbqkb1r/1p2pppp/p2p4/8/3NP1n1/2N1B3/PPP2PPP/R2QKB1R w KQkq - 2 7
After 6...e6 every reasonable move keeps an edge (+0.41 to +0.55): here the engine says White can choose by plan — f3 and Qd2 for the classical English Attack, or Be2 for a quieter set-up.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bf1, Be3, Nc3, Nd4, a2, b2, c2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Nf6, Nb8, a6, d6, e6, b7, f7, g7, h7 — White to move. FEN:
rnbqkb1r/1p3ppp/p2ppn2/8/3NP3/2N1B3/PPP2PPP/R2QKB1R w KQkq - 0 7📐 Note on cp and win %. Throughout this chapter, "+0.38" means +0.38 pawns from White's point of view, and costs are in win-% points from the mover's point of view, both computed with the book's standard functions (
chessdata.win_pct).
Two engine-reading habits come out of these tables.
Habit one: read ties as ties. When four moves sit within 0.10, the engine is not ranking them; the search noise is bigger than the gaps. You will see in 23.6 that the tabiya's own evaluation wanders between +0.25 and +0.55 as the search deepens from 6 to 26 plies. A 0.05 difference between two candidates means nothing.
Habit two: multi-PV is a different search. Ask Stockfish for one line at the position after 6...e5 7.Nb3 Be6 8.f3 and depth 22 says +0.41 (Stockfish 19, depth 22) with 8...Be7 first. Ask for four lines at the same depth and it says 8...Nc6 +0.27, 8...h5 +0.31, 8...Be7 +0.49, 8...Nbd7 +0.51. Neither is "wrong": multi-PV mode splits the search across lines and lets them influence each other's move ordering, so the numbers shift by tenths. If a conclusion depends on a tenth, you do not have a conclusion.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bf1, Be3, Nb3, Nc3, a2, b2, c2, g2, h2, f3, e4; Black Ke8, Qd8, Ra8, Rh8, Be6, Bf8, Nf6, Nb8, e5, a6, d6, b7, f7, g7, h7 — Black to move. FEN:
rn1qkb1r/1p3ppp/p2pbn2/4p3/4P3/1NN1BP2/PPP3PP/R2QKB1R b KQkq - 0 8🔄 Check your understanding 1. Why does the database step come before the engine step? 2. Stockfish rates 6...Ng4 +0.31 and 6...e6 +0.37 at depth 22. Should Black prefer 6...Ng4? 3. What does a multi-PV search give you that a single best line does not?
Answer
- The engine does not know what your opponents play; preparing its top line first spends time on branches that may almost never occur at your level (6...Ng4 is 2.9% of games at Lichess 1500–1799).
- No. A 0.06-pawn gap is far below the depth-to-depth wobble of the evaluation; the choice should be made by structure and taste.
- A ranking with a cost for each alternative — which of the natural moves are free choices and which concede something (7.Qe2 after 6...Ng4 hands back about 0.4 pawns).
23.4 Step 3 — model games: what is the plan?
The principle. For every structure your preparation leads to, own one or two complete games by strong players that show the plans — for both sides — beyond the point where your moves run out.
The reasoning. 23.7 will show that a club game leaves master theory within the first handful of moves. After that, what you need is not the next move of a variation but an answer to "what am I trying to do here?" Engine lines rarely answer that question: a PV is a sequence of best moves, not an explanation, and it changes with depth. A model game is an explanation that a strong player acted out over forty moves.
Where to find them. Three sources, all reproducible from the toolkit:
- The masters explorer lists "top games" for each node — games between the highest-rated players that passed through it. At the position after 6...e5 7.Nb3 Be7 8.f3 Be6 9.Qd2 (12,564 master games; replies 9...O-O 8,891, 9...h5 2,124, 9...Nbd7 1,450), it lists Nakamura–Carlsen 2020 twice, Caruana–Mamedyarov 2018 and two 2016 games of Vachier-Lagrave. All five are draws — elite games tend to be — which is why top games alone are not enough.
- The book's PGN Mentor collection (
master_games) — great players' complete careers. - The broadcast database — the last twelve months of real over-the-board games, including this year's elite events.
outpost.prep.model_games() searches the second and third for decisive games through an exact move
sequence. After 9...h5 it finds 50 White wins in 117 games (13 in PGN Mentor, 104 in broadcasts); with
both players rated 2500+, the highest-rated classical one is Van Foreest–Giri, Tata Steel Masters 2026
(round 3, FIDE 2703 vs 2760, 1-0, 127 plies), loaded from the broadcast data. It is our modern model
game. (For the classical model game in the same structure — Judit Polgar against Boris Gelfand, Novgorod
1996 — see Case Study 1.)
1.e4 c5 2.Nf3 d6 3.d4 cxd4 4.Nxd4 Nf6 5.Nc3 a6 6.Be3 e5 7.Nb3 Be7 8.f3 Be6 9.Qd2 h5 10.O-O-O Nbd7
11.Kb1 Qc7 12.a3 Rc8 13.Nc1 O-O 14.N1a2 b5 15.Nb4 Qb7 16.Ncd5 Nxd5 17.exd5 Bf5 18.Rg1 Nb8 19.g4 hxg4
20.fxg4 Bg6 21.Bd3 Bxd3 22.Qxd3 a5 23.Na2 b4 24.a4 Qa6 25.Qxa6 Nxa6 ...
9...h5 — the brake.

♟️ Position: White Ke1, Qd2, Ra1, Rh1, Bf1, Be3, Nb3, Nc3, a2, b2, c2, g2, h2, f3, e4; Black Ke8, Qd8, Ra8, Rh8, Be6, Be7, Nf6, Nb8, e5, h5, a6, d6, b7, f7, g7 — White to move. FEN:
rn1qk2r/1p2bpp1/p2pbn2/4p2p/4P3/1NN1BP2/PPPQ2PP/R3KB1R w KQkq - 0 10
Every English Attack plan runs through g2–g4–g5, kicking the f6-knight and opening lines towards Black's king. Giri's 9...h5 is prophylaxis in the sense of Chapter 7: it answers "what does White want?" before White can do it — g4 can now be met by ...hxg4, and White has to prepare the push. At depth 22 Stockfish ranks 9...Nbd7 (+0.35), 9...h5 (+0.39) and 9...O-O (+0.41) together; the choice between them is a choice of plans, not of evaluations.
🤖 Engine check: After 9...h5 Stockfish 19 gives +0.39 (Stockfish 19, depth 20) and +0.26 (Stockfish 19, depth 24), preferring 10.Be2 to the game's 10.O-O-O. In both lines White's edge is a quarter to two-fifths of a pawn — the normal value of having the first move in a Najdorf. The engine is not telling you that the position is close to winning for anyone; it is telling you that it is a manoeuvring game, which is exactly what the next diagrams show.
13.Nc1 — the knight goes the long way.

♟️ Position: White Kb1, Qd2, Rd1, Rh1, Bf1, Be3, Nc1, Nc3, b2, c2, g2, h2, a3, f3, e4; Black Ke8, Qc7, Rc8, Rh8, Be6, Be7, Nf6, Nd7, e5, h5, a6, d6, b7, f7, g7 — Black to move. FEN:
2r1k2r/1pqnbpp1/p2pbn2/4p2p/4P3/P1N1BP2/1PPQ2PP/1KNR1B1R b k - 2 13
With the g-pawn advance slowed down, White changes plan: the knight on b3, which has nothing to do on b3, travels c1–a2–b4 to fight for d5. This is the deepest idea of the ...e5 Najdorf structure, and the reason to learn it from a game: the d5-square is the hole Black's ...e5 created (the outpost idea of Chapter 3), and both sides' pieces orbit around it. Stockfish's verdict after 13.Nc1 is +0.05 at depth 20 and +0.00 at depth 24: by the engine's measure White has nothing special. Van Foreest played it anyway, because it gives White a clear plan in a position where the "best" move gives no plan at all.
17.exd5 — the structure changes.

♟️ Position: White Kb1, Qd2, Rd1, Rh1, Bf1, Be3, Nb4, b2, c2, g2, h2, a3, f3, d5; Black Kg8, Qb7, Rc8, Rf8, Be6, Be7, Nd7, b5, e5, h5, a6, d6, f7, g7 — Black to move. FEN:
2r2rk1/1q1nbpp1/p2pb3/1p1Pp2p/1N6/P3BP2/1PPQ2PP/1K1R1B1R b - - 0 17
After 16.Ncd5 Nxd5 17.exd5 the position has a new skeleton: White's pawn on d5, Black's on d6 and e5. The c-file and Black's queenside play are still there, but the e6-bishop is attacked and must look for a new diagonal, and the d6-pawn is fixed behind White's d5-pawn. Stockfish says +0.24 at both depth 20 and depth 24 (stable), with the game's 17...Bf5 as its first choice.
19.g4 — the break arrives anyway.

♟️ Position: White Kb1, Qd2, Rd1, Rg1, Bf1, Be3, Nb4, b2, c2, h2, a3, f3, g4, d5; Black Kg8, Qb7, Rc8, Rf8, Bf5, Be7, Nb8, b5, e5, h5, a6, d6, f7, g7 — Black to move. FEN:
1nr2rk1/1q2bpp1/p2p4/1p1Ppb1p/1N4P1/P3BP2/1PPQ3P/1K1R1BR1 b - - 0 19
Ten moves after 9...h5 made g4 hard, White plays it after 18.Rg1 — prepared, with the rook behind the pawn. +0.26 (Stockfish 19, depth 20), +0.21 at depth 24. The queens came off on move 25, and the game was won 39 moves later in an endgame in which the d-pawn created on move 17 marched to d7. The depth-16 summary gives White a book accuracy of 96.0 (ACPL 16.8) and Black 93.7 (ACPL 28.3); the largest swings came around move 20 and in the endgame, not in the opening.
What the model game taught that the engine did not. Three plans: (1) when ...h5 stops g4, regroup and prepare g4 with Rg1; (2) re-route the b3-knight via c1–a2–b4 to fight for d5; (3) when you capture on d5 with the e-pawn, the d5-pawn becomes a long-term asset — in this game, the winning one. None of those plans is a move you could memorise from a PV.
⚠️ Common pitfall: model games without a filter. The most famous game in a line is often a brilliancy built on a mistake. A model game is useful when (a) it is between strong players at a slow time control, (b) it stays in your structure for a long time, and (c) the winner's plan is visible. Check the eval graph: if the game was decided by a blunder on move 22, it teaches tactics, not the opening.
🔄 Check your understanding 1. Why are the masters explorer's "top games" not enough as model games? 2. After 13.Nc1 the engine's evaluation is about 0.00. Why might a strong player still choose it?
Answer
- They are chosen by the players' ratings, and elite games in main lines are very often draws (all five listed after 9.Qd2 were); you want decisive games in which one side's plan is visible.
- Because it gives White a clear plan (the knight to b4 and the fight for d5) in a position where the engine's slightly "better" moves give no obvious plan — and an evaluation of +0.00 is still an equal, playable position.
23.5 Step 4 — must-know positions: where do people like you go wrong?
The principle. Out of the whole tree, memorise the positions that are reached often and answered badly often. Everything else you can work out at the board from the plans.
🧩 Productive struggle. Before reading on, look at the English Attack tree you have seen so far: the tabiya, 6...e5 7.Nb3, 6...e6, 6...Ng4. Where would you expect club players to make their costliest mistakes in the first dozen moves — in the main line with 6...e5, or somewhere else? Write down a guess and one reason, then compare with the data below.
The reasoning. A position deserves a place in your memory when three things are true at once: you will reach it, a natural move there is a mistake, and players like you actually make that move. Each factor alone misleads. A position with a brilliant hidden refutation that nobody reaches is trivia. A position everyone reaches but nobody gets wrong needs no study. A move the engine hates but that costs only two win-% points is not worth memorising. The product of the three is what matters.
📐 Definition — error rate and must-know score. At a node of your tree, the error rate is the share of games (weighted) in which the move played cost the mover at least 10 win-% points against the engine's best move (a mistake by the book's classification). The must-know score is reach × error rate × mean cost of those errors, where reach is the share of all games in the tree that pass through the node. It estimates the win-% points thrown away at that node per game that enters the line. A high score means: learn this position.
We built Dev's English Attack tree from every game that reached 6.Be3 by this move order — 1,519 broadcast
over-the-board games and 429 Lichess games (weighted to 1,535) — down to ply 23. For each of the 89 nodes
reached by at least 25 games, Stockfish 19 evaluated the node (three lines) and every move played there at
least three times, all at depth 18 (code/04_must_know.py). The top of the list for White's decisions:
Top must-know nodes — White to move
1.e4 c5 2.Nf3 d6 3.d4 cxd4 4.Nxd4 Nf6 5.Nc3 a6 6.Be3 Ng4 7.Bg5 h6 8.Bh4 g5 9.Bg3 Bg7
1.e4 c5 2.Nf3 d6 3.d4 cxd4 4.Nxd4 Nf6 5.Nc3 a6 6.Be3 Ng4
1.e4 c5 2.Nf3 d6 3.d4 cxd4 4.Nxd4 Nf6 5.Nc3 a6 6.Be3 e5 7.Nb3 Be7 8.f3 Be6 9.Qd2 O-O
ply games reach eval best error_rate club_error_rate mean_cost must_know human_moves
18 41 1.80 +0.32 h3 21.15 64.29 16.49 0.06 h3 44% (−1), Qd2 21% (−0), f3 21% (−16), Be2 13% (−1)
12 156 7.40 +0.30 Bg5 5.26 13.92 13.45 0.05 Bc1 44% (−1), Bg5 35% (−0), Qd2 7% (−5), Bd2 6% (−6)
18 34 1.11 +0.46 O-O-O 25.81 20.00 10.27 0.03 O-O-O 74% (−1), g4 26% (−10)
(Excerpt; the only-move-gap column is omitted. human_moves lists the moves played, their share and
their cost in win-% points at depth 18;
club_error_rate uses only Lichess games below 2100 and broadcast games below FIDE 2000, a small subset
at these deep nodes.)
The surprise is how short the list is. Of 47 White-to-move nodes and 42 Black-to-move nodes, only 2% of White nodes and none of Black's have an error rate of 25% or more. The 6...e5 7.Nb3 main line — the node 45% of all tree games pass through — has an error rate of zero: everyone, at every level, plays sensible moves there. The mistakes cluster in one branch, the one club players meet least and prepare least: 6...Ng4.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bf1, Bg3, Nc3, Nd4, a2, b2, c2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bg7, Bc8, Ng4, Nb8, g5, a6, d6, h6, b7, e7, f7 — White to move. FEN:
rnbqk2r/1p2ppb1/p2p3p/6p1/3NP1n1/2N3B1/PPP2PPP/R2QKB1R w KQkq - 2 10
This is the position after 6...Ng4 7.Bg5 h6 8.Bh4 g5 9.Bg3 Bg7. Every instinct of an English Attack player says f3: it is the move White plays in almost every other line, it kicks the knight, it prepares Qd2 and long castling. Here it is a mistake that 21% of players in our tree make (and most of the club players who reach this position):

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bf1, Bg3, Nc3, Nd4, a2, b2, c2, g2, h2, f3, e4; Black Ke8, Qd8, Ra8, Rh8, Bg7, Bc8, Ng4, Nb8, g5, a6, d6, h6, b7, e7, f7 — Black to move. FEN:
rnbqk2r/1p2ppb1/p2p3p/6p1/3NP1n1/2N2PB1/PPP3PP/R2QKB1R b KQkq - 0 10🤖 Engine check: After 10.f3? Stockfish 19 gives −1.71 (Stockfish 19, depth 22): 10...Ne3! hits the queen on d1, and the line runs 11.Qd2 Bxd4 12.Bf2 Qb6 13.Nd1 Nxc2+ 14.Qxc2. The reason is geometric: the bishop that used to guard e3 has walked to g3, so the only guard left was the f2-pawn — and f2–f3 removes it. The knight lands on e3 with tempo on the queen, and the g7-bishop, already aimed down the long diagonal at d4, joins in. The quiet alternatives keep the balance — 10.h3 +0.32 and 10.Qd2 +0.28 at depth 22 — because after them ...Ne3 is simply met by fxe3.
The general lesson: in a sideline, the main-line reflex is the most dangerous move on the board. The English Attack's moves (f3, Qd2, g4, O-O-O) are so automatic that players play them where they do not belong. That is exactly what the must-know score detects, and exactly what a list of "main-line moves" cannot.
The third node is a main-line position, and its trap is the same reflex in the other direction:

♟️ Position: White Ke1, Qd2, Ra1, Rh1, Bf1, Be3, Nb3, Nc3, a2, b2, c2, g2, h2, f3, e4; Black Kg8, Qd8, Ra8, Rf8, Be6, Be7, Nf6, Nb8, e5, a6, d6, b7, f7, g7, h7 — White to move. FEN:
rn1q1rk1/1p2bppp/p2pbn2/4p3/4P3/1NN1BP2/PPPQ2PP/R3KB1R w KQ - 3 10
After 6...e5 7.Nb3 Be7 8.f3 Be6 9.Qd2 O-O, a quarter of White players in our tree launch the pawn storm at once with 10.g4. Stockfish 19 at depth 22 answers 10...d5! (−0.37): the central break that the Najdorf structure exists to prepare, timed for the moment White's king is still on e1 — where, with the f-pawn on f3, the e1–h4 diagonal is open (the engine line includes ...Bh4+). Castling first — 10.O-O-O, +0.31 — keeps the edge and makes the attack come with the king safe.

♟️ Position: White Ke1, Qd2, Ra1, Rh1, Bf1, Be3, Nb3, Nc3, a2, b2, c2, h2, f3, e4, g4; Black Kg8, Qd8, Ra8, Rf8, Be6, Be7, Nf6, Nb8, e5, a6, d6, b7, f7, g7, h7 — Black to move. FEN:
rn1q1rk1/1p2bppp/p2pbn2/4p3/4P1P1/1NN1BP2/PPPQ3P/R3KB1R b KQ - 0 10
What about Black's side — the positions where Dev's opponents go wrong? In this tree, at these depths, almost nowhere. The highest Black error rate among frequently reached nodes is 0.8% (at the tabiya itself). Club Najdorf players, online or over the board, play the first dozen moves of the English Attack well. If Dev was hoping for a trap that wins the game by move 12, the data says there isn't one. His preparation has to aim at something else — the subject of 23.8.
📋 Try it — Engine analysis. Take pos-11 above (after 9...Bg7) and, without an engine, list White's candidate moves and what each does about the knight on g4 and the square e3. Then check your list with
engine_candidates()fromoutpost.prepat depth 18 and depth 24.
Answer
Natural candidates: 10.f3 (kicks the knight), 10.h3 (kicks it without loosening e3), 10.Qd2 (develops, covers e3), 10.Be2 (challenges g4). At depth 24 Stockfish 19 ranks 10.Qd2 +0.45, 10.h3 +0.34, 10.Be2 +0.08 (multi-PV 3); 10.f3 is −1.71 at depth 22 because of 10...Ne3. The key is not the order of the good moves but the reason the obvious one fails: the e3-square has lost its guard.
🔄 Check your understanding 1. Why is "the main line is where people go wrong" usually false for a well-known opening? 2. A node has reach 40%, error rate 1%, mean cost 12. Another has reach 2%, error rate 30%, mean cost 15. Which has the higher must-know score?
Answer
- The main line is where everyone has studied and where the moves are most natural; mistakes cluster in the less-studied branches, where main-line reflexes are wrong (10.f3? in the 6...Ng4 line).
- 0.40 × 0.01 × 12 = 0.048 against 0.02 × 0.30 × 15 = 0.090: the rare, treacherous node scores almost twice as high.
23.6 The engine's blind spots: depth, horizon, and "equal but unplayable"
Steps 2 and 4 lean on Stockfish. This section is about the ways that leaning goes wrong. None of them is a bug; all of them are consequences of what an engine evaluation is — the value of the position under best play by both sides, estimated by a search of finite depth.
Pitfall 1 — the number depends on the depth
We searched four positions at every even depth from 6 to 26, clearing the hash before each search so
that every number is an independent answer (code/02_engine_step.py):
English Attack tabiya (6.Be3):
d6 +0.34 [e5] | d8 +0.33 [e5] | d10 +0.55 [e5] | d12 +0.43 [e5] | d14 +0.43 [Ng4] | d16 +0.31 [e5] |
d18 +0.32 [e5] | d20 +0.25 [e5] | d22 +0.28 [e5] | d24 +0.40 [e5] | d26 +0.33 [e5]
after 6...Ng4:
d6 +0.33 [Bg5] | d8 +0.44 [Bg5] | d10 +0.45 [Bc1] | d12 +0.26 [Bc1] | d14 +0.29 [Bc1] | d16 +0.29 [Bc1] |
d18 +0.25 [Bc1] | d20 +0.27 [Bc1] | d22 +0.24 [Bc1] | d24 +0.23 [Bc1] | d26 +0.27 [Bc1]

📊 Figure (described): Evaluation (White's view) against search depth for the English Attack tabiya, the position after 6...Ng4, and two middlegame positions from Dev's games. The two opening positions wobble inside a band about 0.3 pawns wide and never settle on one value; the two middlegame positions jump — from +1.29 to +9.18 between depths 8 and 10 in one case, from +2.50 to +4.61 between depths 6 and 8 and again to +7.37 at depth 16 in the other.
In quiet opening positions the wobble is a few tenths and even the preferred move can flip (6...Ng4 is first at depth 14, 6...e5 at every other depth). That is why 23.3 told you to read gaps under ~0.2 as ties. The book's convention — every evaluation with its depth, and two depths whenever a conclusion depends on it — is not pedantry; it is the minimum you need to know whether a number is stable.
Pitfall 2 — the horizon
The middlegame curves in the figure show the classic engine failure, the horizon effect: a search that stops at depth d cannot see a consequence that arrives at depth d + 1, so it evaluates the position as if that consequence did not exist.

♟️ Position: White Kg2, Qe4, Rd5, Bf2, a2, b3, f3, g3, c4; Black Ke7, Qc7, Re6, Bf6, e5, a6, b7, f7, g7 — White to move. FEN:
8/1pq1kpp1/p3rb2/3Rp3/2P1Q3/1P3PP1/P4BK1/8 w - - 6 32
This position is from one of Dev's English Attack games (move 32, White to move). At depth 6 and 8, Stockfish likes the quiet 32.b4 and calls White a bit better (+1.29 (Stockfish 19, depth 6)). At depth 10 it finds 32.Bc5+! and the evaluation leaps to +9.18; at depth 24 it is +9.68 (Stockfish 19, depth 24) with the line 32.Bc5+ Ke8 33.Qh7 Qxc5 34.Rxc5 Rc6 35.Rxc6 bxc6. The bishop check drives the king back to e8 and the queen invades on h7; in the engine's main line Black ends up giving the queen for the bishop on c5, and after the rook trade that follows it is White's queen against Black's lone bishop. The tactic was always there. A shallow search simply ran out of moves before reaching the point where Black's position collapses. (Dev, to his credit, played 32.Bc5+ in the game and won.)
How common is this? We re-evaluated all 577 still-undecided positions from Dev's 19 English Attack games (plies 12–70) at depth 6 and compared them with depth 16. The median disagreement is 20 centipawns, but in 73 positions (12.7%) the two depths differ by at least a pawn, and in 29 by at least two. A quick "blitz analysis" on a phone can be off by a whole piece in one position out of eight.
⚠️ Common pitfall: shallow analysis in preparation. Phones, browser boards and "instant analysis" features often stop at modest depths. For move-by-move preparation that is fine if you then re-check the positions you intend to keep at a real depth (20+) and with a second depth. A line you prepared because "the engine said +1.3" may be +9 or −1 once the search sees past its horizon.
Pitfall 3 — "0.00 but unplayable for humans"
The engine evaluates a position under best play. Humans do not play best play. So a position can be dead equal by the number and very hard to play for one side — because one side needs a sequence of precise, unnatural moves while the other side's moves play themselves. Coaches have said this forever. Our data lets us measure it.
📐 Definition — practical residual. For an opening position (an exact move sequence), the practical residual is White's actual score from that position in a pool of games minus the score the engine evaluation implies through the book's win-% model. A residual of −10 means White's players score ten points less than the engine's number would predict.
We took every opening position (after 6, 8 or 10 plies) that occurs in at least 150 balanced Lichess
games between players averaging 1400–1799 — 331 positions from 265,222 games — and evaluated each once
with Stockfish 19 at depth 20 (code/03_equal_is_not_equal.py):
across positions: r(eval clipped ±300, club White score) = 0.092; mean |residual| vs win-% model = 4.9 pts
engine-equal positions (|eval| <= 30 cp at depth 20): 154; club White score range 37.4%–63.9% (median 51.5%);
CI excludes 50%: 21 (3 below, 18 above)
positions the engine rates >= 1.00 for one side: 32; of these the 'better' side scores below 50% at club level in 11

📊 Figure (described): Each dot is an opening position (size = number of club games, colour = ply). The orange curve is the score the engine evaluation implies. Most positions sit in a cloud between 45% and 58% whatever the engine says; positions rated +2 by Stockfish score no better than positions rated 0.00. The correlation between evaluation and club score across positions is only 0.09.
Read that correlation for what it is. Across the 331 most common opening positions at club level, the engine's evaluation barely predicts which side scores better. That does not make the engine wrong — these are all positions where nobody has yet done anything decisive, and the games are decided later by mistakes. It means the evaluation of an opening position is a statement about perfect play, and the difference between perfect and club play is larger than the differences between the openings.
Two kinds of position stand out.
Engine-equal, but one side struggles. 154 positions are within ±0.30. Their club scores run from 37.4% to 63.9%, and in 21 of them the 95% interval excludes 50% — about eight would by chance alone, so there is a real spread, but only at the edges. Two examples:

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bc1, Bf1, Ng1, Nc3, a2, b2, c2, f2, g2, h2, d4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Nf6, Nb8, d5, a7, b7, e7, f7, g7, h7 — White to move. FEN:
rnbqkb1r/pp2pppp/5n2/3p4/3P4/2N5/PPP2PPP/R1BQKBNR w KQkq - 1 5
After 1.e4 c6 2.Nc3 d5 3.exd5 cxd5 4.d4 Nf6 Stockfish says +0.00 (Stockfish 19, depth 20), yet club White players score 37.4% [29.5–46.1] (194 games). White has played an Exchange Caro-Kann with the knight already committed to c3, where it blocks the c-pawn: the usual plans (c3 and Bd3, or the c4 Panov push) are no longer available in their natural form, and the position asks White for ideas that the opening move order took away. The masters explorer has only nine games here — strong players avoid it.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bc1, Bf1, Nb1, Nf3, a2, b2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Nc6, Ng8, c3, a7, b7, c7, d7, f7, g7, h7 — White to move. FEN:
r1bqkbnr/pppp1ppp/2n5/8/4P3/2p2N2/PP3PPP/RNBQKB1R w KQkq - 0 5
The mirror image: after 1.e4 e5 2.Nf3 Nc6 3.d4 exd4 4.c3 dxc3 (the Göring Gambit, Black taking the second pawn) Stockfish says −0.07 at depth 20 — Black is fine — but club White players score 63.9% [54.9–72.0] (188 games). White's moves (Nxc3, Bc4, O-O, Qb3) are natural developing moves aimed at f7; Black's defence requires knowing exactly which piece goes where. In the masters explorer, White scores 48.4% from the same position (253 games): strong defenders neutralise the gambit, club defenders do not.
Engine-winning, but humans lose. Of 32 positions the engine rates at least a pawn better for one side, the "better" side scores below 50% at club level in 11. The largest residuals in the whole table all belong to one family: gambits where the gambiteer is objectively lost but practically dangerous.
ply key opening n cp score model resid
6 e4 e5 Nf3 Nf6 Nxe5 Nc6 Petrov's Defense: Stafford Gambit 491 212.0 47.0 68.6 -21.5
6 e4 e5 Nf3 Qf6 Nc3 c6 King's Pawn Game: McConnell Defense 162 323.0 55.8 76.7 -20.9
8 e4 e5 Nf3 Nf6 Nxe5 Nc6 Nxc6 dxc6 Petrov's Defense: Stafford Gambit 406 211.0 48.3 68.5 -20.2
8 e4 d5 exd5 Qxd5 Nc3 Qa5 Nf3 Bg4 Scandinavian Defense: Main Line 210 113.0 41.4 60.3 -18.8
8 d4 e5 dxe5 Nc6 Nf3 Qe7 Bf4 Qb4+ Englund Gambit: Main Line 189 199.0 50.0 67.5 -17.5
6 e4 e5 Nf3 d5 exd5 e4 Elephant Gambit: Paulsen Countergambit 423 106.0 42.5 59.6 -17.1
(Excerpt; cp = Stockfish 19 at depth 20 in centipawns, White's view; score = White's club score %;
model = the score the evaluation implies.) The Stafford Gambit from the opening of this chapter heads
the list twice; the Englund and Elephant gambits and a Scandinavian main line follow.

♟️ Position: White Ke1, Qd1, Ra1, Rh1, Bc1, Bf1, Nb1, Ne5, a2, b2, c2, d2, f2, g2, h2, e4; Black Ke8, Qd8, Ra8, Rh8, Bc8, Bf8, Nc6, Nf6, a7, b7, c7, d7, f7, g7, h7 — White to move. FEN:
r1bqkb1r/pppp1ppp/2n2n2/4N3/4P3/8/PPPP1PPP/RNBQKB1R w KQkq - 1 4
Is the practical gap a property of the position, or of the players? If it were just the noise of club play, it should vanish at higher levels. We checked the 125 positions with at least 100 games in both the 1400–1799 band and the 2000+ band:
positions with >= 100 games in BOTH bands: 125
SD of (score - model): club 4.9 pts, 2000+ 5.5 pts
mean |score - model|: club 3.9, 2000+ 4.3
r(club residual, 2000+ residual) = 0.414

📊 Figure (described): Each dot is one position; the horizontal axis is its practical residual at 1400–1799, the vertical axis at 2000+ (Lichess). The cloud tilts upward (r = 0.41): positions that are practically bad for White at club level tend to be practically bad at 2000+ as well, though with plenty of scatter. The gap does not shrink at the higher level.
The residuals correlate across levels (r = 0.41) and are no smaller at 2000+. So part of the "practical value" of an opening position travels with the position: it is about how hard the position is to play, not just about who is playing it. Part of it, of course, is selection: the players who choose the Göring Gambit or the Stafford are not a random sample — they are often players who have prepared that one line, against opponents who have not. Both readings point to the same preparation rule.
🔍 Why this works: An evaluation is the value of a position when both sides find the best move every time. A human's result depends on how many good moves each side has and how hard they are to find. If White's best moves in a position are quiet, unnatural and unique (the Stafford: White must find a series of precise defensive moves while Black's attacking moves are obvious), the human error rate is lopsided, and the score follows the error rate, not the evaluation. The engine measures the destination; the error rate measures the road. Step 4 of the workflow — must-know positions — is simply the error rate turned into a to-do list.
⚠️ Common pitfall: "the engine says it's equal, so it's fine for me". Equal for Stockfish means equal for Stockfish. Before adopting a line, ask the database how players at your level score from it with your colour — and if the score is far below what the evaluation implies, find out which positions cause it (23.5) before you decide.
Pitfall 4 — reading the engine's first line as the only line
The last pitfall is the most common: preparing only the engine's top move at every node. You saw in 23.3 that the top four moves at the tabiya are within 0.06 of each other, and that multi-PV and single-line searches can disagree on the order. Preparing "the" best move means preparing a line chosen by noise. Prepare the move whose structure and plans you understand among the ones the engine accepts, and know the engine's alternatives well enough to recognise them when your opponent plays them.
🔄 Check your understanding 1. At depth 6 Stockfish rates a position +1.29; at depth 10, +9.18. Name the effect and explain it in one sentence. 2. Across 331 common club opening positions, the correlation between the engine's evaluation and White's club score is 0.09. Does that mean Stockfish evaluates openings badly? 3. The Göring Gambit position after 4...dxc3 is −0.07 for the engine but scores 63.9% for White at club level and 48.4% at master level. Give two explanations.
Answer
- The horizon effect: the shallow search ends before the decisive tactic (32.Bc5+) appears, so it evaluates the position as if the tactic did not exist.
- No. The evaluation measures the position under perfect play; club results are decided by the mistakes that follow, which depend on how hard each side's position is to play — something the evaluation does not measure. Openings differ less in value than players differ from perfect play.
- (a) Practical difficulty: Black's correct defence is precise and unnatural, White's moves are natural; club defenders go wrong, masters do not. (b) Selection: players who choose the gambit have usually prepared it; their opponents often have not.
23.7 How deep should you prepare? The data by rating band
The chess question. Every coach has a rule of thumb for how many moves of theory a player needs. A common one runs: at 800–1200 know the first three to five moves and the basic plans; at 1200–1600, five to ten moves of your main lines; at 1600–2000, the main lines through the transition to the middlegame; above 2000, deep preparation with novelties. It sounds right. Can we test it?
The idea. We cannot measure what players know, but we can measure how long their games stay on known ground. If most games at 1400 leave master theory by move 3, then knowing twelve moves of theory is insurance against a fire that rarely starts. If they stay in book to move 8, twelve moves begin to pay.
📐 Definition — book exit ply. Using the book defined in 23.1 (every move sequence played at least five times in the 70,452 PGN Mentor master games from 1990 on — 25,783 sequences), a game's book exit ply is the first ply whose exact move sequence is not in the book. The player who made that move left book first. Sequences are exact move orders, so a transposition into a known position counts as leaving book; a bigger reference database would push every exit later. Use the numbers to compare bands, not as absolute "theory depth".
The script (code/05_depth_by_level.py) runs this over 492,103 balanced Lichess blitz and rapid games
(weighted to 2.1 million, bots excluded) and 209,103 over-the-board classical broadcast games:
from _ch23_common import build_book, exit_ply, sans_prefix
book, n_master = build_book(min_games=5, since=1990) # set of 'e4 c5 Nf3 ...' strings
for movetext in games.movetext:
sans = sans_prefix(movetext, 31) # first 31 SAN moves, no python-chess needed
exit_at = exit_ply(sans, book) # first ply not in the book
pool band games q25 median q75 by_move5 by_move8 still_after_move10 white_left_first
Lichess blitz+rapid <1000 34492 3.0 4.0 6.0 99.1 100.0 0.0 50.4
Lichess blitz+rapid 1000-1199 53401 4.0 5.0 6.0 98.4 100.0 0.0 49.9
Lichess blitz+rapid 1200-1399 76098 4.0 5.0 7.0 97.8 100.0 0.0 49.7
Lichess blitz+rapid 1400-1599 95576 4.0 5.0 7.0 97.2 100.0 0.0 50.1
Lichess blitz+rapid 1600-1799 95690 4.0 6.0 7.0 95.8 99.9 0.0 49.7
Lichess blitz+rapid 1800-1999 74723 4.0 6.0 8.0 93.2 99.6 0.1 50.6
Lichess blitz+rapid 2000-2199 39637 5.0 6.0 9.0 86.7 98.8 0.2 51.1
Lichess blitz+rapid 2200-2399 15649 5.0 7.0 10.0 77.7 97.0 0.8 51.7
Lichess blitz+rapid 2400+ 6837 6.0 8.0 11.0 68.8 94.9 1.3 50.5
OTB classical (FIDE) <1000 294 6.0 7.0 9.0 88.4 99.3 0.0 48.0
OTB classical (FIDE) 1000-1199 404 6.0 8.0 10.0 80.2 99.0 0.0 51.5
OTB classical (FIDE) 1200-1399 752 6.0 8.0 11.0 74.2 98.4 0.1 48.4
OTB classical (FIDE) 1400-1599 11601 6.0 8.0 11.0 71.4 96.6 0.6 52.2
OTB classical (FIDE) 1600-1799 33669 7.0 9.0 12.0 65.8 94.7 1.2 50.9
OTB classical (FIDE) 1800-1999 46017 7.0 10.0 13.0 57.2 91.4 2.3 49.6
OTB classical (FIDE) 2000-2199 48191 8.0 11.0 14.0 50.0 88.6 3.2 49.2
OTB classical (FIDE) 2200-2399 44990 8.0 11.0 14.0 44.2 86.6 3.8 48.4
OTB classical (FIDE) 2400+ 23185 9.0 12.0 15.0 37.1 82.3 5.6 49.8

📊 Figure (described): Median (dot) and interquartile range (bar) of the book exit ply for each rating band. Lichess blitz and rapid games (blue) leave master theory between ply 4 and ply 8; over-the-board classical games (orange) stay in book three to four plies longer at every band, from ply 7 below FIDE 1000 to ply 12 at 2400+. Both curves rise with rating, but gently. (Lichess and FIDE ratings are different scales; compare the shapes, not the band labels.)
What it means at the board.
- Below 1600 online, theory runs out by move 3 or 4. The median Lichess game at 1000–1599 leaves this book at ply 5 (Black's third move), and 97–98% are out by move 5. For an improving online player the old rule of thumb is, if anything, generous: three to five moves of your lines plus the plans is enough, because your opponent will almost never let you use the sixth.
- Over the board, add three or four plies at every level. A FIDE 1600–1799 classical game leaves at ply 9 (median), a 2000–2199 game at ply 11, a 2400+ game at ply 12 — and almost two-thirds of 2400+ games are still in this book after move 5 (37.1% are out by then), against 2–3% of Lichess games below 1600. Classical players prepare more and deviate later; Grace's world is not Dev's.
- Even at the top, deep theory is rare in exact move order. Only 5.6% of 2400+ classical games are still in this book after move 10. The point of deep preparation at master level is not that every game follows it; it is that the one game that does can decide a tournament.
- Neither colour leaves first more often. White leaves first in 48–52% of games in every band: "out of book" is something both players do, not something that happens to you.
Does leaving book first cost anything? In balanced games, the player who leaves first scores slightly less, at every level we can measure:
Score of the player who leaves book first (balanced games, |diff| <= 100):
Lichess avg 0-1399: leaver scores 48.5% (n=163,986)
Lichess avg 1400-1799: leaver scores 49.1% (n=191,264)
Lichess avg 1800-2199: leaver scores 48.9% (n=114,354)
Lichess avg 2200-+: leaver scores 48.7% (n=22,483)
OTB avg 0-1399: leaver scores 47.5% (n=201)
OTB avg 1400-1799: leaver scores 47.7% (n=15,416)
OTB avg 1800-2199: leaver scores 48.9% (n=26,525)
OTB avg 2200-+: leaver scores 49.7% (n=24,937)
One to two and a half points. Real, consistent, and small — about what you would expect if the move that leaves book is, on average, a slightly worse move. The engine confirms it. In the 38,874 Lichess games with server evaluations in our 15% random sample of analysed games, the book-leaving move costs its player far more than the moves before it:
games exit_move in_book_moves exit_is_mistake
band
<1000 2995 5.21 1.19 11.95
1000-1199 4415 4.42 1.12 9.42
1200-1399 5946 4.10 1.08 7.37
1400-1599 7336 3.70 1.07 6.08
1600-1799 6985 3.27 1.07 4.54
1800-1999 5426 3.01 1.04 4.09
2000-2199 3215 2.57 1.00 2.67
2200-2399 1694 2.34 0.91 1.83
2400+ 862 2.05 0.90 1.51
(Win-% points lost by the mover, Lichess model; "exit_is_mistake" = share of exits that are mistakes, i.e. cost ≥ 10 points.) Below 1000 the move that leaves book costs 5.2 win-% points on average and is a mistake 12% of the time; at 2400+ it costs 2.1 and is a mistake 1.5% of the time. In-book moves cost about one point at every level. Read that carefully: the problem at 1200 is not that players don't know theory; it is that the first move they choose on their own is often a bad one. That is a skill — finding a sound move in an unfamiliar opening position — and it is trained with principles (Chapter 19) and structures, not with more theory.
⚠️ Common pitfall: measuring your preparation by the number of moves you know. The table says a 1500 online player's games leave master book around move 3. Twenty moves of Najdorf theory will be used in a handful of games a year. What will be used every game is your answer to "what do I do when the opponent plays something I have never seen on move 4?" Prepare that: the typical plans, the pawn breaks, the piece placements — the parts of an opening that survive a deviation.
At different levels — a data-backed rule of thumb. Putting the two tables together:
| Level (pool) | Typical book exit | What to prepare |
|---|---|---|
| Lichess < 1400 | ply 4–5 | First 3–4 moves of your lines; principles for move 4 onward; one plan per structure |
| Lichess 1400–1999 / FIDE < 1600 | ply 5–8 | Main lines to move 5–6, the likely deviations (from your-level data), typical plans and must-know positions |
| FIDE 1600–2199 | ply 9–11 | Main lines to move 8–10 in your repertoire, must-know positions, model games for each structure |
| FIDE 2200+ | ply 11–12, long tail | Deep lines in critical variations, novelties checked with the engine, opponent-specific preparation (Chapter 24) |
The bands are rough and the book is our 1990+ PGN Mentor book, but the shape is the useful part: preparation depth should grow with level, and at every level the moves after theory decide more games than the moves inside it.
🔄 Check your understanding 1. At Lichess 1400–1599 the median game leaves master book at ply 5. What does that imply about the value of learning ten moves of one line? 2. The book-leaving move costs 5.2 win-% points below 1000 but only 2.1 at 2400+. What skill does that difference measure?
Answer
- Ten moves will be used rarely; most games reach unfamiliar positions by move 3, so typical plans and principles for the first unfamiliar move are worth more than the extra depth.
- Finding a sound move in an unfamiliar opening position — opening understanding rather than opening memory.
23.8 Dev's Najdorf fix, continued: what preparation can and cannot repair
Back to Dev. Chapter 20 left him with an honest diagnosis: his 36.0% with the English Attack over 50 games has an interval of 24.1–49.9%, which overlaps his band's 44.3% (97 games); the line is hard for White at 1600 for everyone; he meets it often. So he prepares it — not to fix a proven personal weakness, but because it is a frequent, difficult position at his level. Here is what the four steps produced, and what his own games say about where the effort should go.
Step 1 — what he will actually face. In his band (Lichess 1500–1799) Black chooses 6...e5 in about 55% of English Attack games and 6...e6 in about 24%; the rest is scattered (6...Nbd7, 6...Nc6, 6...Ng4, 6...Qc7). His own 19 games with move text match that picture: Black's sixth move was ...e5 in 8, ...e6 in 3, and one or two each of ...Nbd7, ...Nc6, ...Ng4, ...b5 and ...Qc7 (a few of these games reached the English Attack by a different move order, such as 5.Be3 a6 6.Nc3). Eleven of his 19 opponents did not play the masters' main line. Dev's tree therefore needs two structures (...e5 and ...e6) properly and the rest at the level of "plans and principles".
Step 2 — the engine's verdicts. Black's main replies are within 0.06 of each other at depth 22; after 6...e6 every sensible White set-up keeps +0.41 to +0.55; after 6...Ng4 both 7.Bc1 and 7.Bg5 are fine but the queen moves are not. His preparation sheet says, in effect, "nothing here is forced — choose the set-up you understand".
Step 3 — model games. Van Foreest–Giri 2026 for the ...e5 structure with ...h5; Polgar–Gelfand 1996 for ...e5 with ...Nbd7 and ...b5 (Case Study 1); and for the ...e6 structure the model games of Chapter 22. The structure matters for Black's plans too: the book's data on the English Attack shows that whether ...b5 or ...Nbd7 is the better first move depends on whether Black has played ...e6 or ...e5 (over the board, ...b5 first scores 58.4% [51.1–65.4] for Black over 178 ...e6 games, and ...Nbd7 first 56.2% [52.7–59.5] over 819 ...e5 games; the other two combinations are thin). Dev should expect different Black plans in the two structures.
Step 4 — must-know positions. From 23.5: in the 6...Ng4 branch, 10.h3 or 10.Qd2 — never the reflex 10.f3, which loses to 10...Ne3; in the ...e5 main line, castle before 10.g4.
Now the most useful check of all: what actually went wrong in his games? We analysed all 19 of Dev's
English Attack games with move text at depth 16 and located, in each, the first move of his that cost 10
win-% points or more (code/06_dev_najdorf.py):
Dev's Najdorf-6.Be3 games as White: 50; score 36.0% (W/D/L 18/0/32); with movetext: 19
movetext games: 19, Dev W/D/L 5/0/14, mean ratings Dev 1667 vs opp 1716
eval after move 10 (ply 20): median +0.21; Dev worse by >= 1.00 in 1 of 19; better by >= 1.00 in 4
Dev's first mistake (win-% drop >= 10): phase counts {'middlegame': 9, 'opening': 8, 'none': 2}; median ply 25
who made the first mistake of the game: Dev 7, opponent 12
in Dev's 14 losses: first Dev mistake in the opening phase 6, middlegame 7, endgame 0
Dev's book accuracy: opening phase 92.8, after the opening 82.9
mistakes per game by Dev: 4.00

📊 Figure (described): One line per game, White's (Dev's) win % against ply; blue = Dev won, orange = Dev lost. Inside the shaded opening phase (ply ≤ 20) almost every line stays between 40% and 65%; the big swings — in both directions — happen after ply 20. A few losses drop early (one below 20% before ply 20), and those are the games preparation could have saved.
Read the numbers slowly; they rearrange the problem.
- Dev comes out of the opening fine. After move 10 the median evaluation is +0.21 for White, and he is a pawn or more worse in only one game of 19 (but a pawn or more better in four).
- His opponents make the first mistake more often than he does (12 games to 7). His losses are not a story of being outplayed in the opening. Note too that his opponents in these 19 games averaged 1716 against his 1667 — part of the low score is simply who he was paired with.
- But six of his 14 losses do start with an opening-phase mistake (the book's opening phase is the first 20 plies, which in the English Attack runs past the end of theory). Two are exactly the kind of must-know position this chapter builds: in one game 6...Ng4 7.Be2? Nxe3 8.fxe3 handed Black the bishop pair (−1.26 (Stockfish 19, depth 22) after 7.Be2, against +0.41 for 7.Bc1 and +0.25 for 7.Bg5 at the same depth); in another, after 9.Na4 Nbd7, 10.Qd2? (Dev's first mistake) let 10...b5 trap the knight on a4. Those six losses are what preparation can repair.
- The other seven losses start in the middlegame, and his accuracy falls from 92.8 in the opening phase to 82.9 afterwards, with four mistakes per game. No amount of opening theory fixes those. Model games, plans and calculation do.
Here is a typical middlegame turning point, from a 6...Ng4 game in which Dev had reached a winning position:

♟️ Position: White Kc1, Qe3, Rd1, Rh1, Bc4, Nc3, a2, b2, c2, f3, g4, h4; Black Ke8, Qd8, Ra8, Rh8, Bg7, Bc8, d5, h5, a6, e6, g6, f7 — White to move. FEN:
r1bqk2r/5pb1/p3p1p1/3p3p/2B3PP/2N1QP2/PPP5/2KR3R w kq - 0 16
After 1.e4 c5 2.Nf3 d6 3.d4 cxd4 4.Nxd4 Nf6 5.Nc3 a6 6.Be3 Ng4 7.Qf3 Nxe3 8.Qxe3 g6 9.O-O-O Bg7 10.Bc4 Nc6 11.Nxc6 bxc6 12.h4 h5 13.f3 e6 14.g4 d5 15.exd5 cxd5, Black's king is still in the centre and the a8-rook stands on the long light diagonal. 16.Bxd5! wins: +6.63 (Stockfish 19, depth 22), with the line 16...Bd7 17.Bxa8 Qxa8. Dev played 16.Rhe1 and the evaluation fell to −1.36 at depth 16; he lost the game. Look at how Dev got there: 7.Qf3 is not a main-line move after 6...Ng4 (the masters play 7.Bg5 or 7.Bc1), and still he reached a winning position by move 15. His opening was not the problem in this game; a missed tactic against an uncastled king was — the territory of Chapter 9, not of an opening book.
🤖 Engine check: Stockfish 19 rates 16.Bxd5 at +6.63 (Stockfish 19, depth 22). In human terms: White's bishop, knight and rook all bear on d5, more attackers than Black has defenders, and the bishop that captures lands on the long diagonal aimed at the a8-rook, which has no defender that can step in cheaply. In the engine's line Black gives up the exchange (16...Bd7 17.Bxa8 Qxa8). The tactic exists because Black's king never castled and the a8-rook never moved — preconditions you learn in the tactics chapters.
Dev's preparation plan, then, has two halves.
- Opening (what this chapter can fix): the two structures (...e5, ...e6) to move 10; the must-know list (6...Ng4: 7.Bc1 or 7.Bg5, no early queen or bishop moves that allow ...Nxe3 cheaply, no 10.f3 after ...Bg7; ...e5 lines: castle before g4; no knight excursions to a4 while ...b5 is possible); one model game per structure.
- Middlegame (what it cannot): the recurring plans from the model games (the d5-square, the c4-square, pawn storms that open files) and tactics drills on positions from his own games.
What we will not claim. We will not claim that this preparation raised Dev's rating or his English Attack score. There is no such data in a 34-hour sample, and even with it the arithmetic is unkind: with 100 more English Attack games, a 95% interval on his score would still be roughly ±10 points wide, so a true improvement of five points would be invisible. The honest measure of success is narrower and checkable: in the next games that reach these positions, does Dev avoid the must-know mistakes, and does the share of his losses that begin in the opening phase go down? Chapter 35 builds the tools to track exactly that.
📋 Try it — Database research. Load Dev's composite games (
data/reference/persona_dev.parquet, stratumnajdorf_6Be3) and, for the 19 with move text, list the ply at which each game left the master book (exit_plyin_ch23_common.py) and who left it. Who leaves first more often — Dev or his opponents?
Answer
The script's output: median exit ply 13; White (Dev) left first in 12 games, Black in 7. Dev leaves theory first more often — yet his opponents make the first mistake more often (12 to 7). Leaving book is not the same as going wrong; what matters is the quality of the first move made on your own (23.7).
🔄 Check your understanding 1. Dev was a pawn or more worse after move 10 in only one of 19 English Attack games. Why, then, does the chapter still recommend opening preparation for him? 2. Seven of his 14 losses began with a middlegame mistake. Name two kinds of study that address those losses better than more theory. 3. Why can't Dev measure the effect of his preparation with his next 100 English Attack games?
Answer
- Because six of his losses began with an opening-phase mistake, and at least two of those (7.Be2 after 6...Ng4; 10.Qd2 with the knight stranded on a4) are exactly the must-know positions preparation covers — and because the line is frequent and hard at his level.
- Model games for the structures he reaches (plans around d5, c4 and the pawn storm) and tactics training on positions from his own games (the missed 16.Bxd5).
- A 95% interval on a score over 100 games is about ±10 points wide, larger than any plausible effect of preparation; he should track narrower outcomes such as avoiding the must-know mistakes.
Spaced Review
Before you look anything up, answer these from memory; then check.
- From Chapter 1: the book's win-% model turns +2.11 into about 68.5% and +0.32 into about 53%. Why does the model compress large evaluations (a pawn at +5 changes the win % much less than a pawn at 0)? And why did that compression not save the model in the Stafford Gambit?
- From Chapter 2: the threshold concept "the structure dictates the plan". In the English Attack, what changes in White's plans between the ...e5 and the ...e6 structures? (Hint: one gives White the d5-square; the other keeps it covered by a pawn.)
- From Chapter 20: Dev's 36.0% over 50 games has the interval 24.1–49.9%. Without a calculator, roughly how many games would he need for an interval about ±5 points wide?
Answers
- The win-% curve is logistic: near 0.00 each pawn moves the expected result a lot; at +5 the game is already nearly won, so another pawn adds little. The compression handles large evaluations; it cannot handle the gap between perfect play and human play, which is what the Stafford measures — the model assumes the evaluation will be realised, and at club level it is not.
- With ...e5, Black has a hole on d5 and a fixed centre: White's plans revolve around occupying or exchanging on d5 (Nd5, the d5 recapture) as well as the kingside storm; with ...e6, d5 is covered by a pawn, Black's centre is flexible (...d5 breaks become possible), and White's play is a more direct g4–g5 storm against a Scheveningen set-up.
- The interval width shrinks with the square root of n: about ±13 points at n = 50 means ±5 needs roughly (13/5)² ≈ 7 times as many games — around 350.
Project Checkpoint: prep.py
Dev: So the whole chapter is four functions and a loop.
Narrator: Four functions, a loop, and the discipline to read the output with error bars.
This chapter adds project/outpost/prep.py, the preparation module of Outpost. It is self-contained (it
imports only the toolkit) and mirrors the four steps:
| Function | Step | What it returns |
|---|---|---|
board_after(moves) · sans_from_movetext(text, n) · numbered(sans) |
— | a replayed board (illegal moves raise); fast SAN extraction from PGN movetext; readable move text |
explorer_node(board) |
1 | masters explorer moves with games, share, mover's score, draw %, average rating (cached, with retrieval date) |
GameBook.from_movetexts(texts, results, weights, max_plies) · .node() · .reach() |
1 | your database as a move tree: what is played at each node, how often, how it scores |
engine_candidates(board, depth, multipv) · move_cost() · depth_check(board, depths) |
2 | multi-PV with win-% cost per move; one move's cost; evaluations at several depths with an unstable flag |
model_games(moves, result, min_elo) |
3 | decisive games through the exact sequence from PGN Mentor and broadcast OTB data |
prep_node(board, book, depth) · must_know(book, root, ...) · prep_card(root, book, must=...) |
4 | database + engine per move with a verdict; ranked must-know nodes; a one-page Markdown prep card |
book_exit(sans, reference) |
23.7 | the first ply a game leaves a reference book |
The heart of step 4 is short enough to read in full:
for _, r in node.iterrows(): # every move played >= child_min times
b2 = b.copy()
b2.push_san(r.move)
loss = max(0.0, best - _mover_wp(eng.evaluate(b2.fen(), depth=depth)["cp_clipped"], white))
if loss >= MISTAKE: # 10 win-% points = a mistake (book definition)
err_w += r.weight
cost_w += r.weight * loss
reach = book.reach(sans)
err = err_w / node.weight.sum()
must_know_score = reach * err * (cost_w / err_w if err_w else 0.0)
The demo (code/project_checkpoint.py) runs the whole workflow on Dev's English Attack, using a
GameBook of 1,637 broadcast over-the-board games through 6.Be3:
1) Database — masters explorer
B90 Sicilian Defense: Najdorf Variation, English Attack, 45,847 games (retrieved 2026-11-20)
2) Engine — multi-PV and a depth check
rank move eval mover_win_pct cost pv depth
1 Ng4 0.30 47.24 0.00 Ng4 Bc1 Nf6 h3 e6 g4 18
2 e5 0.35 46.78 0.46 e5 Nb3 Be6 h3 Nbd7 g4 18
3 e6 0.46 45.78 1.47 e6 Qd2 Be7 f3 h5 Be2 18
depth eval best
12 0.43 e5
18 0.32 e5
24 0.40 e5 | unstable: False
prep_node: database + engine per move
move masters_share book_games book_share book_mover_score eval_after cost verdict
Ng4 9.26 133 8.13 53.38 0.25 0.00 best
e5 71.51 1221 74.63 52.99 0.30 0.00 ok
e6 17.70 236 14.43 52.75 0.45 1.19 ok
b5 0.10 12 0.73 45.83 1.03 6.43 inaccuracy
4) Must-know positions for White (GameBook >= 40 games, to ply 20, depth 18)
... every White node in this over-the-board book has error rate 0.0
(Excerpt; columns trimmed.) Two things in that output are worth a second look. First, depth_check calls
the tabiya stable — the best move is 6...e5 at depths 12, 18 and 24 and the spread is 0.11 — even though
the multi-PV ranking at depth 18 puts 6...Ng4 first: the two kinds of search disagree about the order of
near-equal moves, exactly as 23.3 warned. Second, with an over-the-board book and a 40-game threshold,
must_know() finds no White errors at all; the English Attack mistakes of 23.5 come from the online
games and the less-trodden 6...Ng4 branch. Which games you put into the GameBook decides which positions
come out as must-know — so build it from games that look like your opponents.
The module plugs into later chapters directly: Chapter 24
builds a GameBook from one opponent's games instead of a population, the training generator of
Chapter 25 can turn a
must-know list into flash-card drills, and Chapter 40's command line will expose prep_card() as
python -m outpost prep "<moves>".
💻 Developer note.
must_know()evaluates every child move with a fresh search, so a large tree is slow the first time and instant afterwards (the toolkit caches every evaluation). For trees with hundreds of nodes, batch the evaluations across processes ascode/04_must_know.pydoes with three workers.
Chapter Summary
The workflow.
| Step | Question | Tool | Read it as… | Typical pitfall |
|---|---|---|---|---|
| 1 Database | What will be played, and how often? | masters explorer, broadcast OTB, your platform at your band | frequencies first; scores only with n and an interval | preparing the masters' tree for online opponents |
| 2 Engine | What does each choice lead to? | multi-PV at a stated depth, checked at a second depth | a ranking with error bars; gaps < ~0.2 are ties | trusting one shallow number; preparing only the top line |
| 3 Model games | What is the plan? | decisive games by strong players through your structure | plans that survive deviations | studying a brilliancy decided by a blunder |
| 4 Must-know | Where do people like me go wrong? | reach × error rate × cost (must_know) |
a short list to memorise | memorising everything; ignoring sidelines where main-line reflexes fail |
Key numbers from this chapter (all from the book's data snapshot).
- English Attack tabiya: 6...e5 in 71.5% of 45,847 master games, 73.6% of 554 OTB games below FIDE 2000, 55.3% of 73 Lichess games at 1500–1799; Stockfish 19 (depth 22, multi-PV 4) rates the four main replies +0.31 to +0.37.
- Shallow vs deep: in 577 undecided positions, depth 6 and depth 16 differed by ≥ 1 pawn in 12.7%.
- 331 common opening positions at Lichess 1400–1799: r(eval, White's score) = 0.09; 154 engine-equal positions range from 37.4% to 63.9%; the Stafford Gambit (+2.11 at depth 20) scores 48.3% for White.
- Book exit (PGN Mentor 1990+, ≥ 5 games): median ply 4–8 on Lichess by band, 7–12 over the board; the book-leaving move costs 5.2 win-% points below 1000 and 2.1 at 2400+, in-book moves about 1.
- Dev's English Attack: a pawn or more worse after move 10 in only 1 of 19 games (median +0.21); six of 14 losses began in the opening phase, seven in the middlegame.
Decision checklist for preparing a line.
- Which database looks like my opponents? Pull the frequencies at my level, with raw n.
- Which replies cover at least ~80% of my games? Prepare those; for the rest, know the plans.
- Multi-PV at depth 20+, re-checked at a second depth. Are my candidate moves within ~0.2? Choose by plan.
- One model game per structure: strong players, slow time control, decisive, plan visible.
- Must-know list: where do players at my level make costly mistakes? Especially in sidelines where my main-line reflexes are wrong.
- Engine-equal ≠ human-equal: does my colour score far below the evaluation at my level? Find out why.
- Write it on one page (
prep_card). If it doesn't fit, I'm memorising instead of preparing.
What's Next
Everything in this chapter prepared a line against a population — everyone who plays the Najdorf at
Dev's level. Chapter 24 narrows the database to one person:
Grace's next opponent, a player with a 96% French habit and a real score that kills Grace's assumption about
where the weakness lies. The four steps stay the same; the GameBook gets much smaller, and the confidence
intervals much wider.