Whodunit

Something broke. git bisect is about to guess. Whodunit reads the crime scene first.

Inspiration

I've done this too many times. A bug shows up, you run git bisect, you wait through seven test runs, and if the suite flakes once it can still point at an innocent commit. The commit that looks guilty is usually the feature, not the bug. I wanted a bisect that actually reads the diffs first.

What it does

You type one sentence (finance says a credit note CSV is a cent off) and Whodunit searches git history, writes a test, and finds the culprit.

The demo is 108 commits. The test suite is green. The killer isn't the credit-note feature. It's a "harmless" refactor that swapped Math.floor for Math.trunc, so negative money rounds the wrong way. One cent. Classic bisect needs about 6 probes. This closes in 3.

Turn on a flaky test and vanilla bisect derails. Whodunit still stamps the same commit (4c58cb3). Then Gemini can restore Math.floor and push the fix.

How we built it

I built this solo (my teammate ditched me :( ). Elasticsearch 9 on Elastic Cloud for the case file: commits, diffs, CI logs, issues. Hybrid search (BM25 + Gemini vectors + RRF) and ES|QL. The agent's tools are real queries, not a chatbot wrapper.

Gemini runs three specialists: investigate, reproduce, fix. If quota dies mid-demo it falls back to another Flash model.

The bisect is Bayesian. It probes where the evidence points, and treats a flake as noise, not a verdict. The UI is a React interrogation room. If Wi-Fi dies, the simulated demo still plays the same 108-commit crime scene.

Challenges we ran into

Search loves the wrong commit. The credit-note feature and the tax-rounding "fix" both mention the bug. The real one says "no behaviour change." Without a test, rank is a vibe.

Live Gemini also 429'd in the middle of a run, so I had to build fallbacks and a simulated cinematic that doesn't need the API.

Elastic Cloud Serverless also rejected shard settings that work fine locally. One 400 and nothing indexes.

Accomplishments that we're proud of

You can watch it disagree with git bisect. Grey needle is the midpoint. Red needle is the weighted guess. Flake the test and classic bisect stamps the wrong person. This one doesn't.

The radar shows actual Elasticsearch queries. The newspaper cites the hunk. And the booth still works offline.

What we learned

Don't trust search without a test. Elasticsearch finds suspects. The oracle names the killer.

Three small Gemini jobs beat one giant prompt.

Always start the pitch on the simulated run. Live is the encore.

What's next for Whodunit

Point it at a real repo, not just the 108-commit crime scene. Learn flake rate from the suite instead of a slider. Update the posterior when a commit lands, before anyone files a complaint.

Built With

Share this project:

Updates

Submission history