Zero-Search Reinforcement Learning for Slay the Spire 2 with Failure-Driven Restarts

Xiangqin Chen, Zhengxuan XiearXiv 2026

This paper presents a novel approach to training reinforcement learning (RL) agents for the complex deck-building roguelike Slay the Spire 2 (STS2). The authors demonstrate that a relatively small model can achieve competitive performance at high difficulty levels without using any lookahead or tree search during gameplay, provided it is trained with a specialized "failure-driven" curriculum.

TL;DR

The authors develop a 6.6M-parameter "entity transformer" that plays Slay the Spire 2 with zero-search inference, achieving a 15.6% win rate on the highest difficulty (A10) for the Ironclad character. Their core innovation is a failure-driven restart curriculum that uses a headless game host to force the agent to practice specifically in the late-game scenarios where it most frequently loses.

What Problem Does This Paper Address?

Reinforcement learning in games like STS2 faces two major hurdles: long horizons and sparse rewards. A single winning run requires hundreds of decisions, but the most critical "make-or-break" moments often occur in late-game boss fights.

Standard RL agents spend the vast majority of their training time in the early game (Act 1), which is relatively easy. Consequently, they rarely reach the late-game "bottlenecks" (Act 3 bosses) often enough to learn how to beat them. Furthermore, many late-game losses are actually caused by poor deck-building choices made much earlier, creating a difficult credit-assignment problem.

Methods

The researchers built a custom training infrastructure and a novel curriculum:

  • Headless .NET Host: Instead of a reimplementation, they run the actual game assembly (v0.107.1) in a headless environment. This ensures 100% behavioral fidelity and allows for exact state reproduction using game seeds and action prefixes.
  • Entity Transformer: The agent uses a 6.6M-parameter transformer (Figure 1) that treats game objects—cards, relics, enemies, and orbs—as typed tokens. This allows the model to handle the variable number of entities present in any game state.
  • Failure-Driven Restart Curriculum: This is the paper's key contribution. The system maintains a "failure map" that tracks where runs are lost. It then uses the headless host's replay capability to restart training episodes directly from these high-failure situations (e.g., starting Act 3 or a specific boss fight) in proportion to their difficulty.
  • Zero-Search Inference: Unlike previous state-of-the-art agents that use Monte Carlo Tree Search (MCTS) to simulate thousands of moves before acting, this agent makes every decision with a single forward pass of the network (taking only ~25ms).
Figure 1: Policy and value network (6,568,453 parameters). Typed entity tokens and eight learned memory tokens pass through six pre-norm transformer blocks; the front block shows their layers. The value trunk reads a state summary of the encoder outputs. The same MLP scores every legal action from its own features, the encoder outputs of the entities it points to (dashed) and the state summary.

Datasets

  • Held-out Canonical Seeds: Evaluation was performed on 12,800 games across five characters at Ascension 10 (A10), using a fixed set of random seeds to ensure reproducibility.
  • Cross-Agent Benchmark: The authors established a common panel of 512 seeds to compare their agent against AlphaSpire, Spire Mentor, and frontier LLMs.

Key Insights and Ideas

  • Exact Replay as a Training Tool: By leveraging the game's own code for a headless host, the authors turned a "black box" game into a perfectly reproducible environment where they could "save-scum" for the sake of training efficiency.
  • The "Bottleneck" Hypothesis: The study confirms that late-game bosses are the primary barrier to high win rates. Interestingly, they found that for many losses, even re-playing the entire last Act with perfect hindsight couldn't save the run, suggesting that the "decisive errors" often happen during early-game deck-building.
  • LLMs Struggle with Tactical Depth: Despite their reasoning capabilities, frontier models like GPT-6 Astra failed to win a single game at A10 in this study. This highlights the gap between general reasoning and the precise, long-term resource management required by STS2.

Key Results

The zero-search agent achieved impressive results compared to both search-based agents and other zero-search models:

  • High-Difficulty Performance: At A10, the released policies averaged an 8.05% win rate. The Ironclad reached 15.6%, the highest reported for a zero-search agent (Figure 3).
  • Efficiency: The agent requires only 21–27 ms per decision on a single CPU core, making it orders of magnitude faster than MCTS-based agents like Spire Mentor, which can take minutes per run.
  • Comparison to Search: In a head-to-head test on identical seeds, the zero-search agent (8.2% avg) performed nearly as well as Spire Mentor's search-based approach (8.8% avg) (Figure 5).
  • Curriculum Impact: The failure-driven curriculum provided a consistent boost for the "Regent" character, outperforming uniform restarts by 3.6 percentage points.
Table 1: Released zero-search policies at A10 on 2,560 held-out canonical games per character (three disjoint panels of 512, 1,024 and 1,024 games). Base: the policy before the release continuation, on the same games; Regent and Necrobinder are released unchanged. Bold marks the higher count, arrows the change in win rate; paired exact McNemar p. Intervals are Wilson 95%.
Table 3: STS2 v0.107.1, Ascension 10, all five characters. “Measured” rows are our runs; “reported” rows are taken from the cited sources, with their own protocols and seed panels.

Limitations and Future Work

  • Combat Gap: The authors note that their agent's primary weakness compared to search-based agents is tactical combat sequencing in the final boss fights. They suggest that distilling search into the policy (using MCTS to generate training targets) could close this gap.
  • Character Variance: The failure-driven curriculum was highly effective for some characters (Regent) but showed negligible effects for others (Silent), suggesting the "failure map" heuristic may need refinement for different playstyles.
  • Credit Assignment: While restarts help with late-game practice, they don't fully solve the problem of identifying which Act 1 card pick caused an Act 3 loss. Future work could explore more sophisticated attribution methods.

Summary updated

Abstract

Slay the Spire 2 (STS2) is a deck-building roguelike in which a winning run at the highest difficulty takes several hundred decisions, and most losses happen in late boss fights that a learner seldom reaches. We train agents that choose every action with one forward pass of a 6.6M-parameter entity transformer, without lookahead. Training and evaluation run the game's own compiled assembly (v0.107.1) in a headless .NET host. The host replays a run exactly from its seed and actions, so training episodes can restart from states the learner has visited, and a failure-driven curriculum allocates these restarts in proportion to where complete runs are lost. On 12,800 held-out games at Ascension 10 (A10), the released policies win 8.05% averaged over the five characters (Ironclad 15.6%, Regent 12.5%), and AlphaSpire's released networks used without search win 0.55% on a common panel. Longer A10 training raised Ironclad from 12.4% to 15.6% and Defect from 3.0% to 8.1% on these games. At Ascension 0 the released policies win 80.2%, level with the 80.3% that the tree-search agent Spire Mentor reports, while Mentor leads by 5 to 8 points from A4 upward. Run in our host on the same 2,000 A10 games, Mentor's search wins 8.8% against 8.2% for our policies, which need 21-27 ms per decision on one CPU core. GPT-6 Astra at maximum reasoning won none of 11 A10 games through our text interface. In a controlled study of 18 training runs from six random initializations, failure-driven allocation exceeds uniform restart allocation on each of three Regent initializations, by 3.6 percentage points on average, while the Silent effect is small and changes sign. Code, trained policies, an in-game mod and the records behind every table are at https://github.com/HalfVulpes/sts2ai.
BibTeX
@misc{chen2026zero,
  author = {Xiangqin Chen and Zhengxuan Xie},
  title = {{Zero-Search Reinforcement Learning for Slay the Spire 2 with Failure-Driven Restarts}},
  year = {2026},
  eprint = {2611.12088},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.12088},
}
Figure