Does Reasoning Transfer Follow Structure or Surface?

When a language model is trained with reinforcement learning on math and then scores higher on coding or science questions, the field reads this as "reasoning transfer." Two problems make that reading unsafe. First, the test sets are public and often memorized. Some models reproduce MATH-500 solutions from a partial prompt, and some gain points even under random rewards (Reasoning or Memorization?). Second, nobody separates two things a source and a target domain can share: the surface (vocabulary, topic, narrative framing) and the structure (the graph of operations and dependencies needed to reach the answer). Work on retrieval for in-context examples has already shown that surface similarity is a poor proxy for shared reasoning steps. Transfer research has not yet applied that lesson to itself.

We propose to measure transfer on freshly generated problems in which structure and surface are varied independently. Each problem is produced by sampling a computation graph and then rendering it in one of several domain "skins": a math word problem, a Python function to trace, a table query, or a procedural rule-application text. We train a model with reinforcement learning on one structure-skin cell and measure its gain on every other cell. The result is a contamination-free transfer matrix that splits each gain into a structural part and a surface part. The bet is that transfer is mostly structural. If so, the conflicting reports on whether math training helps elsewhere become a predictable consequence of how little structure math benchmarks share with the algorithmic targets, compounded by contamination.

Core Claim

On leakage-free evaluation, the gain from reinforcement learning on a source task is predicted by how much its computation-graph structure overlaps with the target's, and only weakly by surface or topical similarity. The structural overlap predictor will also beat gradient-alignment measures computed on static data.

This claim does three jobs at once.

It explains the "Math Paradox." Transferability for General Reasoning (TAC) found that math reinforcement learning gradients point in idiosyncratic directions while table reasoning acts as a transfer hub. BeyondBench found that math-tuned models do worse than their base models on dynamically generated algorithmic tasks. Grade-school and competition math are dominated by short arithmetic chains. Tables and algorithmic puzzles require branching aggregation and state tracking. The structure account predicts exactly this pattern.

It is falsifiable. If the surface effect is as large as the structure effect, the account fails.

It turns a vague notion, "abstract reasoning skill," into a quantity the generator controls, because the true graph is known by construction.

Research Program

The generator. It samples graphs from four structure families. Each family has a tunable depth, so performance cliffs can be located.

  • Linear arithmetic chains, matching the template-style computation that AbstRaL and GSM-Symbolic study.
  • Branching aggregation graphs, where several intermediate results merge, in the style of DyVal's directed acyclic graphs.
  • State-tracking sequences, where an object is repeatedly updated, as in BeyondBench's Tower of Hanoi.
  • Small constraint-satisfaction instances.

The renderers. Each graph is rendered into the four skins using template banks with randomized entities, names, and numbers. Distractor clauses are inserted at a controlled rate, following GSM-NoOp in GSM-Symbolic. Answers are checked by executing the graph. Every evaluation instance is generated after the model's training cutoff from a space far too large to have leaked. This follows the same logic as DyVal and BeyondBench, but adds the surface-structure crossing that neither has.

The prior work this builds on, and how it differs.

  • DyVal supplies the graph-generation method. It showed that fine-tuning on its graphs helps GSM8K, SVAMP and FOLIO, but measured that transfer on static, possibly contaminated sets, and never held structure fixed while changing the skin.
  • SALA and SKILL-KNN motivate the structure-versus-surface split. SALA aligns LLM-induced operation sequences. SKILL-KNN retrieves examples via LLM-written skill descriptions. Both work at the level of choosing demonstrations, not training. Both infer structure with an LLM, whereas our generator knows it exactly, so we can check how well their inferred structure tracks the truth.
  • AbstRaL shows that rewarding symbolic abstraction buys robustness to surface perturbation. It stays within linear arithmetic templates and tests transfer on static sets.

Two training stages.

In the first stage we run reinforcement learning with group-relative policy optimization (GRPO) on each of the sixteen cells. We use small models from two families: Qwen2.5-1.5B and Llama-3.2-3B. Two families matter because the Qwen2.5 family is documented as contaminated on math. We then fill the transfer matrix and fit gain as the sum of a structure-overlap term and a surface-overlap term. Structure overlap is computed from shared operator types and dependency patterns in the true graphs. Surface overlap is computed from embedding similarity of the rendered text.

In the second stage we take real checkpoints, trained on static data, and project them onto the grid. These are a math-RL model trained on GSM8K/MATH in the style of CPL and Reasoning Vectors, and table- and logic-trained models built from GURU domains. For each checkpoint we read off which structure cells it improves. We then test whether that profile predicts its gains on BeyondBench tasks and on post-cutoff LiveCodeBench problems. BeyondBench tasks map by hand onto our structure families, since their generators are known.

Finally, we use the predictor to choose training mixtures that maximize structural coverage of a target. This tests whether the measurement is useful, not just descriptive.

Baselines

