# Reverse-Engineer a Neural Chess Net into Hand-Tuned Evaluation Tables

> Use AI agents to probe a neural chess engine's weights, extract new evaluation structures, and refit a classical engine's tables.

- Category: [Research & Knowledge](https://agentusehub.com/categories/research-and-knowledge)
- Tools: [Claude](https://agentusehub.com/tools/claude), [ChatGPT](https://agentusehub.com/tools/chatgpt), [Other or custom](https://agentusehub.com/tools/other)
- Industry: Software
- Difficulty: Advanced
- Cost: $25–100/mo
- Source: [Hacker News](https://news.ycombinator.com/item?id=50769016)
- Published: 2026-12-05

## The problem it solves

“Reverse-Engineer a Neural Chess Net into Hand-Tuned Evaluation Tables” is an advanced Research & Knowledge AI agent workflow from Software. It connects Claude, ChatGPT and Other or custom in 5 steps. Setup takes about Not stated and running costs are about Not stated.

A classical chess engine's hand-written evaluation is weaker than a neural one, but you want to keep the fast, net-free classical design. Manually guessing which evaluation features the neural net has learned is slow and error-prone, and simply refitting existing table values yields almost no strength gain because the missing piece is the structure, not the numbers.

## How it flows

Probe neural net → Extract structures → Encode tables → Match test → Verify gains

## Step-by-step setup

1. **Set up the probe harness**: Build a script that loads the neural engine's weights and lets an agent run controlled experiments: weight decompositions, ablation of individual features, and single-position traces that show which inputs move the evaluation. Keep every experiment reproducible and logged so results can be replayed.
2. **Have agents search for missing structures**: Point the agent at the classical engine's existing evaluation terms and ask it to find patterns the neural net relies on that the hand-written code does not represent. Use ablations to confirm each candidate structure actually changes the net's output, and discard features that only look correlated.
3. **Encode findings as table values**: Translate each confirmed structure into concrete lookup tables for the classical engine, generating the values programmatically rather than by hand. Keep the tables separate from the engine code so they can be regenerated and diffed.
4. **Run a controlled strength test**: Play a large match between the modified classical engine and the unmodified baseline, and separately test a version with only refitted old tables. The second run is the control that shows whether the gain comes from new structures rather than tuning.
5. **Replicate and publish**: Repeat the match independently to confirm the result holds, then release the code, the generated tables, and the game records so others can audit the claim.

## Example prompts

### Probe neural net for missing eval features

```text
You are working on a chess engine research task. I have a neural-network chess engine and a classical engine with hand-written evaluation terms. Write a Python harness that loads the neural net's weights and supports three experiment types: weight decomposition, feature ablation, and single-position tracing that reports which inputs most affect the evaluation. Then propose a list of candidate evaluation structures the neural net may use that the classical evaluation lacks. For each candidate, describe the ablation test that would confirm it matters. Output the harness code and the candidate list with test plans. Do not assume any candidate is real until its ablation shows a measurable effect.
```

### Generate classical eval tables from findings

```text
Given the confirmed evaluation structures from the ablation experiments, write a script that generates lookup tables for a classical chess engine. Each table should encode one confirmed structure as integer values indexed by the relevant board features. Keep the tables in a separate data file from the engine source. Also produce a second, control set of tables that only refits the engine's existing terms without adding new structures. Print a summary of table sizes and value ranges for both sets so I can compare them before running any match.
```

## Frequently asked questions

### What does the “Reverse-Engineer a Neural Chess Net into Hand-Tuned Evaluation Tables” workflow do?

Use AI agents to probe a neural chess engine's weights, extract new evaluation structures, and refit a classical engine's tables.

### Which tools do I need?

You need Claude, ChatGPT and Other or custom.

### How long does it take to set up?

Plan for about Not stated. It is rated advanced. The guide walks through 5 steps, starting with “Set up the probe harness”.

### How much does it cost to run?

Expect about Not stated in running costs ($25–100/mo range).

### What problem does it solve?

A classical chess engine's hand-written evaluation is weaker than a neural one, but you want to keep the fast, net-free classical design. Manually guessing which evaluation features the neural net has learned is slow and error-prone, and simply refitting existing table values yields almost no strength gain because the missing piece is the structure, not the numbers.

---

Canonical: https://agentusehub.com/use-cases/reverse-engineer-a-neural-chess-net-into-hand-tuned-evaluation-tables

More: https://agentusehub.com/llms.txt
