THE GITHTML FIELD GUIDE
Check whether an AI documentation edit changes executable behavior
Do not assume an AI patch is behavior-neutral because it is described as documentation-only. Review the actual diff for code changes and for comments or docstrings consumed by tests, generators, or tooling. Identify executable examples and directives, then run relevant local checks in a safe environment before making a narrow claim about the patch's effects.
Identify which text is consumed by tooling
Ordinary prose comments may have no runtime effect, but some text participates in doctests, documentation generation, type checking, lint configuration, or code-generation conventions. Inventory the tooling relevant to the edited files. In Python, docstrings are available to introspection, and doctest can execute examples it discovers. Other ecosystems have their own annotation conventions. Do not generalize from one language to another. Read the entire diff, including imports, decorators, string delimiters, and surrounding code, rather than trusting the AI's summary of changed files. A small misplaced quote can alter parsing beyond the intended comment.
Separate prose changes from behavioral inputs
Classify each edited region as explanatory prose, literal example, executable test, directive, or actual code. The scaffold below helps reviewers record why a region needs a particular check. Inspect generated examples before running them, especially if they touch files, network services, or environment variables. Verify that a rewritten docstring still describes the same arguments, return values, and exceptions. If the AI added a tool directive or suppression comment, require an explicit reason rather than accepting it as stylistic cleanup. Keep unrelated code fixes separate so the documentation review does not silently expand into an implementation change.
Edited region:
Consumer: reader / generator / doctest / other tool
Literal or executable content:
Potential side effects:
Relevant local checks:
Observed result:
Scope beyond prose:
Remaining uncertainty:Report the verification at the right level
Run the relevant local syntax, documentation, and example checks in the approved test environment. Compare generated output when docstrings feed a public reference. A passing formatter does not establish that doctests still work, and passing doctests do not prove every application behavior is unchanged. State exactly which checks ran and what remains unverified. If the patch changes executable examples or metadata, describe that scope honestly instead of retaining a blanket documentation-only label. Preserve the reviewed diff and evidence so maintainers can understand the impact. The useful conclusion is a bounded assessment of the actual changes, not reassurance based on the file type or the model's intention. Inspect generated artifacts only as evidence, not as a replacement for reviewing the source diff. A hidden directive can affect a later build mode even when the default preview looks unchanged.
- Read the full diff and inventory tooling that consumes comments or docstrings.
- Classify edited text by whether it is prose, example, directive, or code.
- Inspect executable examples and new suppressions before running checks.
- Report exact local verification and avoid a broader behavior-neutral claim than the evidence supports.
Sources and further reading
AI-assisted writing with source-linked guidance and illustrative examples. Read our editorial approach or report a correction.