To train an AI that fixes software bugs, you need many examples of the repair process. Collecting each example separately quickly becomes repetitive because new examples often repeat steps from earlier ones. This wastes effort and limits the data's value.
SWE-Trail uses memory of earlier attempts to decide where to focus when generating new examples. It keeps that memory hidden from the AI, so the AI must rely only on its own knowledge. At important moments, the system briefly tries several next steps from the same state and picks the one with stronger evidence.
On code repair benchmarks, the best AI trained on SWE-Trail's examples solved 2.33 and 1.60 percentage points more issues than one trained on independently collected examples. This shows that using prior attempts to guide collection, without letting the AI see them, produces better training material.
