swebench
The official SWE-bench package - a benchmark for evaluating LMs on software engineering
Decision gist · record as of 2026-08-14
Yes, if you are a researcher or engineer evaluating language models on code generation and bug fixing. The benchmark is well-maintained, actively used by the community, and provides reproducible evaluation infrastructure. Install only if you have or can access Docker and sufficient compute resources; the package itself installs easily, but meaningful evaluation requires significant system resources and setup.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Docker must be installed and running.
- Evaluation requires at least 120GB free storage, 16GB RAM, and 8 CPU cores; ARM-based systems (MacOS M-series) require additional setup with --namespace '' flag.
- Low friction installation with a pure-Python wheel.
License · maintenance · safety
permissive license (permissive) — MIT License permits unrestricted use, modification, and distribution with minimal restrictions, making it suitable for both research and commercial applications.
last release 2025-09-11 (337 days) · last repo commit 2026-08-14 · 5,633 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 29,298,212 downloads/mo, #821 on PyPI
Alternatives
Verify before relying
pip install swebench
from datasets import load_dataset
swebench = load_dataset('princeton-nlp/SWE-bench', split='test')
python -m swebench.harness.run_evaluation \
--dataset_name princeton-nlp/SWE-bench_Lite \
--predictions_path <path_to_predictions> \
--max_workers 4 \
--run_id my_eval- Whether the package's evaluation harness can run on systems with less than the recommended 120GB storage without significant degradation
- Performance characteristics and typical runtime for evaluating a single issue or small batch on standard hardware
What it is and what it does
SWE-bench is a benchmark dataset and evaluation harness for measuring how well language models can solve real software engineering problems. It provides curated GitHub issues paired with their codebases and verified solutions, allowing researchers to test whether LLMs can generate patches that actually resolve the described bugs. The package includes a Docker-based evaluation framework that reproduces the original environment for each issue, ensuring reproducible testing across different models and systems.
The framework handles the full pipeline: loading datasets from Hugging Face, running inference on models to generate patches, and evaluating whether those patches pass the original test suites. It supports local evaluation, cloud-based evaluation via Modal, and integrates with tools like GitPython, docker, and datasets for managing repositories and test execution. The package is designed for researchers benchmarking LLM capabilities on software engineering tasks, not for end-user bug fixing.
Use it for
- Evaluate a language model's ability to resolve real GitHub issues by generating patches and checking if they pass existing tests
- Compare performance of different LLMs on standardized software engineering tasks using SWE-bench Lite or Verified subsets
- Run inference on local or API-based models to generate patch candidates for a curated set of real-world bugs
- Collect and prepare new software engineering benchmark tasks from your own repositories using the data collection procedure
- Run evaluations on cloud infrastructure via Modal to avoid local resource constraints when testing multiple models
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes, if you are a researcher or engineer evaluating language models on code generation and bug fixing.
The benchmark is well-maintained, actively used by the community, and provides reproducible evaluation infrastructure. Install only if you have or can access Docker and sufficient compute resources; the package itself installs easily, but meaningful evaluation requires significant system resources and setup.
Install
swebench on PyPI
Before you install
Low friction installation with a pure-Python wheel. The package is actively maintained with recent commits and a large community (5633 stars). However, evaluation itself requires Docker and substantial system resources (120GB storage, 16GB RAM, 8 CPU cores recommended), which is a runtime constraint rather than an install-time one.
Docker must be installed and running. Evaluation requires at least 120GB free storage, 16GB RAM, and 8 CPU cores; ARM-based systems (MacOS M-series) require additional setup with --namespace '' flag.
License in practice
MIT License permits unrestricted use, modification, and distribution with minimal restrictions, making it suitable for both research and commercial applications.
Quickstart
pip install swebench
from datasets import load_dataset
swebench = load_dataset('princeton-nlp/SWE-bench', split='test')
python -m swebench.harness.run_evaluation \
--dataset_name princeton-nlp/SWE-bench_Lite \
--predictions_path <path_to_predictions> \
--max_workers 4 \
--run_id my_eval
Verify before relying
- Whether the package's evaluation harness can run on systems with less than the recommended 120GB storage without significant degradation
- Performance characteristics and typical runtime for evaluating a single issue or small batch on standard hardware
Package facts
| License | permissive license permissive |
| Python support | Supports the current Python release >=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 14 packagesbeautifulsoup4chardetdatasetsdockerghapiGitPythonmodalpre-commitpython-dotenvrequestsrichtenacitytqdmunidiff |
| Maintenance | Actively maintained 337 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 29,298,212 / month, #821 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | License :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11 |
Evidence: swebench-4.1.0-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “language model code generation benchmark”
- swebenchSWE-bench is a benchmark framework for evaluating language models on…
- mini-swe-agentAn AI agent that solves software engineering tasks by running bash…
- evalplusEvalPlus provides a rigorous evaluation framework for code generated…
Give your agent the search over MCP, or paste the wish link into any chat.
More Artificial Intelligence packages
LiteLLM provides a unified Python interface to call 100+ LLM providers (OpenAI, Anthropic, Gemini, Bedrock, Azure, and others) using OpenAI-compatible API format, available as both a Python SDK and a self-hosted AI Gateway proxy server.
Install it if you need to work with multiple LLM providers or want to centralize LLM routing in your organization.
Client library and CLI tool for downloading, uploading, and managing models, datasets, and repositories on the Hugging Face Hub platform.
Install it if you work with Hugging Face Hub models or datasets.
LangChain provides a framework for building agents and LLM-powered applications by composing language models, tools, and memory through a unified API that abstracts over multiple model providers.
hf-xet provides chunk-based deduplication and efficient file transfer for the Hugging Face Hub, enabling faster uploads and downloads of large files with local disk caching.
Tokenizers converts raw text into token sequences for NLP models, with support for training custom vocabularies and using pre-built tokenizers (BPE, WordPiece) optimized for speed via Rust.
Transformers provides a unified framework for loading, fine-tuning, and running state-of-the-art pretrained models across text, vision, audio, video, and multimodal tasks using PyTorch, JAX, or TensorFlow.
Install it if you need to run or train any transformer-based model for NLP, vision, audio, or multimodal tasks.
See also swesmith · mini-swe-agent · swe-rex · mteb · ms-swift · inspect-swe · terminal-bench · rf100vl · lm-eval · clip-benchmark