{"id":14784,"date":"2026-11-27T01:02:00","date_gmt":"2026-11-27T06:02:00","guid":{"rendered":"https:\/\/www.both.org\/?p=14784"},"modified":"2026-11-26T08:05:58","modified_gmt":"2026-11-26T13:05:58","slug":"what-should-a-maintainer-require-from-an-ai-written-patch","status":"publish","type":"post","link":"https:\/\/www.both.org\/?p=14784","title":{"rendered":"What Should a Maintainer Require From an AI-Written Patch?"},"content":{"rendered":"<div class=\"pld-like-dislike-wrap pld-template-1\">\r\n    <div class=\"pld-like-wrap  pld-common-wrap\">\r\n    <a href=\"javascript:void(0)\" class=\"pld-like-trigger pld-like-dislike-trigger  \" title=\"\" data-post-id=\"14784\" data-trigger-type=\"like\" data-restriction=\"cookie\" data-already-liked=\"0\">\r\n                        <i class=\"fas fa-thumbs-up\"><\/i>\r\n                <\/a>\r\n    <span class=\"pld-like-count-wrap pld-count-wrap\">    <\/span>\r\n<\/div><\/div>\n<p class=\"wp-block-paragraph\">Repository code owners face a dilemma I keep coming back to: review increasingly large AI-written patches more carefully, accept a slower release pipeline, or become more hands-off and carry more risk. The patch itself cannot settle that trade-off. When I review code with another engineer, on either side of the discussion, we talk almost as much about how the work was written, run, tested, and deployed as about the lines in the diff. Here I am writing about the human difference between writing and doing, but it applies to AI coding agents as well.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">The work behind a pull request<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In college, my COMP 202 introduction to Java, typing the code was briefly the difficult part. But in the grand scheme of a software engineering career, understanding the syntax is a tiny piece of the puzzle. The following years were spent learning how to run and deploy it in different environments. At one of my first full-time PHP jobs, working in a large monorepo with an ORM, I didn&#8217;t always know how I was supposed to test a change. Some of my early PRs may have been fingers-crossed affairs. A senior engineer eventually showed me how to execute PHP scripts directly in the CLI instead of launching an entire web server. The people who reviewed my PRs began to trust me more, and I managed to flourish as a junior developer.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The process of writing code is as important as the outcome. Two patches might look identical, but the engineer who understood how to exercise the relevant behavior is in a better position to explain its limitations. That explanation is part of what a reviewer needs from the author, not just the artifact.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">The answer isn&#8217;t another checkbox<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">A common response is to add more questions to the pull-request template: list the commands you ran, check a box saying you used AI, explain how you tested it. That may help some projects, but it is a weak answer to a review-capacity problem. A coding agent can fill out a form as easily as it can write an optimistic PR description. The maintainer still has to decide whether those statements are supported by actual work. Requiring every volunteer to install a new telemetry stack, create an account, or learn an organization&#8217;s release process would be the opposite mistake. It would make contributing harder precisely when open source needs thoughtful new contributors.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I&#8217;d rather offer contributors a path to build greater confidence in a merge, instead of imposing another onboarding requirement on everyone. Someone who has put serious effort into understanding and validating a change should be able to show that effort without asking the reviewer to trust a self-reported checklist. A maintainer should be able to recognize that additional evidence and decide whether it justifies taking a closer look. This is not a guaranteed fast lane, a paid badge, or an automatic merge approval. It&#8217;s an optional signal that a contributor has done work worth inspecting.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Try the evidence in a Linux terminal<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">For this exercise, we&#8217;ll use a public Python repository called grader-issue-lab. It contains a miniature order-processing application named ParcelDesk, six GitHub issue assignments, and an offline simulator that compares recorded validation evidence against expected checks. It also links to real Claude Code sessions and GitHub PR checks, which we&#8217;ll inspect separately. You do not need a coding-agent subscription or Code Telemetry account for the offline portion.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The repository requires Python 3.12 or later and uses Git and Make. Its developer environment installs pinned versions of pytest and ruff into a local virtual environment. Open a terminal, check your versions, and clone the repository:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>python3 --version\ngit --version\nmake --version\ngit clone https:\/\/github.com\/CodeTelemetry\/grader-issue-lab.git\ncd grader-issue-lab\nmake install<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The first install needs network access to download the dependencies; the subsequent offline demonstrations don&#8217;t need a cloud service. If you cannot create the virtual environment, install its matching python3-venv package or follow the uv fallback in docs\/REPRODUCE.md. The repository&#8217;s Makefile gives the validation commands short, consistent names, which makes them easier both to run and to recognize in a session record. Try these ordinary development checks:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>make org-lint org-unit repo-integration<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The first command runs ruff, the second runs unit tests, and the third runs ParcelDesk&#8217;s repository-level integration tests. Those checks answer different questions, even though all three may return successful exit codes.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">When a pass becomes stale<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The examples\/evidence directory contains 18 deliberately constructed session fixtures. Each declares itself synthetic; these aren&#8217;t recordings of real agents. Run the simulator&#8217;s tests and compare all fixtures against the expected-results matrix:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>make labgrader-test offline-repro<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">The repository documents an expected closing line of \u201c18 fixtures, 0 mismatches.\u201d That is a consistency test for the simulator, not an attestation that an agent actually performed those activities. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now examine a pagination assignment where the validation ran, but a source edit followed it:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>.venv\/bin\/python -m labgrader.repro --explain examples\/evidence\/05-pagination-stale.json<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">That command displays the fixture\u2019s individual checks and why they are marked stale.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The expected output marks the four applicable checks stale. Their previous results are real within this synthetic history, but they precede the final edit. They no longer establish what happened with the files being proposed for review. That distinction is useful even when the actual test command reported success at the time. A reviewer should be able to see whether the evidence applies to the code in front of them.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The offline fixtures explain how a policy reads recorded evidence; the public pull requests show the corresponding historical gate behavior against real agent sessions.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In pull request #10, the organization and repository checks passed while an issue-specific authorization test failed. A later correction and fresh validation produced a passing result. The contributor could point to an actual change in evidence, not simply rewrite the PR description to sound more convincing. Pull request #11 shows another important limit: all checks had passed before a later code edit, so the live gate initially failed despite a numeric score of 100. Fresh validation against the same head, without further edits, produced a passing gate result. That is a concrete demonstration of why evidence should be tied to the revision a maintainer is considering.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Give contributors a positive path to trust<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">The starting point is a project&#8217;s normal contribution process: a focused change, an issue or explanation, and independent CI. A contributor who wants to provide stronger assurance can go a step further and attach verifiable evidence from the development session. That evidence should show which relevant checks were run, their observed outcomes, the context or tools consulted, and whether the checks still apply to the final edit. A reviewer should be able to see the result without reading a full conversation transcript, then drill into the deciding events when something looks questionable. When a project supports an automated Grader, its check can make that evidence visible alongside ordinary GitHub checks. The agent&#8217;s own claim that it tested the patch is not the evidence; the observed commands, results, and tested revision are.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This particular lab uses Code Telemetry and instrumented Claude Code sessions, and running a new live gate requires the repository and workspace integration to be configured. For projects without such integration, contributors can still offer reproducible tests and inspectable external evidence (just through a different medium). For projects that choose to support a Grader, the goal is to let contributors opt into the stronger path and make its results easy to inspect.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">When review capacity is scarce, maintainers have every reason to be selective about where they invest attention. But treating every unfamiliar AI-assisted contributor as spam risks discarding useful work and discouraging newcomers. An optional evidence path gives maintainers an additional signal while preserving a way to contribute without special tooling. It also gives conscientious contributors a way to distinguish themselves from mass-produced, unvalidated submissions. The same project can retain its ordinary human review and CI requirements while recognizing that one PR arrives with better evidence of the work that produced it.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Make confidence earnable<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">What I&#8217;d like to change is the default interaction between a contributor and the person who has to review their work. Today, a contributor can hand over a large AI-written diff and a reassuring summary, leaving the maintainer to reconstruct how it was tested. A better path lets the contributor do the verification work first and hand over a concise, inspectable record of it. That reduces uncertainty before review begins, without asking volunteers to navigate a new bureaucracy. In an era when generating patches is cheap and maintainer attention is not, making confidence something contributors can earn is a better compromise than pretending another template will solve the problem.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">References and reproducible examples<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/github.com\/CodeTelemetry\/grader-issue-lab\">Public lab and reproducible Linux\/Python examples<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/github.com\/CodeTelemetry\/grader-issue-lab\/blob\/main\/docs\/REPRODUCE.md\">Offline reproduction instructions<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/github.com\/CodeTelemetry\/grader-issue-lab\/pull\/10\">PR #10 \u2014 authorization acceptance failure and remediation<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/github.com\/CodeTelemetry\/grader-issue-lab\/pull\/11\">PR #11 \u2014 stale pagination validation and recovery<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/codetelemetry.com\/blog\/more-confidence-not-more-code-review\">Earlier published company essay<\/a><\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Repository code owners face a dilemma I keep coming back to: review increasingly large AI-written patches more carefully,<\/p>\n","protected":false},"author":513,"featured_media":2725,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_lmt_disableupdate":"","_lmt_disable":"","footnotes":""},"categories":[307,98,5,546],"tags":[1008,1007],"class_list":["post-14784","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-ai","category-code","category-linux","category-maintenance","tag-ai-written","tag-patch"],"modified_by":"David Both","_links":{"self":[{"href":"https:\/\/www.both.org\/index.php?rest_route=\/wp\/v2\/posts\/14784","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.both.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.both.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.both.org\/index.php?rest_route=\/wp\/v2\/users\/513"}],"replies":[{"embeddable":true,"href":"https:\/\/www.both.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=14784"}],"version-history":[{"count":8,"href":"https:\/\/www.both.org\/index.php?rest_route=\/wp\/v2\/posts\/14784\/revisions"}],"predecessor-version":[{"id":14807,"href":"https:\/\/www.both.org\/index.php?rest_route=\/wp\/v2\/posts\/14784\/revisions\/14807"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.both.org\/index.php?rest_route=\/wp\/v2\/media\/2725"}],"wp:attachment":[{"href":"https:\/\/www.both.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=14784"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.both.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=14784"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.both.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=14784"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}