Terminal-RSI trains a 27B terminal agent with recursive self-rewrite and policy-refine

Terminal-RSI trains a 27B terminal agent with recursive self-rewrite and policy-refine

A paper listed on Hugging Face Papers (2610.22192) proposes Terminal-RSI, a training method for terminal agents. The authors start from the problem of turning verifier outcomes into useful policy updates, and partial progress into complete task resolution.

The method alternates two phases. Recursive Self-Rewrite (RSR) works on verified trajectories. Recursive Policy-Refine (RPR) is a policy refinement phase that inherits the critic from the previous stage. The full sequence has five stages: the Qwen3.8-27B base model, then RSR-1, RPR-1, RSR-2 and RPR-2. The end result is Terminal-RSI-27B.

Several components support the loop. Turn-Boundary Skip-Observation GAE (TB-GAE) is meant to retain token-specific baselines while applying decay across interaction turns. Family Dense Reward (FDR) calibrates semantic progress across task families. Success-Prioritized Reward (SPR) separates strict success from bounded partial credit. A Warm-up Critic Model, recursive critic handoff and stage-specific learning rates coordinate the two refinement phases.

The abstract reports these scores for Terminal-RSI-27B: 19.84% on Terminal-Bench 4.0, 86.52% on Terminal-Bench 2.1, 16.95% on Terminal-Bench 3.0 and 79.00% on Terminal-Bench Hard. It also gives before and after figures on two other benchmarks. On LHTB, process reward rises from 0.21 to 0.37, and strict completion goes from 0/46 to 5/46 tasks. On SWR100, success doubles from 3.00% to 6.00%.

The authors' summary claim is that, by coupling verified trajectory rewriting with critic-inheriting policy refinement, each retained stage consolidates discovered behaviors and progressively moves the agent from partial local repairs to strict terminal verification.

Key facts

  • Terminal-RSI alternates Recursive Self-Rewrite (RSR) of verified trajectories with critic-inheriting Recursive Policy-Refine (RPR).
  • A five-stage sequence (Qwen3.8-27B base, RSR-1, RPR-1, RSR-2, RPR-2) yields Terminal-RSI-27B.
  • Reported scores: 19.84% on Terminal-Bench 4.0, 86.52% on 2.1, 16.95% on 3.0 and 79.00% on Terminal-Bench Hard.
  • On LHTB, process reward rises from 0.21 to 0.37 and strict completion from 0/46 to 5/46 tasks.
  • On SWR100, success doubles from 3.00% to 6.00%.

Why it matters

Terminal agents often make partial progress without fully resolving a task. This paper targets that gap directly: its reward design (SPR) separates strict success from bounded partial credit, and its training loop is built to move an agent from partial local repairs toward strict terminal verification. The reported LHTB result shows the scale of the starting point: strict completion of 5/46 tasks after the pipeline, up from 0/46.

Who it affects

The work is aimed at researchers and engineers training agents that act in a terminal, especially those using reinforcement-learning style updates with verifiers. The base model is Qwen3.8-27B, so the setup concerns a 27B-parameter base model.

How to use it

The abstract describes a recipe, not a product: a warm-up critic, alternating RSR and RPR stages with the critic handed from one stage to the next, stage-specific learning rates, and the TB-GAE, FDR and SPR components. No release of code, weights or data is mentioned, so a reader cannot yet reproduce or download Terminal-RSI-27B from what is given.

How solid is it

This is a preprint listed on Hugging Face Papers. The abstract names no authors or institutions. No baseline scores are given for the Terminal-Bench variants, so the size of any improvement there cannot be stated. The abstract does not say what the percentages on Terminal-Bench 4.0, 2.1, 3.0 and Hard measure. LHTB and SWR100 are not expanded or described, and it is not stated which model produced the before values on LHTB (0.21, 0/46) and SWR100 (3.00%). No comparison with other agents or models is given.

Risks and caveats

The headline numbers cannot be judged without baselines or metric definitions, and the benchmark scores are not comparable with each other since the versions differ. The SWR100 gain is a doubling, but from a low 3.00% to 6.00%, and LHTB strict completion is 5 of 46 tasks. No compute cost, training duration or dataset size is given, and the claim that each stage progressively improves the agent is the authors' own characterization.

“each retained stage consolidates discovered behaviors and progressively advances the agent from partial local repairs to strict terminal verification”

— Terminal-RSI paper abstract