Tropical Reinforcement Learning
Organizations: MBZUAI · TUM
Abstract
Reinforcement learning for large language models typically maximizes expected return, adding up the probabilities of all successful trajectories. However, the classical sum formulation can only report how often the model policy succeeds, not which solution actually worked, and because probabilities sum to one, reinforcing one solution can make the model forget another that was never shown to be wrong. This makes expected return a poor fit for compositional reasoning, where a solution must be assembled from reasoning steps that the model produces in separate, often failed, attempts but rarely produces together. To address this, we propose Tropical Reinforcement Learning, which rests on a simple change of algebra: instead of adding the probabilities of alternative solutions, we take their maximum, which yields the tropical semiring. The value of a state then becomes the log-probability of its most likely verified solution, together with an explicit path that can be replayed and reused. This enables true composition, since the best prefix and the best suffix meeting at a shared state can be joined even when they come from different rollouts. To put this into practice, we introduce TROPIC, a training algorithm for deterministic, resettable environments with verifiable outcomes. On four agentic tasks (Sokoban, Countdown, FrozenLake, WebShop), TROPIC outperforms the strongest on-policy baselines by up to 16 percentage points. Changing the algebra of reinforcement learning, not just its estimators, can thus substantially improve compositional reasoning in language models
Figures & tables
| Classical (sum) | Tropical (max) | |
|---|---|---|
| The value measures | how much of the actor already succeeds | how far the actor is from its nearest verified solution (Lem. 5 ) |
| Advantage | relative to the average action, must be estimated | , exactly on the best path, computed by the DP |
| Performance difference | expectation over the new policy’s trajectories | a sum over one path (Thm. 14 ) |
| Gradient weight on a step | visit prob. action prob. completion prob. | on every step of the best path (Cor. 3 ) |
| Rare path of depth | escape takes steps | steps; MaxRL matches this on one path (Thm. 15 ) |
| Training on one path | can lower an unsampled solution (Prop. 1 ) | never lowers any state; shared parts gain in full (Thm. 4 ) |
| Task | Method | Qwen2.5-3B-Instruct | Gemma 4 E4B-it | |||||
|---|---|---|---|---|---|---|---|---|
| Success Rate ( ) | Tokens ( ) | Time (h) ( ) | Success Rate ( ) | Tokens ( ) | Time (h) ( ) | |||
| Sokoban | Base Model | 12.89 | 254 | -- | 45.50 | 205 | -- | |
| PPO | 21.90 2.14 | 231 | 2.70 | 71.68 1.71 | 209 | 8.85 | ||
| GRPO | 27.60 2.47 | 205 | 2.90 | 66.53 2.32 | 254 | 8.20 | ||
| DAPO | 36.55 2.11 | 174 | 2.80 | 72.65 1.35 | 219 | 8.40 | ||
| SNR-Aware | 42.20 1.96 | 201 | 2.10 | 76.55 1.94 | 237 | 8.30 | ||
| Method | Success Rate ( ) | Tokens ( ) | Time (h) ( ) | First-Solve ( ) |
| Base Model | 12.89 | 254 | -- | -- |
| MaxRL | 51.30 2.31 | 202 | 2.53 | -- |
| GiGPO | 47.60 2.18 | 199 | 3.11 | -- |
| GiGPO + T-STAR | 53.10 2.18 | 194 | 3.80 | -- |
| TROPIC (No Comp.) | 40.80 2.26 | 205 | 1.45 | 0.0 |
| TROPIC (Root-Only) | 51.80 2.12 | 196 | 1.92 | 24.7 3.2 |
Appendix figures & tables2 assets
Supplementary material from the paper’s appendix.
Appendix
| Hyperparameter | Description | Value |
| Attempt groups per problem/iteration | ||
| Attempts per group | ||
| Frontier exploration weight | ||
| -- | Training-rollout temperature | |
| Prefixes and suffixes per shared state | each | |
| -- | Composition candidates per problem/refresh |
Reinforcement Learning
Reinforcement learning studies how agents learn sequential decisions from rewards and interaction, balancing exploration, performance, safety, and adaptation.
See all 1,742 papers