Repository navigation
feat: prove corpus labels from anchored marks - #46
Merged
Merged
Conversation
A label came from AI tool names found anywhere in a commit, so a person's commit that only mentioned a tool counted as the tool's. A suggestion that a person committed, or a squash of many commits, counted as an agent's too. And a shallow clone made old files look as if they began in 2018. Marks are now a table of the strings each agent writes itself, each with a kind and a real commit that carries it. A mark is matched only where the tool writes it: the author, the committer, a co-author, a trailer or a known footer. An assist never counts and a squash never proves. A history that a shallow clone cut says so, and a commit is before the cutoff only by both its author and its committer date. collect.py gains recheck, which clones each repository of the big tier and derives every live label again under these rules, and pack --exclude, which writes the labels that fail into a new batch. A batch may hold only exclusions, and a test covers that.
GitHub ends a squash-merge's subject in "(#N)", and its message may look like one commit's. So an agent's mark on it hid the person's commits of the pull request, and git could not tell. A marked commit with such a subject now proves its marks only when every commit of pull request N carries a mark that counts. recheck and describe ask GitHub with gh api, one request at a time, and keep the answers in the work directory, so a run again asks nothing twice. When GitHub cannot show the pull request, the commit proves nothing, and the label fails as unverified. harvest does not ask yet, so it leaves such files out. The design doc now says that exclusions which would take a label under the tree's floors wait for their replacements and ship with them.
webern
marked this pull request as ready for review
September 27, 2026 03:48
6 tasks done
webern
added a commit
that referenced
this pull request
Sep 27, 2026
## Summary This grows the corpus's big tier from 1,200 fixtures to 21,891 live ones. It adds a second batch, `2026-09-27-02`, with 21,075 fixtures from a new harvest: 11,473 `human`, 9,003 `llm` and 599 `mixed`. The same batch excludes the 384 fixtures of the first batch that `recheck` (#46) no longer proves. The tree is resampled so each label still holds 400. To get there, `collect.py` changed in five places: - `discover` is now a list of named samplers. Each says whether it needs a `gh` login and skips itself without one. The new ones search Sourcegraph for agent files and for topics, some outside software, and search GitHub commits for the marks agents write. - `harvest` asks GitHub's GraphQL API about every candidate first, 100 at a time, so forks, bad licences and huge histories are never cloned. It clones in parallel, reads each history in one pass, checks a nearer `LICENSE` than the root one, logs failures and retries them on the next run, and asks GitHub about squash-merges as `recheck` does. It keeps up to 50 files of each label from a repository, at random, and always keeps a `mixed` file's `human` twin. `--limit` and `--deadline` bound a run. - `stage` is new, and it is the one writer of sidecars. It writes version 3 sidecars and the batch's `repos.jsonl`, the ledger of every repository the harvest tried. - `pack` checks that every `before` names a live `human` twin. - `select` samples the tree from the big tier, keeps what is still live, and refills each label. Sidecar version 3 adds the raw evidence behind a label: each mark as written (`text`, `tool`, `kind`, `place`, `commits`), each marked commit's change to the file with its blob ids (`edits`), `truncated`, and the committer dates. A `mixed` sidecar may add `before`, which names its `human` twin (the same file at the last commit before 2022) and the commits between that are not an agent's. The loaders accept versions 2 and 3, check the ledger against the manifest, and check that every `before` names a live `human` fixture. The big tier now holds files of 128KB at most; the tree stays at 64KB. `docs/design/corpus.md` has a new Register section (there is no `baseline` label; register is a facet of `human`, tagged `sg-register:`), the twin rule, and the per-repository cap. `docs/design/corpus.asbuilt.md` and `scripts/blobstore/blobs.md` describe the new batch, the ledger and the discovery samplers. `blobs.md` now gives the image a budget of 250MB unpacked. ## Discovery `discover` found 70,418 distinct repositories, 67,878 of them on GitHub. A repository found by several samplers counts once in the total and once for each sampler below. | Sampler | Token | Repositories | Seconds | Notes | | --- | --- | --- | --- | --- | | `sourcegraph-agent-files` | no | 31,390 | about 900 | 8 patterns: `CLAUDE.md`, `AGENTS.md`, `GEMINI.md`, `.github/copilot-instructions.md`, `.claude/` commands, agents and skills, `.cursor/rules/`, `.kiro/`, `.windsurfrules` | | `sourcegraph-topics` | no | 21,510 software, 4,510 register | 11,320 | about a minute per query | | `github-commit-marks` | yes | 11,695 | 2,215 | 18 searches, each on 20 random days | | `crates.io` | no | 2,645 | 113 | by downloads | | `gitlab-stars` | no | 1,000 | 16 | | | `huggingface` | no | 1,000 | 3 | | | `codeberg-stars` | no | 497 | 59 | | | `npm` | no | 244 | 33 | | Limits: - Sourcegraph searches only the repositories it indexes, a slice of public GitHub, and each query asks only for repositories with a permissive licence file at the root. A topic query takes the first 300 or 500 results. It needs no token, which is why it leads. - GitHub commit search returns at most 1,000 results per query, so each search is cut into single days. Its secondary rate limit fired at 3 seconds between searches, so the pace is now 6 seconds. It interleaves the searches by day, in random order, so a run cut short still covers every tool. - The topic search is slow and coarse. The register topics (books, courses, essays, law, recipes, wikis, curated lists and the like) gave 337 repositories that the harvest tried. - GitLab, Codeberg and Hugging Face gave almost nothing: under one `human` file per repository, and no `llm`. - crates.io failed at page 215 with HTTP 400, so it now reads pages under 200. ## Pilot 200 repositories in `sources` order took 127 seconds. 39 more were skipped on GitHub's metadata before any clone. They gave 724 `human`, 116 `llm` and 13 `mixed` files, 11 of the `mixed` with their twin. - Repositories with agent files took 8.6 seconds each and gave 6.0 `human`, 2.9 `llm` and 0.38 `mixed` each. - 24 of 30 commit-search repositories were skipped for having no licence GitHub recognises. - Topic repositories gave 8.6 `human` files each; Hugging Face nearly none. - A fixture came to about 6.2KB of Markdown and 2.5KB of sidecar. The pilot showed that time would not bind the run; bytes would. At the rate the whole run went, 4 to 6 hours of harvest would have come to 350 to 500MB, well past the 250MB budget. ## The run The harvest ran in legs, to steer toward the rarer sources, and one leg was a retry: | Leg | Order and filter | Limit | Seconds | human | llm | mixed | | --- | --- | --- | --- | --- | --- | --- | | pilot | sources | 200 | 127 | 724 | 116 | 13 | | 1 | priority | 500 | 1,019 | 5,726 | 1,234 | 343 | | 2 | priority | 250 | 441 | 2,720 | 518 | 79 | | 3 | priority, commit search for every tool but Claude Code | 1,000 | 621 | 905 | 3,586 | 74 | | 3b | the same, the 309 that failed in leg 3 | 309 | 5,072 | 673 | 3,418 | 108 | | 4 | priority, register topics | 150 | 1,056 | 432 | 619 | 14 | | 5 | sources, register topics | 150 | 165 | 631 | 284 | 7 | | all | | | 8,501 | 11,811 | 9,775 | 638 | `priority` order takes first the repositories an agent was found in that began before 2022, since only they can give `mixed` files; then the other agent repositories; then the rest. Within each, the sources take turns, a repository standing for the rarest source that found it. Discovery ran for about 4 hours alongside the legs. Leg 3b was slow because its repositories lean on squash-merges, and the harvest asks GitHub about those at most 4,800 times an hour, under its limit. What the ledger says about the 3,232 repositories tried: - 2,238 harvested, 989 skipped on GitHub's metadata (801 with no licence GitHub recognises, 67 GPL-3.0, 27 AGPL-3.0, and so on), 4 gone, and 1 with 60,361 commits, past the limit. - 4 more failed on network errors and are left for the next run. - 1,388 gave a fixture to the batch. - Files that qualified: 59,724 `human`, 64,039 `llm` and 739 `mixed`. Kept: 11,473, 9,003 and 599. Past the cap of 50, 3,938 `llm` files were not asked about. - Dropped while reading: 12,692 whose text may be older than their history (8,565 of those from one repository, `tmorin/plantuml-libs`), 2,879 under a nearer licence that is not allowed, and 1,792 whose bytes a merge commit changed. `stage` then left out 1,022 files whose bytes another fixture already has, 68 whose origin the first batch holds, and 59 over 128KB. ### The batch | | human | llm | mixed | | --- | --- | --- | --- | | Fixtures | 11,473 | 9,003 | 599 | | Repositories | 873 | 677 | 238 | - 474 `mixed` fixtures have their `human` twin. 6 lost it in `stage`, where the twin was left out, and 119 never had one: no `human` revision of the file qualified at the cutoff. For most of those, the repository had no licence GitHub recognises at the cutoff. - `llm` by tool: Claude Code 5,254, Copilot 1,516, Cursor 752, Codex 620, Amp 352, Devin 331, Jules 205, OpenHands 190, opencode 136, Kiro 77, Aider 48. Six tools have 300 or more. - `mixed` by tool: Claude Code 412, Copilot 116, Cursor 73, Codex 20, and 4 each for Jules, Amp and Devin. - By first source: agent files 13,592, commit search 6,165, software topics 680, register topics 263, crates.io 210, npm 127, GitLab 22, Codeberg 16. Counted by any source in the ledger, register repositories gave 1,545 `human`, 967 `llm` and 81 `mixed`. - 17,834 in English, 3,108 in another language, 133 with no prose to tell. - 21,037 from GitHub, 22 from GitLab, 16 from Codeberg. Bytes: 142,677,577 of Markdown and 203,442,958 in all (sidecars about 50MB, the manifest 9.3MB, the ledger 1.2MB). With the first batch the image is 215MB of its 250MB budget. ### Sizes and the cap Every file the harvest read has its size recorded, 22,261 in all: median 3,305 bytes, p90 15,551, p99 77,728, p99.9 367,767, largest 2,574,278. | Cap | Files over it | Their share of bytes | | --- | --- | --- | | 64KB | 1.31% | 27.1% | | 128KB | 0.43% | 17.6% | | 256KB | 0.17% | 11.9% | By label at 128KB: `human` 0.57% of files and 24.7% of bytes, `llm` 0.15% and 7.4%, `mixed` 2.18% and 37.4%. At 64KB, `mixed` would lose 5.3% of its files. So the cap is 128KB: it costs few files, and `mixed` files, which tend to be long, keep most of theirs. Many of the files over it are changelogs and link lists. ## Exclusions The batch excludes the 384 fixtures `recheck` found in #46: 204 `llm` and 180 `mixed`, none `human`. 339 of them rest on a squash of several commits, which cannot say who wrote one file. Most of the other 45 rest on a commit whose mark the rules of section 3 no longer accept, 2 on a bot's commit and 3 on text older than its history. Each line of `exclude.jsonl` gives the reason. ## The tree | | human | llm | mixed | | --- | --- | --- | --- | | Before | 400 | 400 | 400 | | Dropped | 0 | 204 | 180 | | Added | 0 | 204 | 180 | | After | 400 | 400 | 400 | `select` kept every fixture still live and filled from the big tier. `select --check` passes. The floors hold: 400 in each label (the floor is 350), 18 layouts (the floor is 10), and the character test's `llm >= 4 * human` at 248 against 4 * 57 = 228 (it was 241 before). The tree now holds 204 `llm` and 180 `mixed` sidecars at version 3, and 147 of those `mixed` name a twin. ## Golden files `make fix-golden` moved only `llm` and `mixed` lines. Every changed line is a fixture dropped or added; no fixture that stayed changed its measurement, and `core` and `human` did not move. | Lint | Fails before | Fails after | | --- | --- | --- | | `banned_chars` | 469 (llm 241, mixed 165) | 494 (llm 248, mixed 183) | | `banned_phrases` | 221 (llm 29, mixed 121) | 207 (llm 32, mixed 104) | | `density` | 279 (llm 92, mixed 126) | 294 (llm 104, mixed 129) | | `max_emphasis` | 491 (llm 230, mixed 173) | 499 (llm 244, mixed 167) | | `max_size_bytes` | 166 (llm 25, mixed 106) | 173 (llm 31, mixed 107) | | `repo_layout` | 2 (mixed 1) | 3 (mixed 2) | ## The `deslag fix` tally `tests/corpus.rs` pins what `deslag fix` does to the tree (#51), so the numbers are pinned again: | | Before | After | | --- | --- | --- | | Banned characters | 6,399 in 469 fixtures | 7,423 in 494 fixtures | | Fixed | 5,400 | 6,443 | | Fixtures fixed whole | 350 | 358 | | Left: replacement holds letters or digits | 737 | 732 | | Left: the edit changes how the file reads | 153 | 143 | | Left: in HTML | 71 | 56 | | Left: in frontmatter | 23 | 40 | | Left: default for a range of characters | 14 | 6 | | Left: in a URL | 1 | 1 | | Left: drawn as one with the character beside it | 0 | 2 | The last row is new: a corpus edit now reaches the grapheme check and is refused there. ## Precision A sample of the batch was checked against GitHub's own record, not the clone the harvest read. For each fixture: GitHub's list of the commits that touched the file up to the quoted commit, labelled again from their authors, committers and messages with the same rules and the same squash-merge questions; the bytes GitHub serves at that commit; for `human`, that no commit is late or marked; and for `llm`, that GitHub says the oldest commit added the file rather than renamed it. One fixture per repository in each stratum, 30 where there were 30 repositories. `human` is split by register, and `llm` and `mixed` by the kind of evidence: an agent's identity, a session trailer only, or a squash-merge GitHub proved. | Stratum | Checked | Label wrong | Precision, 95% Wilson | Commit list differs | | --- | --- | --- | --- | --- | | human, register | 30 | 0 | 1.000 [0.886, 1.000] | 0 | | human, software | 30 | 0 | 1.000 [0.886, 1.000] | 0 | | llm, identity | 30 | 0 | 1.000 [0.886, 1.000] | 0 | | llm, session | 30 | 0 | 1.000 [0.886, 1.000] | 1 | | llm, squash-merge | 30 | 0 | 1.000 [0.886, 1.000] | 0 | | mixed, identity | 30 | 0 | 1.000 [0.886, 1.000] | 5 | | mixed, session | 9 | 0 | 1.000 [0.701, 1.000] | 2 | | mixed, squash-merge | 30 | 0 | 1.000 [0.886, 1.000] | 3 | All 239 labels hold, and GitHub serves the same bytes for every one. In 11 the commits differ, though the label GitHub's list gives is the same: - In 9, GitHub lists fewer commits than the sidecar counts (for example 129 against 784 for `cksystemsteaching/selfie/README.md`). The harvest reads the whole history in one pass, so a file's history holds every commit that changed it on any branch. GitHub's list for a path leaves out a side branch whose changes a merge did not take. - In 2, a marked commit of the sidecar is not in GitHub's list. In `valve-tech/reth`, GitHub lists a copy of it instead, with the same change, author date and message under another hash; in `tui-cs/Terminal.Gui`, it is an ancestor of the quoted commit that changed the file, on a branch GitHub's list leaves out. ## The image v2 is published and pinned: `ghcr.io/webern/deslag-blobs:v2@sha256:33d0d99e2d588f31d7d69563d62599486bcd1e89fe8efcfed6fcdf047d6fca00`. It reuses the first batch's layer as it is, and adds one layer, `corpus/batches/2026-09-27-02`, which holds only the batch's 21,075 fixtures, their 21,075 sidecars, and its `manifest.jsonl`, `exclude.jsonl` and `repos.jsonl`. From a cold cache (`.blobs/` moved aside), `make fetch-blobs` unpacked v2 in 26 seconds, the unpacked tree was identical to the one published, and `make test-blobs` passed. ## Other changes - The corpus tests place fixtures at their real paths, and the walk honours the global git excludes file. A new fixture sits under `.vscode/`, which some machines' global excludes ignore, so those machines walked a different corpus. `place_real` now writes a `.ignore` of `!*`, which takes precedence over the global file, so every machine walks the same files. - `tests/blobs.rs` builds its small batches from fixtures with no `before`, since the tree now holds some, and turns a sidecar into version 2 where a test needs one. - The pace file that the harvest's processes share for GitHub questions could be left holding two times run together, since a write was flushed after its lock was let go. It is now flushed first, and a bad value is read as "now". - In `corpus.md`, the example commit links in the marks table are cut to 10 hex characters, to keep the doc in its 16384-byte budget. ## Deviations - The run was 7 legs, not one command, and it stopped at 8,501 seconds of harvest, not 4 to 6 hours. Bytes bound it, not time. - 474 `mixed` fixtures have a twin, a little under the 500 hoped for. The last `priority` leg gave 79 `mixed` files along with about 3,200 others, some 30MB, so more would have spent the budget's headroom. - 309 repositories of leg 3 failed on the pace-file bug above. They were retried in leg 3b, and 3 of them failed again on the network. - `qualified` in the ledger counts, for `llm` and `mixed`, the files whose commits prove the label. The check for text older than its history runs only on files that are read, so `qualified` overstates `llm` by what that check would drop. - A sidecar's `found_by` is the repository's first source only; the ledger lists all of them. So a register analysis should read the ledger: 263 fixtures carry `sg-register:` in their sidecar, while register repositories gave 2,593. - The full-history reading above means a `mixed` label may rest on an agent's commit on a side branch whose change a merge did not take. GitHub's list agreed on the label for all 69 `mixed` fixtures checked, but a later change could read the history as the file's own line of descent instead. ## Left for later - A byte budget for a harvest run, in place of `--deadline`, and maybe a lower cap for `human`: it has 11,473 fixtures, well past the 3,000 to 5,000 hoped for, and the image has 35MB of budget left. - The 4 repositories that failed on the network are retried on the next run. - 3,938 `llm` files past the cap were not asked about. A later run can take them if a repository is worth more than 50. ## Testing - [x] `make ci`: exit 0 - [x] From a cold cache: `make fetch-blobs` unpacks v2 byte for byte as published, then `make test-blobs` passes - [x] `make test-blobs`: every fetched batch keeps the rules, every tree fixture is in the big tier with the same sidecar - [x] `collect.py select --check`: the tree is the sample it would take - [x] `scripts/blobstore/blobs.sh plan`: the first batch is the same layer, the second is new; it took 10 seconds over both batches - [x] Precision against GitHub's own record, per stratum (above) ## References - Related: #16, #18, #33
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
deslag's corpus is Markdown quoted from public repositories. Each file, a fixture, is labeled
human,llmormixedfrom its git history: which commits touched it, when, and whether an AI agent made them. The lints are measured against those labels, so a wrong label is a wrong measurement.The rule behind the labels was too loose. It looked for tool names anywhere in a commit, so a mention, a suggestion a person accepted, or a squash of many commits could make a file
llmormixed. This PR replaces it with a table of the marks each agent writes itself, matched only where the agent writes them. A GitHub squash-merge proves its marks only when GitHub shows that every commit of its pull request carries one. Then it rechecks every fixture of the big tier against the new rule, from full-depth clones: 384 of the 1200 no longer hold (204llm, 180mixed, nohuman).The 384 exclusions ship with the next harvest, in one batch with the fixtures that replace them, and the tree drops and refills in that same change. Dropping them now would take
llmto 196 fixtures andmixedto 220, under the 350 per label thattests/corpus.rsrequires. So this PR publishes nothing: no new image, and no change toblobs.lock,tests/corpus/or the golden files.What ships:
scripts/llm-detection/collect.py(MARKS,label_history) anddocs/design/corpus.mdsection 3, with the table of marks and a real commit for each.PullRequestsincollect.py, which asks GitHub what a squash-merge's pull request held.collect.py recheck, which clones each repository the big tier quotes, derives every live label again, and writes the ones that fail toexclude.jsonlin its work directory.collect.py pack --exclude, which writes those exclusions into a new batch.docs/design/corpus.asbuilt.mdbrought up to date.What was wrong
The old rule searched the author, the committer and the whole message for tool names. So:
google-gemini/gemini-cli. The file it added was labeledllm, written by "gemini". In reisxd/TizenTubeCobalt 8a45a90 a person writes "Fix the build error manually or by Gemini-CLI", and that made the filemixed.Co-authored-by:lines is Copilot Autofix, a fix a person accepted in review. Its file was labeledllm.llm, but pull request #3497 held five commits, and a person's commit in it touched the file. In nrwl/nx 8cec6ce, pull request #31380 held two commits, and neither carries an agent's mark.--shallow-since=2018-01-01, so an older file seemed to begin at that boundary. 69 of the 400mixedsidecars say the file was "begun by a person, unmarked" on a day in January 2018, and 47humansidecars record a first commit then. Forllm, a cut history could hide a person's older commits.The new rule
human: every commit that touched the file is a person's from before 2022-01-01, by both its author date and its committer date, and none carries any mark.llm: every commit is an agent's, and the file's text is no older than that history.mixed: at least one commit is a person's from before 2022-01-01 with no mark, and at least one is an agent's.A commit is an agent's when it carries a mark that counts and is not a squash. A mark is a regular expression matched in one place:
identity(the author, the committer, or the value of aCo-authored-by:trailer),trailer(another line of the trailer block that ends the message), orfooter(a line a tool writes into that block, such as "Generated with Claude Code" after a robot emoji). Its kind isagent-identityoragent-session, which count, orassist, which never does. An assist is a tool's suggestion that a person committed.In short, the 32 marks are:
[email protected],claude[bot], theClaude-Session:trailer, the session link and "Generated with Claude Code" footersCopilot-Session:andAgent-Logs-Url:trailers, the Copilot Workspace footer[email protected]co-author[email protected], theMade-with: Cursortrailer, the "Made with Cursor" footerCodex <[email protected]>,[email protected], thecodexaccountName (aider),[email protected][email protected], theAmp-Thread-ID:trailer[email protected], the "Generated with OpenCode" footergemini-code-assist[bot], a review's suggestionAssisted-by:trailerThe full table, with the exact patterns and an example commit for each, is in
docs/design/corpus.mdsection 3.Three shapes make a commit a squash: two or more paragraphs that open with
*, as GitHub lists squashed commits; the headergit merge --squashwrites; or a last line of nine dashes followed only by trailers, which is how GitHub gathers the squashed commits' co-authors.A marked commit whose subject ends in "(#N)" is taken for a GitHub squash-merge. It proves its marks only when every commit of the pull request merged as it carries a mark that counts.
collect.pyasks GitHub withgh api, one request at a time and at most two a second, and keeps the answers in its work directory. When GitHub cannot show the pull request, because none was merged as the commit or GitHub refuses, the commit proves nothing, and a label that needs it fails with its own reason,unverified.llmalso needs the text to be the agents'. When the commit that added the file deleted a Markdown file of the same name, or one that git's rename detection pairs with it, or when a merge added the file, the text may be older than its history, so the file gets no label. A history that ends at a shallow boundary says so in its basis and rules outllm. The cutoff stays at 2022-01-01, as #5 set it.What the recheck found
collect.py recheckmade full-depth blobless clones of all 1072 repositories the big tier quotes and derived each of the 1200 labels again. No repository was gone. The clones took about five minutes with 12 jobs, and the questions to GitHub about 13 minutes.unverified)Each fixture is counted once, under one reason. The mention cases above land in "a commit that is not an agent's" and "no agent's commit at all".
The squash-merge rule adds 61 of the 384 exclusions: 26
llmand 35mixed. 4 of thosemixedare counted under "a squash", since they also hold one. 3llmfixtures that the first pass excluded because their text moved now fail on a squash-merge first.292 marked squash-merges were asked about. 185 were proven, 119 of them pull requests of one commit. 88 had a commit with no agent's mark. For 18, GitHub shows no pull request merged as the commit: pytorch/pytorch #196869 and facebook/metro #1632, for example, were closed, not merged, and their commits landed another way. 1 request was refused:
DataDog/datadog-agentrequires SAML access that the token used did not have. The 7unverifiedfixtures come from those.Of the squashes, the first pass found 112
llmand 96mixedthat list the squashed commits and 41 and 25 with only the nine-dashes shape. A pull request of one commit gives that shape too, so I looked up the pull request of each of those 66: none had one commit, and in 36 of them a person's commit in the pull request touched the file.The floors the exclusions would break
With the 384 fixtures dropped from a local copy of the tree, three tests of
tests/corpus.rsfail:every_category_is_well_stocked:llmwould hold 196 andmixed220, fewer thanMIN_PER_CATEGORY, 350.the_default_groups_flag_llm_text_far_more_than_human_text:banned_charswould flag 57humanfixtures and 133llm, and the test needsllmto be at least 4 timeshuman, 228. As a rate it still holds: 68% ofllmfixtures against 14% ofhuman.the_corpus_layouts_read_from_the_text_alone: 6 layouts, where it needs 10.The floors stay as they are. The next harvest has to bring at least 154
llmand 130mixedfixtures that hold under these rules, and, for the layout test, files with real layouts. The tree was restored after the dry run.How far the labels that hold can be trusted
Before the squash-merge rule, I took a stratified sample of 123 fixtures that held under an earlier draft of these rules (seed 20260927), and checked each by hand against its commits and pull requests on GitHub:
human: 30 of 30 right.llm: 56 sampled, 2 wrong, 5 could not be checked.mixed: 37 sampled, 3 wrong, 1 could not be checked.Every wrong label in the sample rested on a GitHub squash-merge, and all five are now excluded. No fixture that rests on direct commits was wrong: 0 of 32
llmchecked and 0 of 15mixed.I also checked every squash-merge a label rested on against a looser test: did a commit of the pull request that is not an agent's touch the file? That found 16
llmand 17mixedlabels wrong, and all 33 are excluded now. The rule in this PR is stricter, since it does not ask which files a commit touched. It also excludes 5llmand 15mixedfixtures that the looser test found right.Deviations and doubts
llmand 3mixedfixtures.unverifiedfixture fromDataDog/datadog-agentfails only because the token used lacks SAML access to that organization. A run with such access would ask again.harvestdoes not ask GitHub yet. With the rule as it is, it leaves out any file whose label rests on a squash-merge, which costs the next harvest fixtures unless it asks.Co-authored-by:value is matched as an identity, like the author and committer, not as a trailer.(cherry picked from commit ...)line is read as a footer, so it does not hide the trailers above it.[email protected]is typed as an assist. It comes from VS Code'sgit.addAICoAuthorsetting, which I read as a sign of help, not of an agent's commit.codexaccount (267193182) is a User account, not a Bot. It is listed because its profile names it "OpenAI's coding agent", with company OpenAI and a link to openai.com/codex.[email protected]was seen as a co-author), Antigravity ([email protected]), a[email protected]co-author, and Pi. Leaving a mark out can only cost fixtures. It never makes a label wrong, since an unlisted mark makes the commit a person's commit after the cutoff.Left for later
llmandmixedfixtures under these rules, then one batch with them and the 384 exclusions, the tree dropped and refilled, and the golden files regenerated, in one change.harvestasking GitHub about squash-merges, asrecheckdoes.Testing
make ci: exit 0corpus.md's table matchesMARKSrow for row.collect.py recheckover all 1200 fixtures of v1 at full depth, then again with the squash-merge rule. A run on the kept evidence and answers takes about 5 seconds and writes the sameexclude.jsonl.References