TL;DR
This paper explores how reinforcement learning (RL) post-training affects a language model's ability to combine individual skills to solve complex problems. By formalizing reasoning as a dependency graph, the authors reveal a striking "decomposed-to-composed asymmetry": training models on isolated sub-skills fails to transfer to complex composed tasks, whereas training on composed tasks successfully generalizes back to simple skills.
What Problem Does This Paper Address?
Reinforcement learning (RL) post-training has dramatically boosted the reasoning performance of Large Language Models (LLMs). However, because training data is always limited, models must be able to perform compositional reasoning—recombining known primitive skills to solve novel, more complex problems.
A critical data-design question arises: Is it better to train models on isolated, easily verifiable sub-skills (decomposed training), or on full, multi-step problems (composed training)? While intuitive to think that mastering individual building blocks is enough, this paper investigates why models trained purely on isolated skills fail when those skills are chained together.
Methods
The authors introduce a formal dependency-graph framework to characterize compositional reasoning. Tasks are represented as Directed Acyclic Graphs (DAGs), where nodes represent a specific skill invocation and edges represent data dependencies between them.
Using this framework, they define three hierarchical levels of compositionality:
- Level I: Single-Skill Chain: One skill repeated along a single path (tests horizon generalization).
- Level II: Multi-Skill Chain: Different skills mixed along a single path (tests skill switching).
- Level III: Branch-Merge Graph: A non-linear dependency graph where multiple branches must be executed and merged (tests non-local dependencies).
For post-training, the authors use Group Relative Policy Optimization (GRPO) with binary outcome rewards based on programmatic correctness. They contrast two main training strategies:
- RL-Atomic: Trained exclusively on single-step, decomposed skills.
- RL-Compound: Trained on multi-step, composed tasks.
They also compare RL performance against Supervised Fine-Tuning (SFT) to evaluate out-of-distribution length generalization.
Datasets
The framework is instantiated using deterministic, programmatically verifiable tasks:
- DSR-Bench: A benchmark for structural reasoning in LMs, utilizing data structures like Arrays, Binary Search Trees (BST), Bloom Filters, Hashmaps, and Heaps.
- Segment-Tree Construction: A custom task designed to evaluate non-linear Level III compositionality.
- Berkeley Function Calling Leaderboard (BFCL): Used as a real-world pilot study to evaluate tool-calling capabilities across single (
simple_python) and multi-call (parallel,parallel_multiple) splits.
Key Insights and Ideas
- The Decomposed-to-Composed Asymmetry: Learning skills in isolation is insufficient for composition.
RL-Compoundexposes the model to both the skills and their transitions, allowing it to maintain intermediate states effectively. - Error Compounding and Coverage Shift: Mathematically, the authors prove that composed rollouts induce a distribution of states (contexts) that atomic training never covers. In a long reasoning chain, a single early mistake cascades, leading to catastrophic failure on compound tasks.
- Linear vs. Non-Linear Bottlenecks: Non-linear compositions (Level III) introduce a severe bottleneck. At merge points, models cannot simply propagate the immediate preceding state; they must retrieve and coordinate non-local dependencies from separate branches.
- SFT Memorizes, RL Generalizes: SFT performs exceptionally well on in-distribution problem lengths but degrades sharply when evaluating longer sequences. RL post-training demonstrates significantly better length extrapolation.
Key Results
- Performance Gap: Across all three levels of compositionality,
RL-Compoundsignificantly outperformedRL-Atomicon compound tasks. In Level III tasks,RL-Atomiccollapsed to near-zero accuracy as problem length scaled, whileRL-Compoundmaintained robust performance.
- No Skill Degradation: Training on composed tasks (
RL-Compound) does not hurt basic skill execution; it preserves or even improves performance on atomic tasks. - Tool-Use Validation: The pilot study on the BFCL tool-calling benchmark confirmed that the decomposed-to-composed asymmetry holds true in practical, real-world agent scenarios.
Limitations and Future Work
- Final-Output Scoring: The study relies entirely on final-answer verification. While intermediate-state verification could provide a denser reward signal, the authors found that forcing structured intermediate outputs (like JSON) actually increased formatting burdens and reduced overall accuracy.
- Domain Specificity: The empirical evaluation focuses primarily on deterministic data-structure algorithms.
- Future Directions: The authors suggest exploring LLM-based judging to track and evaluate intermediate reasoning traces flexibly without constraining the model's generation format. Testing this data-design principle on broader real-world benchmarks remains an open avenue.
Summary updated