AI-Generated Code Provenance for Indemnity Claims: Proving Which Tool Generated a GPL-Matching Snippet
To support an indemnity claim for a GPL-matching snippet, an enterprise has to show more than a similarity match. It needs a record that a specific AI coding tool generated the output, with the prompt context, policy settings, timestamp, user and repository, plus proof the record was not altered. Reconstructing this from commits or vendor logs after the fact is weak. Evidence captured at generation time, in the execution path, is stronger.
Records to capture at generation time
- 1
Tool identity and version
Which assistant produced the output, and which client or plugin version was in use.
- 2
Model version
The model that served the request, as reported at the time of generation.
- 3
Prompt and context
The request and the surrounding code supplied to the tool, stored under your own retention and access rules.
- 4
Policy and filter settings
The configuration in force when the output was produced, since indemnity conditions may depend on it.
- 5
Timestamp, user and repository
Who generated the output, where it was destined, and exactly when.
- 6
Output fingerprint and later changes
A hash of what was generated, and a record of subsequent modification so modified and unmodified output can be told apart.
Assess whether your current controls can produce this evidence
- Is each generation event recorded with tool identity, model version, timestamp, user and repository, and can those records be exported as evidence?
- Are records created in the execution path at generation time, or reconstructed later from commits and telemetry?
- Are prompt context and the policy or filter settings in force captured with each event?
- How are records protected against alteration, and what tamper-evidence mechanism is used?
- How are later edits, copy-paste and mixed human and AI content recorded?
- What false positive and false negative rates apply to any provenance or detection method, and how were they measured?
What an indemnity claim has to establish
Treat attribution as an evidence-engineering problem. The legal terms belong to counsel, and this guide is not legal advice. But whatever the wording of a specific vendor programme, a claim for a GPL-matching snippet generally rests on a chain of five links.
The first is the similarity match: a demonstrable overlap between the snippet and GPL-licensed source. The second is tool identification: showing that one particular assistant produced the output, not a human author, an open-source import or a different assistant. The third is interaction context, meaning the prompt, surrounding code, model version and user. The fourth is the set of conditions the vendor attaches to its indemnity, which may include whether filters were enabled and whether the output was used unmodified. The fifth is chain of custody: evidence that the records linking these elements are complete and unaltered.
The first link is a comparison exercise. The second through fifth are record-keeping problems. A similarity match says nothing about who or what wrote the code, and that gap is where most claims weaken.
Where attribution breaks down in common setups
Most regulated enterprises do not run one assistant. Developers use several AI coding tools alongside human authorship and imported open-source code. A commit records who committed a change, not which tool produced each line. IDE telemetry is usually partial and fragmented across tools. Vendor-side logs sit outside the enterprise's control, so their completeness, retention and format are not something the claimant can guarantee.
Copy-paste and editing make this worse. Once a developer pastes output from one assistant into a file, edits it, and merges it with other code, the origin of any given fragment is hard to recover. If an indemnity condition depends on unmodified output, the enterprise also needs a record of what was generated versus what was changed.
Detection after the fact does not close the gap. NIST's synthetic content work notes that patterns in text depend heavily on the prompt that produced it, and that mixing AI-generated and non-AI-generated text is relatively easy. One submission to NIST from the Computing Community Consortium goes further, giving the authors' opinion that consistent, accurate detection of AI-generated content is impossible. That is commentary, not a NIST finding, but the direction is consistent: inferring origin from the content alone is not a sound basis for a claim.
Why runtime evidence is stronger than reconstruction
NIST describes provenance data as a strong signal that affirmatively describes the history of content, and notes that provenance techniques can be added proactively during generation. Provenance detection only works if the data was recorded when the content was created. That is the core argument for capturing evidence in the path where code is produced, rather than assembling it from commits and vendor logs later.
Two further properties matter. First, tamper evidence: NIST points to tamper-proof histories and content authentication methods such as cryptographic signatures and digital fingerprints, and recommends measuring their reliability, including false positive and false negative rates. A claim built on records that could have been edited invites challenge. Second, absence can be informative. If every generation event is expected to produce a record, a snippet with no record is itself a finding to investigate.
There is also a baseline to keep in view. NIST's secure development profile for generative AI does not distinguish between human-written and AI-generated source code, because all code needs evaluation before use. That control is worth keeping, but it does not establish where a given snippet came from.
Trussed enforces policy in the execution path across coding assistants, with actions such as allow, redact and block, and provides code provenance covering the origin, licence and security context of code. The audit-ready evidence it produces is generated by enforcement at runtime, not reviewed after the fact. Whichever tooling you use, the design test is the same: the evidence should be a by-product of the control, not a separate reconstruction exercise.
The evidentiary chain from snippet to claim
Similarity match
The snippet is shown to match GPL-licensed source.
Tool identification
A specific assistant is tied to the output.
Interaction context
Prompt, model version, user and repository are recorded.
Policy conditions
Filter and policy settings in force at generation are known.
Chain of custody
Records are tamper-evident and cover later edits.
Check whether your evidence chain holds
Walk through how code provenance and audit-ready evidence are generated by policy enforcement in the execution path of your coding assistants.
See How Evidence Is ProducedHow does your AI governance program compare?
See where your program has gaps in less than 2 minutes.