# The Provenance Gap in Agent-Written Code

DevFeed: [The Provenance Gap in Agent-Written Code](<https://devfeed.tech/articles/the-provenance-gap-in-agent-written-code-55875.md>)

Original publisher: [Read original article](<https://swamp-club.com/feed/p/759986b0-a1e1-4a31-a029-bebac3ee394e/go>)

Author: stack72

Published: 2026-09-17T21:22:09Z

Content type: article

Language: en

Sources: [Swamp Club Feed](<https://devfeed.tech/sources/swamp-club-feed.md>)

Topics: [AI software supply chain security](<https://devfeed.tech/topics/ai-software-supply-chain-security.md>), [AI Agent](<https://devfeed.tech/topics/ai-agent.md>), [CI/CD](<https://devfeed.tech/topics/cicd.md>), [slsa levels](<https://devfeed.tech/topics/slsa-levels.md>), [Code review](<https://devfeed.tech/topics/code-review.md>), [Post Mortem](<https://devfeed.tech/topics/post-mortem.md>), [software artifact signing](<https://devfeed.tech/topics/software-artifact-signing.md>)

Tags: [accountability](<https://devfeed.tech/tags/accountability.md>), [agent](<https://devfeed.tech/tags/agent.md>), [agent-verification](<https://devfeed.tech/tags/agent-verification.md>), [agents](<https://devfeed.tech/tags/agents.md>), [ai](<https://devfeed.tech/tags/ai.md>), [attestation](<https://devfeed.tech/tags/attestation.md>), [audit](<https://devfeed.tech/tags/audit.md>), [authoring](<https://devfeed.tech/tags/authoring.md>), [behaviour](<https://devfeed.tech/tags/behaviour.md>), [build](<https://devfeed.tech/tags/build.md>), [building-with-ai](<https://devfeed.tech/tags/building-with-ai.md>), [code](<https://devfeed.tech/tags/code.md>), [configuration](<https://devfeed.tech/tags/configuration.md>), [content](<https://devfeed.tech/tags/content.md>), [control](<https://devfeed.tech/tags/control.md>), [coverage](<https://devfeed.tech/tags/coverage.md>), [gap](<https://devfeed.tech/tags/gap.md>), [process](<https://devfeed.tech/tags/process.md>), [provenance](<https://devfeed.tech/tags/provenance.md>), [repair](<https://devfeed.tech/tags/repair.md>), [verification](<https://devfeed.tech/tags/verification.md>)

## AI overview

A final attestation records which controls passed for a commit, but it does not show the failed attempts, fixes, or diagnostic path that led an agent to a green result. That gap can leave the person accountable for agent-written code unable to investigate an incident. The article proposes retaining a structured iteration record tied to the final attestation: each attempt's input and output commit or diff, checks and failures, governing model and configuration, and a link to the next attempt. Keep the actual prompts and rules durably recoverable; checksums establish configuration integrity but do not preserve their content. Record evidence tracing rather than full conversation transcripts, and treat agent explanations as investigative input, not proof of root cause. Verification coverage and review provenance can clarify what checks and review examined. Signing records can make tampering detectable, while hardened execution environments provide stronger assurance; neither replaces retaining the history. Iteration provenance makes the process auditable but does not prove the run was honest or the agent's interpretation correct.

## Source excerpt

When an agent owns the verification-and-repair loop, what record of that process survives? The attestation captures the terminal state. The iterations that preceded it -- the failures, the fixes, the diagnostic path -- vanish the moment verification succeeds.