SWE-Prime: Fewer Trajectories, Better Performance
SWE-Prime finds that filtering coding-agent traces by process and segment quality can beat training on every resolved trajectory, reducing noisy imitation from redundant or risky steps.
SWE-Prime filters successful coding-agent traces in **two stages**: whole trajectories are screened for process quality, result quality, and representativeness, then semantic segments are judged for contribution, learnability, and risk. Only selected segments contribute to the training loss.
The reported **10% trajectory subset** beat training on the full resolved dataset, with relative gains up to **12.2% on SWE-Bench Pro** and **24.2% on SWE-Bench Verified**. Teams training coding models should evaluate how an issue was solved, not treat a passing outcome as clean supervision.
SWE-Prime filters successful coding-agent traces in **two stages**: whole trajectories are screened for process quality, result quality, and representativeness, then semantic segments are judged for contribution, learnability, and risk. Only selected segments contribute to the training loss. The reported **10% trajectory subset** beat training on the full resolved dataset, with relative gains up to **12.2% on SWE-Bench Pro** and **24.2% on SWE-Bench Verified**. Teams training coding models should evaluate how an issue was solved, not treat a passing outcome as clean supervision. All segments remain in the input sequence to preserve context, so this is selective loss computation rather than simply deleting weak steps. The material reports benchmark results but does not establish whether the selection criteria transfer to other repositories, agents, or training setups.
SWE-Prime shows that successful coding traces are not uniformly valuable supervision: filtering trajectories and masking low-value segments can outperform learning from every resolved example. This strengthens trajectory-quality arguments with benchmark results and adds a concrete implementation distinction—retain the full trace as context while applying loss only to selected segments. It does not resolve whether the underlying tasks or harnesses are valid.