SWE Lab
Tooling to build, run, enrich, audit and fix SWE (a.k.a. coding agent) evaluation data.
What's in it
-
The run engine (
src/swe_lab/sandbox/,workflow/) — one sandboxed run of a coding agent over a benchmark instance, composed from three plug-in axes: a harness (claude_code,codex,grok_build), a dataset (SWE-Bench Pro, DeepSWE 1.1) and an eval method (unit-test grading). A workflow chains those steps — solve, grade, or both — and is run by name:python -m swe_lab run --list # what can be run python -m swe_lab run rollout_and_unit_test <instance_id> # solve, then grade
-
Benchmark integrity (
src/swe_lab/git/,integrity/) — the task repo's future is stripped out of the container before the agent starts (and the strip is proved), and each run is swept for the ways an agent can reach the answer anyway. Detection, never a gate — ADR-0010. -
Related-files annotation (
src/swe_lab/pipelines/related_files/) — for each task instance, a ground-truth list of the code snippets a model needs to read to solve it. Shipped: 731/731 SWE-Bench Pro instances annotated & QA'd. -
Quality auditing (planned) — flag "skewed" eval examples that no longer measure real capability (ambiguous specs vs. overly-specific tests, broken environments, contamination, brittle graders), in the spirit of OpenAI's Separating signal from noise in coding evaluations. Not started; the nearest shipped work is the benchmark-integrity detection above.
The overall roadmap and status live in docs/README.md; the
codebase map, commands and hazards in
docs/conventions.md.
Setup
Prerequisites
- uv for environment and dependency management
- direnv for auto-activating the environment
- Python 3.13 (uv will install it automatically if missing)
1. Clone
git clone https://github.com/Luolc/swe-lab.git
cd swe-lab
Optional — the --capture proxy mode compiles the standalone
cc-reverse-proxy Go project. It is
not a submodule: by default it is looked up as a sibling checkout next to
this repo (../cc-reverse-proxy/reverse_proxy.go); clone it there, or point
CC_REVERSE_PROXY_SRC at its reverse_proxy.go. The default stream capture
needs none of this.
2. Set up the environment
uv sync # create .venv and install all (incl. dev) dependencies
direnv allow # auto-activate the venv on cd (uses .envrc)
If you don't use direnv, activate manually with source .venv/bin/activate.
Install the pre-commit hooks (the full set is listed in
docs/conventions.md):
uv run pre-commit install
3. Download the datasets
Dataset data files are gitignored and must be downloaded locally. See
datasets/README.md for the list of available datasets
and per-dataset download instructions.
Disclaimer
This is a personal project and is not affiliated with any company. The content does not reflect any specific company's projects, products or internal work.
Metadata
Release files for swe-lab 0.3.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| swe_lab-0.3.7.tar.gz | 1.2 MB | With provenance | Details for swe_lab-0.3.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| swe_lab-0.3.7-py3-none-any.whl | Python 3 | none | any | Details for swe_lab-0.3.7-py3-none-any.whl |
Total release size: 2.5 MB
Release files / swe_lab-0.3.7.tar.gz
| Download URL | swe_lab-0.3.7.tar.gz |
|---|---|
| Size | 1.2 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f646d35c328b2b2b32b6c9d672285686eff053a03024e115a49b670632a42b64
|
|
BLAKE2b-256 checksum How to use checksums |
e9a4dd062d13a625501c6678a7bab040a5bc4c9c397329f36a61433295bd4530
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.
Transparency logRelease files / swe_lab-0.3.7-py3-none-any.whl
| Download URL | swe_lab-0.3.7-py3-none-any.whl |
|---|---|
| Size | 1.3 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
376c7fcf9e1bf83996d2ab8a2b8ec15e9471dec9b7973e3ffd97f4c4a7f41cf5
|
|
BLAKE2b-256 checksum How to use checksums |
8a80a06479755afc43de42ceb4b0e71a39d278db87137cf607296bb9c95203e2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.
Transparency logSecurity for swe-lab 0.3.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for swe_lab-0.3.7.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 8, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.