Value network trained on Lc0 data #2

Merged
claude merged 1 commits from value-net into main 2026-11-15 04:18:12 +01:00
Collaborator

The static evaluation behind the quiescence search is now a (768 -> 128)x2 -> 1 SCReLU network instead of the hand-written evaluation. The quiescence search itself is unchanged.

  • Training: bullet on linrock's Lc0-derived test80-2024-02-feb-2tb7p.min-v2.v6.binpack, 40 superbatches (10 min on an RTX 3070), final loss 0.0220. The setup is in train/README.md.
  • Embedding: the net is embedded with incbin. EVALFILE defaults to networks/rigby-value-v1.bin.
  • Q scale: tanh(cp / 800), the scale the net was trained on (sigmoid(cp / 400) = expected score).
  • New commands: evalfens in the engine and --check in the trainer, to compare the engine's inference with bullet's.

SPRT

https://bench.rektdie.com/test/5284/

Elo   | 502.68 +- 147.15 (95%)
SPRT  | 8.0+0.08s Threads=1 Hash=64MB
LLR   | 3.05 (-2.94, 2.94) [0.00, 10.00]
Games | N: 162 W: 150 L: 5 D: 7

Correctness

  • bullet's float evaluation of fixed positions and the engine's quantised inference agree within 6 cp. That difference is quantisation.
  • An integer re-implementation in Python matches the engine exactly.
  • Perft passes and the bench is deterministic.
  • A clean git archive build (as OpenBench does it) gives the same bench, and the network file is byte-identical.

Bench: 545914

🤖 Generated with Claude Code

The static evaluation behind the quiescence search is now a `(768 -> 128)x2 -> 1` SCReLU network instead of the hand-written evaluation. The quiescence search itself is unchanged. - **Training:** bullet on linrock's Lc0-derived `test80-2024-02-feb-2tb7p.min-v2.v6.binpack`, 40 superbatches (10 min on an RTX 3070), final loss 0.0220. The setup is in `train/README.md`. - **Embedding:** the net is embedded with incbin. `EVALFILE` defaults to `networks/rigby-value-v1.bin`. - **Q scale:** `tanh(cp / 800)`, the scale the net was trained on (`sigmoid(cp / 400)` = expected score). - **New commands:** `evalfens` in the engine and `--check` in the trainer, to compare the engine's inference with bullet's. ## SPRT https://bench.rektdie.com/test/5284/ ``` Elo | 502.68 +- 147.15 (95%) SPRT | 8.0+0.08s Threads=1 Hash=64MB LLR | 3.05 (-2.94, 2.94) [0.00, 10.00] Games | N: 162 W: 150 L: 5 D: 7 ``` ## Correctness - bullet's float evaluation of fixed positions and the engine's quantised inference agree within 6 cp. That difference is quantisation. - An integer re-implementation in Python matches the engine exactly. - Perft passes and the bench is deterministic. - A clean `git archive` build (as OpenBench does it) gives the same bench, and the network file is byte-identical. Bench: 545914 🤖 Generated with [Claude Code](https://claude.com/claude-code)
claude added 1 commit 2026-11-15 04:18:02 +01:00
The static evaluation behind the quiescence search is now a
(768 -> 128)x2 -> 1 SCReLU network instead of the hand-written
evaluation. It was trained with bullet on linrock's Lc0-derived test80
2024-02 binpack, 40 superbatches (10 min on an RTX 3070), final loss
0.0220. The quiescence search itself is unchanged.

The network is embedded with incbin (EVALFILE, default
networks/rigby-value-v1.bin). Q is tanh(cp / 800), the same scale the
network was trained on (sigmoid(cp / 400) = expected score).

Checked: bullet's float evaluation of fixed positions (trainer --check)
and the engine's quantised inference (evalfens) agree within 6 cp; an
integer re-implementation in Python matches the engine exactly. Perft
passes, bench is deterministic.

Bench: 545914

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude merged commit 6057476214 into main 2026-11-15 04:18:12 +01:00
claude deleted branch value-net 2026-11-15 04:18:13 +01:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: rektdie/Rigby#2