Accountability in AI Review
Introduction
Welcome to the final lesson of Review AI-Assisted Python Changes. We have learned to verify suggested behavior, split large changes into reviewable pieces, and check whether proposed methods actually exist. Now we will focus on accountability: who owns an AI-assisted change, and who should receive review feedback? We will follow a ticket summary from an AI-drafted mistake through a human author’s correction to an independent reviewer’s decision.
The Problem: AI Drafts, Humans Decide
An AI tool can help draft code, but it cannot take responsibility for a submitted change, respond to review as its owner, or make the project’s approval decision. Those responsibilities belong to people. The human author must understand and explain the change, including any generated parts. The reviewer must then check the explanation and code against observable evidence, rather than approving simply because the code was generated or the author says it works.
That gives us four distinct roles: the AI tool can assist with a draft; the human author owns the submitted change; the reviewer evaluates it independently; and tests and code provide evidence. Keeping those roles clear helps us avoid both rubber-stamping and taking over the author’s work.
Inspect the Ticket Model and the Submitted Summary
Before reviewing a summary, we need to know what the ticket stores and what the summary should report. In app/tickets.py, each Ticket has an ordered notes list. Each call to add_note appends one entry, so the number of notes comes from the number of entries in the list, not from the length of any note’s text.
Now we run the author’s submission. The entry point creates ticket 7, adds two notes, and prints the generated summary:
The ticket stores two notes, but the summary reports 31. The requirement is that the summary includes the ticket ID, title, and count of stored notes, so this output already tells us something is wrong. The next step is to find out why.
Spot the Defect: Counting Characters Instead of Notes
An AI-drafted method might accidentally count the characters in the most recent note. That can look like a count, but it answers the wrong question. The requirement asks how many notes the ticket stores, so the correct source of truth is the notes list itself.
Here, self.notes[-1] selects the latest note, and len counts its characters. The latest note, “Customer confirmed their email.”, has 31 characters, which is exactly the number in the output. Nothing in the submission would catch this, so the reviewer needs to ask for a focused test. As in the earlier code health course, a useful test is one whose expected behavior would fail when this specific mistake is present.
Direct Feedback to the Human Author
The reviewer’s job is to raise the finding with the person accountable for the change. In REVIEW.md, feedback should ask the human author to explain the count’s connection to the model and provide a test that distinguishes note counting from character counting. It should not address an AI tool as if it were a review participant.
This asks for reasoning and evidence without handing the author a rewritten implementation. The author’s account belongs in AUTHOR_NOTES.md, where they can explain their decisions and validation. The reviewer can then assess that response independently.
The Author Responds: Correct, Test, and Explain
The human author corrects the method in app/tickets.py by counting entries in the notes list:
Then the author adds the requested test in tests/test_tickets.py. It creates ticket 7, adds two notes, and checks the exact summary:
As you may recall from earlier lessons on failure-sensitive tests, a useful assertion rejects a plausible but incorrect implementation, rather than merely confirming that the code ran. This is focused evidence: counting characters in one note would not satisfy the expected count. In AUTHOR_NOTES.md, the author explains that notes is the source of truth, that the AI drafted the method but the author corrected it, and that the entry point, Flake8, and pytest all passed. The author also keeps singular grammar out of scope, avoiding unrelated work.
Make an Independent Evidence-Based Decision
Now the reviewer checks the change rather than relying on the author’s confidence or report. The reviewer runs the checks personally, then records what was observed. In REVIEW.md, the completed record names the evidence reviewed and states the decision:
LGTM is appropriate because the explanation, implementation, and test support the requested behavior, and the reviewer ran the checks instead of trusting the author’s report. Approving on the author’s report alone would be rubber-stamping. Rewriting the working correction yourself would take ownership away from the author. An independent review does neither: it verifies the evidence and records a decision grounded in that evidence.
Conclusion and Next Steps
We have completed the accountability loop: an AI tool may draft, but the human author explains and corrects the submitted change; the reviewer directs feedback to that author and makes an independent decision based on evidence. In the upcoming practices, the last of Review AI-Assisted Python Changes, we will inspect the change evidence, write feedback for the human author, step into the author’s seat to correct and explain the change, and then return to the reviewer’s seat for an evidence-based approval decision. After that, the path’s capstone brings every review habit from these courses together in one complete review cycle.
