feat: cpuct scaled by the variance of Q

Monty raises exploration where a node's results spread widely and
lowers it where they agree: cpuct *= 1 + weight * (frac - 1) with
frac = stddev(Q) / scale, pulled towards 1 by (1 - frac) / (1 +
warmup * N) while the node has few visits. Rigby now does the same
with Monty's weight 0.8462 and warmup 0.4988; Monty's scale 0.2710 is
for Q in [0, 1], so it is doubled to 0.5420 for Rigby's [-1, 1].

The variance needs the running mean of the squared results, a new
float per node: Node grows from 20 to 24 bytes, so the same Hash
holds a sixth fewer nodes (README updated).

Checked: bench deterministic; RIGBY_VERIFY_TREE build driven over UCI
with pauses (tree reuse up to 208k nodes, collections at Hash 1 MB,
wtime/winc, movetime, mate-in-one positions found, go infinite +
stop) without an abort.

Bench: 764580

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
rektdieandclaude committed 2026-11-15 22:39:28 +01:00
1 parent 74fb5eb2fb
commit 05e902c683
3 files changed
+19 -3

No files matched your search

+1 -1
View File
@@ -84,7 +84,7 @@ terminal).
| Option | Default | Meaning |
| --- | --- | --- |
| Hash | 64 | Tree memory in MB. A node takes 20 bytes. |
| Hash | 64 | Tree memory in MB. A node takes 24 bytes. |
| Threads | 1 | Only 1 for now. |
| MoveOverhead | 20 | Milliseconds kept back per move. |
| CPuct | 160 | Exploration constant x100. |