VeryChess 0.4.0
Overview
This release covers two areas: a sharper quiescence search and a rebuilt static evaluation.
First, the quiescence search — the tactical search that runs at the leaves of the main search to resolve pending captures before the position is evaluated — was responsible for roughly 87% of all nodes searched, much of it spent on hopeless captures (a queen taking a defended pawn, a rook grabbing a piece and being lost immediately). Two standard filters now curb that waste, and a proper static exchange evaluation (SEE) underpins them.
Second, the hand-crafted evaluation was rebuilt from a flat, hard-switched function into a tapered, component-based one — smoothly interpolated between middlegame and endgame by game phase — and gained full-board mobility, rook file evaluation, and drawn-endgame scaling. Measured against the pre-rework build, the evaluation work alone is worth about +118 Elo at fast time control.
There are no changes to board representation, move generation, time management, or the UCI interface in this release.
Strength
The whole evaluation rework was validated as an SPRT-gated series at 30s + 1s (search depth matters little for evaluation, so a fast control is appropriate), each stage against the one before it. Measured end-to-end against the pre-rework build, the cumulative result is +117.9 ± 31.2 Elo (LOS 100%, 372 games). As always this is self-play at a fast control and overestimates the gain against other engines and at longer controls; the individual accepted stages were tapered eval +80, full mobility +92, rook files +34, and endgame scaling +18. Move generation is unchanged (perft 23/23), and the evaluation symmetry tests pass.
What's new
Delta pruning in quiescence
A capture is skipped when, even in the most optimistic case — winning the captured piece for free plus a safety margin — the result still cannot reach the best score found so far. Promotions and positions where the side to move is in check are never pruned. This is exact at fixed depth (it only discards moves that provably cannot help) and removes about a quarter of quiescence nodes.
Static exchange evaluation (SEE)
A new SEE module evaluates the material outcome of a sequence of captures on one square without a full search — modelling each side recapturing with its least valuable attacker, including x-ray attackers revealed behind a moved piece, and en passant. It is used two ways: to skip materially losing captures in quiescence, and to order clearly losing captures after quiet moves in the main search. Together with delta pruning this cuts quiescence nodes by roughly 45%.
Tapered, component-based evaluation
The evaluation was previously flat — one set of piece-square tables, with a hard boolean switch to a handful of endgame terms once material dropped below a threshold. That switch caused an unnatural jump in the score across a single exchange. It has been rebuilt as a tapered evaluation: every component produces a middlegame and an endgame value, and the final score is interpolated between them by a game-phase measure (weighted by remaining non-pawn material). The endgame now blends in smoothly instead of snapping on.
On top of that framework, three positional terms were added:
- Full mobility. Previously only knights had a mobility term. Now knights, bishops, rooks, and queens are all scored by how many safe squares they can reach — excluding squares occupied by their own pieces and squares attacked by enemy pawns, and counting sliders through their real blockers. This was the single largest gain of the rework.
- Rooks on open files. A rook on a file with no pawns, or with no friendly pawns, now gets a bonus (larger for a fully open file, and larger in the middlegame).
- Endgame scaling. Clearly drawn material configurations are scaled toward a draw so the engine stops playing for a win it cannot achieve: opposite-colored bishops with no other pieces are halved, and a pawnless side with no more than a minor-piece edge (K+B vs K, K+N vs K, and similar) is pulled close to zero.