Skip to main content

swarmr-blame

Git archaeology team for swarmr. Given a command whose exit code says whether a test passes, finds the commit that first broke it and proves the cause.

Non-mutating to your checkout: every test runs in a git worktree under a scratch directory with a scrubbed environment, and the worktree is removed when the run ends. Nothing about the repository is hardcoded — the team profiles it at startup and injects what it found into every prompt.

Install

Core and this team must land in the same environment.

uv tool install "swarmr[blame]"

That exposes teams and teams-mcp on your PATH; this team ships no command of its own. From a checkout: uv tool install ../swarmr --with ../swarmr-blame.

teams --target repo_forensics --repo /path/to/checkout --test "<command>"
teams repo_forensics --repo /path/to/checkout --test "<command>" --setup "<command>" \
  "the checkout test fails on main since this week"

Over MCP the tool is start_repo_forensics(request, repo, test, setup?).

The oracle

The team does not know what a test is, and does not need to. test is run from the root of a scratch worktree at each commit, the way git bisect run has always asked for one: exit 0 is a pass, anything else is a fail. setup, when given, runs once per worktree and again whenever a lockfile changes between refs. Any language, any runner — a script you write that checks the symptom is a test.

The oracle has five answers, and they are distinct on purpose. pass is exit 0 and fail anything else. absent means a file the command names does not exist at that commit, which is never evidence of breakage. unbuildable means setup failed, the command is not on PATH, or it exited 125 — git bisect run's "cannot judge", which a wrapper script can use to skip a commit. timeout means the run exceeded BLAME_ORACLE_TIMEOUT.

Only commits are tested; an uncommitted edit has no commit to blame and is reported as a dirty working tree. If the command cannot run at all the report says unrunnable, with the tool's own output, instead of inventing a verdict about history. An MCP server inherits the environment of whatever launched it, so the toolchain test needs must be on its PATH.

Arguments

Per call, as --flags on the CLI or arguments of the MCP tool. Nothing about the target comes from the environment: a process serving several callers cannot have one repository.

repo is the checkout to investigate — required, must be the repository root, never modified. test is the command whose exit code is the verdict — required, split with shlex, never a shell. setup is optional and runs once per worktree and after every lockfile change.

Tuning: BLAME_PASS_ENV (comma-separated variables passed through to the commands; credentials under $HOME are otherwise invisible), BLAME_ORACLE_TIMEOUT (seconds per test run, default 120), BLAME_INSTALL_TIMEOUT (seconds per setup run, default 300), BLAME_CACHE_TTL (history reads memoised, default 300; oracle runs are never cached). Model credentials come from swarmr (KIMI_*).

There is no network isolation: a test that reaches the network can. Running the team inside a container is the stronger boundary; this package does not provide one. The report names a location, never a fix.

Design notes and internals: CLAUDE.md.

Metadata

Release files for swarmr-blame 1.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for swarmr-blame 1.0.3
File Size Uploaded
swarmr_blame-1.0.3.tar.gz 81.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for swarmr-blame 1.0.3
File Interpreter ABI Platform
swarmr_blame-1.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 144.9 kB

Release files / swarmr_blame-1.0.3.tar.gz

Download URL swarmr_blame-1.0.3.tar.gz
Size 81.3 kB
Tags Source
SHA-256 checksum
How to use checksums
4f8e5dec0af814ba1ebd85f30b6551bc12ca0f3edddb9a72efc826ad570d602a
BLAKE2b-256 checksum
How to use checksums
c490b489f714d88dc001da10c7aff84b372897bfd80895d07bde6047a763b858
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.23 {"installer":{"name":"uv","version":"0.12.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / swarmr_blame-1.0.3-py3-none-any.whl

Download URL swarmr_blame-1.0.3-py3-none-any.whl
Size 63.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ab1b825b6b7d30e6deb82143f1b165a5c0742c1c9eb944d7129aca78c049fcea
BLAKE2b-256 checksum
How to use checksums
96b1c873d4e0050c88773c51fc570a2472ca8a8f6f2f244e228ea9e75839778d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.23 {"installer":{"name":"uv","version":"0.12.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

This release

1.0.3 This release

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page