Base model. The naive reference point is the base model with no further training, evaluated on every grid cell, on the BeyondBench Easy, Medium and Hard suites, and on post-cutoff LiveCodeBench. Any claimed transfer has to clear this. BeyondBench reports a 30–35% ceiling for most open models on its Hard suite, so it is a low but nontrivial floor.

Standard math reinforcement learning. The obvious competitor on the transfer question is GRPO on GSM8K and MATH. This is the source setting behind the strongest published transfer claims. CPL reports +12.2% on HumanEval and +8.6% on GPQA from math-only training of DeepSeekMath-7B. Reasoning Vectors reports +12.3% on BigBenchHard for Qwen2.5-1.5B. We rerun this setting at matched rollout budget. We report it on static targets and on fresh targets side by side. We also run the partial-prompt completion audit from Reasoning or Memorization?, which found 65.8% exact match on MATH-500 for Qwen2.5 given an 80% prefix. This lets us say how much of the static gain survives contamination control.

TAC as a transfer predictor. The strongest existing competitor for predicting and exploiting transfer is TAC's gradient-alignment transferability score and the curriculum built on it. TAC reports +1.8 percentage points of macro-averaged accuracy over the strongest baseline on Qwen3-1.7B across 14 held-out benchmarks, and +9.8 points on Zebra puzzles over random sampling. We compute TAC's random-projection gradient cosines on the same grid and the same real checkpoints. As a predictor, it is compared to ours by held-out variance explained in fresh-benchmark gains. As a curriculum, it is compared to our structure-coverage mixture under identical data pools, rollout counts, and hyperparameter search budgets. Our method beats it if the structure-coverage mixture exceeds TAC's macro-average on fresh BeyondBench and post-cutoff LiveCodeBench by more than seed variance, measured over at least three seeds.

Two further predictor baselines. A surface-similarity predictor uses embedding similarity between source and target text. An inferred-structure predictor uses SALA-style LLM-induced operation sequences compared by dynamic time warping. The second tells us whether cheap inferred structure is good enough to replace true graphs on real benchmarks, where true graphs are unavailable.

Key-ingredient ablation. We train on mixtures that are matched for size and difficulty but vary in kind of diversity. One is surface-diverse but structure-narrow: one structure family in many skins. The other is structure-diverse but surface-narrow: many families in one skin. If structure is the operative ingredient, the second should transfer further on fresh targets.

Why not just…?

Why not just re-run CPL and Reasoning Vectors on BeyondBench and LiveCodeBench? This audit is cheap, and we include it as the first stage. But it only says whether transfer survives, not what carries it. A null result could mean the reasoning skill is fake, or that the skill is real but structurally mismatched to the target. The crossed grid separates these two explanations. The audit alone cannot.

Why not just use TAC's gradient cosine as the measure of transfer? This is the real threat. TAC already predicts transfer well enough to improve curricula. Our concern is that gradients computed on static data can align because two domains share memorized content, not shared computation. Whether that concern is real is an empirical question. The head-to-head prediction test on fresh benchmarks settles it. If gradient cosine explains as much variance as structural overlap, we will report that it suffices. The remaining contribution is then an explanation of why it works.

Why not just train on DyVal-style graphs and check static benchmarks, as DyVal did? DyVal's reported transfer was measured on GSM8K, SVAMP and FOLIO, which can be contaminated. No reported result found on Lacuna for the size of DyVal's fine-tuning gains. Its training also never held structure fixed while changing surface, so it cannot attribute its gains to structure.

Why not just infer structure with an LLM, as SALA or SKILL-KNN do, and skip the generator? For real benchmarks we eventually must. But inferred structure is only trustworthy once it is validated against ground truth, and only a generator with known graphs provides that. The inferred-structure baseline above measures exactly how much is lost by inferring.

Proposed Experiments and Decisive Checks

Check 1: structure versus surface. In the two-way fit of the stage-one transfer matrix, the structure term should explain substantially more variance than the surface term in both model families. The claim is falsified if the surface term is comparable in size. Running Llama-3.2-3B alongside Qwen2.5-1.5B guards against the result being an artifact of Qwen's documented contamination.

Check 2: the Math Paradox. Math-RL checkpoints should improve mainly the linear-chain cells. They should improve the state-tracking and branching cells little, and those cells are where BeyondBench's Hard tasks sit. Table-trained checkpoints should show broader coverage. If math checkpoints instead improve all structure families equally on fresh data, the structure explanation of the Math Paradox is wrong.

Check 3: contamination. For each real checkpoint, the gap between its static-benchmark gain and its fresh-benchmark gain should be larger when partial-prompt completion rates on the source data are high. That would show measured transfer includes a memorization component, which the grid removes.

Check 4: does the predictor help training? The structure-coverage training mixture should match or beat TAC on fresh targets at equal compute. If it does not, structure is still a valid lens for explaining transfer, but it is not a better lever for producing it, and we will say so.