Skip to content

Add more to the uci eval command output#889

Merged
codedeliveryservice merged 2 commits intocodedeliveryservice:mainfrom
Saphereye:uci-eval
Apr 14, 2026
Merged

Add more to the uci eval command output#889
codedeliveryservice merged 2 commits intocodedeliveryservice:mainfrom
Saphereye:uci-eval

Conversation

@Saphereye
Copy link
Copy Markdown
Contributor

Previously only the nnue evaluation was printed

With this PR something like this should come

$ ./target/release/reckless
eval
 NNUE derived piece values:
+-------+-------+-------+-------+-------+-------+-------+-------+
|   r   |   n   |   b   |   q   |   k   |   b   |   n   |   r   |
|-12.68 |-12.77 |-12.71 |-16.47 |       |-13.02 |-12.44 |-12.09 |
+-------+-------+-------+-------+-------+-------+-------+-------+
|   p   |   p   |   p   |   p   |   p   |   p   |   p   |   p   |
| -2.62 | -3.95 | -4.28 | -5.88 | -5.50 | -5.56 | -5.14 | -2.96 |
+-------+-------+-------+-------+-------+-------+-------+-------+
|       |       |       |       |       |       |       |       |
|       |       |       |       |       |       |       |       |
+-------+-------+-------+-------+-------+-------+-------+-------+
|       |       |       |       |       |       |       |       |
|       |       |       |       |       |       |       |       |
+-------+-------+-------+-------+-------+-------+-------+-------+
|       |       |       |       |       |       |       |       |
|       |       |       |       |       |       |       |       |
+-------+-------+-------+-------+-------+-------+-------+-------+
|       |       |       |       |       |       |       |       |
|       |       |       |       |       |       |       |       |
+-------+-------+-------+-------+-------+-------+-------+-------+
|   P   |   P   |   P   |   P   |   P   |   P   |   P   |   P   |
| +2.74 | +4.03 | +4.28 | +5.71 | +5.60 | +5.37 | +5.06 | +3.15 |
+-------+-------+-------+-------+-------+-------+-------+-------+
|   R   |   N   |   B   |   Q   |   K   |   B   |   N   |   R   |
|+10.06 |+10.17 |+10.40 |+14.83 |       |+10.51 |+10.05 | +9.83 |
+-------+-------+-------+-------+-------+-------+-------+-------+

 NNUE network contributions (White side)
+------------+------------+
|   Bucket   |   Total    |
+------------+------------+
|  0         |   +2.20    |
|  1         |   +0.50    |
|  2         |   +2.21    |
|  3         |   +1.37    |
|  4         |   +1.18    |
|  5         |   +0.98    |
|  6         |   +0.92    |
|  7         |   +0.94    | <-- this bucket is used
+------------+------------+

NNUE evaluation        +0.94 (white side)

For the first table the values are calculated like so:

  1. Full NNUE forward pass on the current position.
  2. Remove the piece and create a copy of the board without that piece.
  3. Run another full forward pass on the modified board.
  4. Contribution = baseline - without.

For the second table:

  1. For each bucket (0-7) run the forward pass using the buckets weights
  2. Add an arrow to show which bucket is used

@codedeliveryservice codedeliveryservice merged commit d8f9f78 into codedeliveryservice:main Apr 14, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants