Scaling Trajectories for Complex Tasks through Recursive Self-Rewrite
Recursive Self-Rewrite converts harness-assisted trajectories into general training data, lifting Qwen-3.8-27B Terminal-Bench 2 pass@3 from 57.0% to 74.2%.
RSR uses one base model, Qwen-3.8-27B, with a planner, critic, and executor to reconstruct solutions found under specialized harnesses into trajectories under a general harness. From 2,001 successful source trajectories it derives 11,094 rewritten trajectories for supervised finetuning. Training on these improves pass@3 from 57.0% to 74.2% on Terminal-Bench 2, from 1.5% to 9.1% on Terminal-Bench 4, and from 39.0% to 63.0% on Terminal-Bench Hard, beating both base model and direct trajectory SFT.
- Planner-critic-executor pipeline detects verifier and solution leakage before rewriting
- 2,001 source trajectories expanded into 11,094 rewritten training trajectories
- Terminal-Bench 2 pass@3 rises 57.0% to 74.2% over base model
- Three harnesses jointly solve 759 of ~3K tasks, 34.3% more than best single harness
- Tags
- agent-trainingterminal-benchsupervised-finetuningself-improvementagentic-taskstrajectory-learning
- AI models
- Qwen-3.8-27B
From the original article
1 min read at huggingface.coSuccessful trajectories on difficult tasks provide valuable supervision for model improvement, but specialized harnesses introduce interventions that may be unavailable during deployment. We propose Recursive Self-Rewrite (RSR), a framework that uses one base model, Qwen-3. 8-27B, to discover successful solutions under diverse harnesses and reconstruct them as training trajectories under a general harness.
By Zongxia Li, Yucheng Shi, Zhongzhi Li · huggingface.co
A short excerpt; the article and its images belong to the publisher. Summary, key facts and assessment above are AI-written from the article and can be wrong.