A saved preparation is the player's by his names, not the database's
name ids (they shift when a game is deleted or the file is replaced):
opened from the list, the names are found again. The period counts are
of the games a report can take (set-up games left out first). A partly
known date is in a period when any day it can mean is; a date after
today is not the newest. Reopening a hidden report notices a deleted
preparation; a colour change is saved.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The period caption shortens in a narrow row; «Last N» with both colours
shows «N + N»; the menu says from which date it counts; undated games
left out are named in the summary; no games in a period offer all games.
Without any dates a period by months takes all. Crisp icons (★, 🗐);
saved is a quiet mark. The list cuts long texts, names the colour in
words, opens on double-click, renames with Cancel, explains a missing
database, and tells while it opens one. CP_PREP_LIST for screenshots.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The report takes all the player's games, those of the last 1/2/5 years
before his newest game, or his last 50/100/200 of each colour; every
choice shows how many games it takes. Undated games count only with all.
«💾 Save» keeps a preparation with its errors in the program's data;
«📑 Preparations» in the library opens, renames and deletes them.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
online-games: the network part (lookups, probes, downloads into the database,
with their tests) moves to net.rs, built where a request may block a thread;
ureq is a dependency there only. The names, paths and states of the online
databases stay for every target.
play: the engines that play (Rodent) or judge (Maia's resignations) run as
processes driven from threads: not built for WebAssembly. getrandom has its
browser backend there.
prep: analyse (the job in engine processes) is native.
Nothing changes on the computer or Android; the tests pass as before.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
For a move that could be brilliant or great and was the engine's best, an
optional shallow search (same fixed search, go nodes SHALLOW_NODES = 5000)
keeps its best move and evaluation and the move played at that depth
(PosEval.shallow, serde default; SEARCH_VERSION unchanged). Ply.difficulty
says how much the shallow search underrates the move (Measure::Choice:
against its own best move; Measure::Depth: against the deep search).
Hardness (report.rs) says how the difficulty counts in !! and ! of the
ChessCom rules: ! only for hard moves, gaps, the capture/quiet-retreat bans,
!! for a very hard only move. The default changes nothing and makes no
shallow search; rules that use it fill old analyses in like the second
search (seconds_missing). chesscom_check takes CP_SHALLOW_NODES and the
rule parameters for experiments; review_bench CP_SHALLOW_NODES. fake_uci
learns --searchmoves and --shallow for the job test.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Preparing against an opponent (openings), one fixed engine search for the game
review everywhere, !! and ! recalibrated on chess.com (check set of 15 games),
100 classic sample games that update with the program. Formatting by cargo fmt.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every position of a game analysis (and of the opening errors) is searched by
ChessPenguin's Stockfish 19 to 1M nodes with one thread, a 32 MB hash and
ucinewgame before each search, so the evaluations depend on the position
alone: the same marks on every computer and phone, whatever the number of
engine processes (one per CPU, at most 8 on a computer and 4 on a phone, and
what the free memory holds) or the order of the positions.
- ReviewMeta.search: analyses of another search are stale; shown, but
Update makes them all again. The prep caches drop such evaluations.
- Desktop: no launch dialog (engine, quality, threads, memory are gone);
Analyse starts at once, its tooltip gives the time; the prep dialog keeps
the colour. Without the own Stockfish the download is offered.
- settings.review and prep.quality removed; old settings files still read.
- fake_uci --hash-memory; tests of determinism on processes and order.
- chesscom_check in the fixed search (CP_REVIEW_NODES for experiments);
review_bench example for times and determinism on a real engine.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The opening table moves from prep into its own crate, chess-openings, so the
game review can tell a book move (a position on a line of the table), as
chess.com does. A move is no longer great when the best other move still keeps
60 % (was 75): every chess.com ! of the check set is at 59 % or less. ChessCom
rules only. Check set: 23 agree, 5 differ (was 9).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Core: the most precise opening name stays down a line (a deeper position the
table names more generally, «Sicilian Defense» after 3.d4, does not take it
back), in the games' names and in the tree; one name per position across move
orders; the games and the last date of a position over all its move orders;
`evaluated()` (evaluations from the cache count). Report version 3.
Screen: errors judged from cached evaluations show without a run; «Checked N of
M positions · Continue» after «Stop» or a new depth; the report shows the book
only when it was computed with the chosen one; the dialog keeps the remembered
book and the same player reopens with the dialog's colour and book; «Deeper»
and the depth list share one path (setting kept, report from the cache); a
chosen error survives re-judging during the run; quitting during the run asks
first; Ctrl+W returns from a game opened from the report; a game opened at an
error opens after the move, a repeated error at its newest game.
Design (§12): the summary as a grid whose columns give way, counts in the
colours of the signs; result bars without numbers, faint over few games; move
lines numbered at White's moves; whole-move first-move lines; colour icons in
the openings table; ECO kept beside the name; the errors tab as one table with
row selection and keys (↑/↓/→/←/Enter); colour lines there only in the stack;
«Inaccuracies» switch (kept in settings) for the tab, the summary, the tree and
the games; «▾» at the right end; one colour order; the depth caption by the
room left; names first in narrow game lists; two-row games minimum in a low
window; the caption beside the stacked board; «others (N)» when narrow.
Designer's review recorded in docs/design/opponent-prep.md §12.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The «Prepare against…» entry points in the library (the filter panel's button
when a player is set, the game row's context menu, Ctrl+Shift+P), the dialog
(database, the player's spellings with the similar names apart, colour, book)
and the report screen in the stack between the library and the game: the
repertoire tree with transpositions, opening names, scores and the book
column, the openings table by family and variation, the errors tab (repeated
errors and by opening), the board of the chosen position with the line under
it, and the games of the selection, which open in the game screen at that move
with «⬅ Back to preparation».
The engine run reuses the game analysis job over the distinct opening
positions of the chosen colour: the launch dialog shares the engine picker and
the quality/threads/memory grid with review.rs (quality «Fast» by default, its
own setting), marks appear as positions are evaluated, «Stop» keeps what was
done, the evaluations and the report are cached under <cache>/prep. One engine
job per program: game analysis and the live engine are blocked meanwhile.
Core: targets and counts by colour (`targets_for`, `missing_for`), the book
step keeps its per-position counts (`book_counts`) for the tree column.
Narrow windows: the board stacks over the lists under 804 px and folds into a
button under 720 px of height; the right column is split explicitly (a nested
bottom panel is not reserved from the content above it in egui).
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
A new crate shared by the apps, no UI: what a player of a database plays
in the opening and where in the opening he goes wrong.
- Player: candidates from the database's names (initials with a full
stop work), one or several ids, White, Black or both.
- Lines: the first N plies (default 20) of the main lines, position keys,
UCI/SAN, result from the player's side, full date, opponent's Elo;
games from a set-up position are skipped.
- Repertoire tree per colour by move order with position keys:
games (+/=/-), last date, average opponent Elo, game list,
transpositions marked.
- Opening names from lichess-org/chess-openings (CC0; revision and
SHA-256 pinned, files in crates/prep/data, THIRD_PARTY_NOTICES): the
deepest named position of a line, families and variations with their
first moves, grouped by name.
- Book: a second database (or the same one without the player's games)
says where each game left it (first position with fewer than T games,
T = 5) and whose move it was.
- Engine: every distinct position of the lines once through
game_review::run, judged with the game analysis rules for the player's
moves only; errors by opening and the repeated ones (same position,
same move in two or more games); evaluations cached per position across
reports, the report cached by database, player and plies.
- examples/prep_report.rs prints it all for a database and a player.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>