SWE-smith: Scaling Data for Software Engineering Agents

John Yang, Kilian Adriano Lieret, Carlos E. Jimenez, Alexander Wettig, K. Khandpur, Yanzhe Zhang, Binyuan Hui, Ofir Press, Ludwig Schmidt, Diyi Yang

arXiv:2504.21798 · 2026-07-27 공개 · arXiv · PDF

language-models swe-bench software-engineering open-source dataset-generation github-repositories swe-smith automated-software-engineering

Abstract

Despite recent progress in Language Models (LMs) for software engineering, collecting training data remains a significant pain point. Existing datasets are small, with at most 1,000s of training instances from 11 or fewer GitHub repositories. The procedures to curate such datasets are often complex, necessitating hundreds of hours of human labor; companion execution environments also take up several terabytes of storage, severely limiting their scalability and usability. To address this pain point, we introduce SWE-smith, a novel pipeline for generating software engineering training data at scale. Given any Python codebase, SWE-smith constructs a corresponding execution environment, then automatically synthesizes 100s to 1,000s of task instances that break existing test(s) in the codebase. Using SWE-smith, we create a dataset of 50k instances sourced from 128 GitHub repositories, an order of magnitude larger than all previous works. We train SWE-agent-LM-32B, achieving 40.2% Pass@1 resolve rate on the SWE-bench Verified benchmark, state of the art among open source models. We open source SWE-smith (collection procedure, task instances, trajectories, models) to lower the barrier of entry for research in LM systems for automated software engineering. All assets available at https://swesmith.com.

한국어 요약

한 줄 요약

SWE-smith는 소프트웨어 엔지니어링 에이전트 학습 데이터를 대규모로 생성하는 파이프라인으로, 128개 리포지토리에서 50,000개의 인스턴스를 생성해 기존 방식 대비 10배 규모 확장.

핵심 기여도

핵심 아이디어

SWE-smith는 기존 학습 데이터 수집 방식에서 요구되는 수동 작업과 저장소 부담을 줄이기 위해, Python 코드베이스를 기반으로 실행 환경을 자동 생성하고, 테스트 실패를 유발하는 버그 인스턴스를 자동으로 합성하는 방식을 제안한다. 핵심 아이디어는 실행 기반 검증을 통해 해결 가능한 버그를 식별하고, 이를 학습 데이터로 활용하는 것이다. 이는 기존 SWE-bench의 인스턴스 수집 전략을 확장하면서도, PR 필터링과 수동 작업을 최소화하는 것이 핵심이다. SWE-smith는 LM을 활용한 함수 재작성, AST 수정, PR 복구, 버그 병합 등 4가지 기술을 결합해 인스턴스를 생성한다.

기술적 접근법

주요 결과

의의 및 한계

SWE-smith는 소프트웨어 엔지니어링 에이전트 학습 데이터 생성의 주요 장벽인 수동 작업과 저장소 부담을 해결하며, 대규모 오픈소스 데이터셋을 생성할 수 있는 기반을 제공한다. 특히, 실행 기반 검증을 통해 생성된 인스턴스는 실제 문제 해결 능력을 평가할 수 있어, 기존 텍스트 기반 학습 데이터와 차별화된다. 그러나 SWE-smith는 Python 코드베이스에만 적용되며, 다른 언어나 복잡한 시스템에 대한 확장성은 명시되지 않았다. 또한, 생성된 인스턴스 중 일부는 반복적인 행동이나 로컬라이제이션 실패로 인해 해결되지 않으며, 이는 모델의 추론 능력을 제한하는 요인으로 작용할 수 있다.

실용적 활용

SWE-smith는 오픈소스 소프트웨어 엔지니어링 에이전트 연구를 촉진할 수 있는 도구로, 대규모 학습 데이터셋을 저비용으로 생성할 수 있다. 특히, 소프트웨어 자동화, 코드 생성, 버그 수정 등에 활용 가능하며, 연구자와 개발자들이 LM 기반 에이전트를 개선하는 데 기여할 수 있다. SWE-smith는 GitHub 리포지토리 기반의 코드베이스를 대상으로 하기 때문에, 오픈소스 프로젝트 개발자들이 모델 학습과 평가에 활용할 수 있다.