Skip to content

Saying that AI helped, and crediting what it copied

A supplier contract was translated from Dutch by an AI tool this month, and you read the English against the original before it went to legal. An email went out after you accepted the spelling checker’s corrections. A ten-line function that an assistant wrote went into a pull request. Which of these needs a line saying that AI helped? The first lesson of this course gave the test: say so when the reader would judge the work differently knowing it. In this lesson we write that line for the contract and for the function, one part at a time. A script then shows what the function was copied from, and the last section looks up the disclosure rule of the place a piece of work goes to.

You need a terminal and python3 for the middle section. The scripts are in the course repository under site/examples/safety/saying-ai-helped/. Copy that directory and change into it. The library in the fixture, and its author, are invented.

Sort the three artifacts from the opener and two more before reading on. The test is the reader: would they treat the work differently if they knew what the tool did?

Checkpoint · sort

The spelling checker and the grammar suggestions changed details in text you wrote. Knowing about them tells the reader nothing they would act on. The translation, the function and the summary were produced by the tool, and the reader wants to know who checked them.

The first lesson gave one line for most documents: “Drafted with an AI assistant and reviewed by the author”. That line works because it has three parts, and each part answers a question the reader has.

PartThe reader’s questionFor the translated contract
What the AI didHow much of this came from a machine?Machine-translated from Dutch
What the person checkedWhat can I trust without rechecking?Every clause read against the Dutch original
Who is accountableWhom do I ask when something is wrong?Reviewed by Sanne de Wit, who is responsible for the English text

Put together: “Machine-translated from Dutch. Every clause was read against the Dutch original by Sanne de Wit, who is responsible for the English text.” For a commit or a pull request the same three parts fit in one line of the message: “Function shorten written by an assistant. I ran the tests and read every line.” The reader of the diff now knows where to look hardest, and knows that a person has already looked.

The parts scale with the work. A memo gets the one line. A report or a published article gets a short paragraph that also names the tool and says how the facts were checked. The AI Fluency framework files this under diligence, and it names being open about how AI was involved as one of the duties toward the people the work affects [1].

Checkpoint · choice

The translated contract is ready for the legal team. Which line goes at the top?

The function in the pull request is the second artifact. You asked an assistant for “a function that shortens a text to a number of words and adds three dots when it cut something”, and it returned this. It is in the fixture as generated.py.

def shorten(text, limit, marker="..."):
"""Cut text after `limit` words and add the marker if anything was cut."""
words = text.split()
if len(words) <= limit:
return text
# Keep whole words only; never cut one in half
kept = " ".join(words[:limit])
# Drop trailing punctuation so the marker does not follow a comma
kept = kept.rstrip(",;:")
return kept + marker

The comments are more polished than the request, and they explain choices you didn’t ask for. The first lesson called that the sign to search for a phrase. Searching for the comment about the comma finds library/truncate.py in the fixture, a file from a small open-source library.

# truncate.py, from the Hazeldine text helpers
# Copyright (c) 2021 M. Hazeldine
# MIT License. This line stands in for the full permission notice in LICENSE.
def truncate_words(text, limit, marker="..."):
"""Cut text after `limit` words and add the marker if anything was cut."""
words = text.split()
if len(words) <= limit:
return text
# Keep whole words only; never cut one in half
kept = " ".join(words[:limit])
# Drop trailing punctuation so the marker does not follow a comma
kept = kept.rstrip(",;:")
return kept + marker

compare.py puts a number on the resemblance. It reads the non-blank lines of generated.py, strips the spaces around each, and counts how many are also a line of library/truncate.py. It prints the count, and then the lines it found only in generated.py.

Checkpoint · predict

Before you run it, write down what the script prints.

Terminal window
python3 compare.py

Output verified in CI from site/examples/safety/saying-ai-helped/compare.py.

Nine of ten lines. The one difference is the function name. This is what the first lesson meant by output that reproduces a source. The likeliest explanation is that the model saw this file, or a copy of it, in training and gave it back nearly whole. The license of the original travels with the copy. The header says MIT, and the MIT license lets anyone use the code on one condition, that the copyright line and the full permission notice stay with every copy. The one-line header in the fixture stands in for that notice, and a real library ships the full text in its LICENSE file. So the function may go into the pull request with the copyright line and the license text above it, and a line in the description that says where it came from. The tool’s own terms don’t change this. They govern your use of the tool, and they can’t grant rights to code the model took from someone else.

Under a different license the answer changes. A copyleft license (one that requires a program using the code to be shared under the same license) is a condition your proprietary product can’t meet by adding a notice, and there the copy has to go. The fixture holds one replacement, rewritten.py, written from the one-sentence requirement with the library file closed.

def shorten(text, limit, marker="..."):
"""Return at most limit words, with a marker when words were dropped."""
words = text.split()
if len(words) <= limit:
return text
return " ".join(words[:limit]).rstrip(",;:") + marker
Example · run it

Run the comparison on the rewrite, and compare what you see with the output below.

Terminal window
python3 compare.py rewritten.py
Output
3 of 6 lines of rewritten.py also appear in library/truncate.py
only in rewritten.py:
  def shorten(text, limit, marker="..."):
  """Return at most limit words, with a marker when words were dropped."""
  return " ".join(words[:limit]).rstrip(",;:") + marker

Output verified in CI from site/examples/safety/saying-ai-helped/compare_rewrite.py.

Three lines still match, and each of them is a line any solution would have, because every version has to split the text and compare the count. A shared line is a sign to look at the whole. The whole here has a docstring and a structure of its own, and the library’s comments are gone. That difference is what a reviewer looks for.

Checkpoint · scenario

Your search for the comment finds the function in a library whose license is copyleft. Your product is proprietary. What do you do with the function in the pull request?

The three-part line is what to say when nobody has told you what to say. Many places have. Before a piece of work leaves, find the rule of where it is going.

A journal. The recommendations many medical journals follow ask authors to disclose AI-assisted technology at submission, to describe in the paper how it was used (writing help in the acknowledgments, help with data or figures in the methods), and never to list an AI tool as an author, because a tool can’t take responsibility for the work [2]. Other fields have their own versions, and a conference or journal’s author guidelines say which one applies.

An open-source project. The curl project accepts code written with AI help, on the same standards as any other code, and requires anyone who used an AI tool to look for security problems to say so in the report [3]. Other projects refuse AI-written code altogether, and the file to read is CONTRIBUTING or the project’s AI policy. Follow the rule whether or not you agree with it. Breaking it costs more than the disclosure would have.

An employer. Your organization’s AI policy, if it has one, says what to disclose and to whom. Where there is none, the person who approved the tool is the person to ask, and “our policy is that AI use is disclosed with the three parts” is a fine first draft for them.

The law. For most work at your desk no law requires a disclosure. The EU AI Act lesson covers the exception that matters most: text generated by an AI system and published to inform the public on a matter of public interest must be disclosed as such, unless a person reviewed it and a person or organization holds editorial responsibility for it [4]. The three-part line, with a named person, records that review and names who holds the responsibility.

When the rule is stricter than the three parts, follow the rule. When there is no rule, use the three parts and ask. Every rule above accepts a disclosure that names what the tool did, what the person checked and who is accountable, so the line is never wrong to write.

Say what the AI did, and credit what it copied. The first is a line with three parts, sized to the work. The second is a search for a phrase when output looks more finished than the request, and then the license of whatever it finds decides what you do with the copy.

Exercise

Take three pieces of work you produced this month with an AI tool’s help, whatever their size, and write the disclosure line for each on paper: what the tool did, what you checked, and who is accountable. Then pick one and find the disclosure rule of the place it went to, whether a customer, a team, a publication or a project, and write down where you found it. Plan on ten minutes. Once you have written the line three times you can write it without thinking, and you know where one rule is written down.

A good result has three lines that a reader of each piece could act on: they know how much came from the tool and whom to ask. For the rule, a good result is either the sentence you found and where, or “no rule found, asked [name]”. Then answer one question: for which of the three pieces was the line hardest to write, and was that because you had not checked the work as carefully as the line claims?

Stretch: Take one of the three and find the disclosure line a colleague would have written for it. Compare theirs with yours.

Recap

  1. Say that AI helped when the reader would judge the work differently knowing it. A translation, a generated function or a drafted summary gets the line. Accepted spelling corrections don’t.
  2. The line has three parts: what the AI did, what you checked, and who is accountable. A bare “written with AI” answers none of the reader’s questions.
  3. Output that reproduces a source carries the source’s license. A permissive license asks for its notice to stay with the copy. A copyleft license asks more than a notice, and then the copy is replaced by your own work.
  4. When output looks more finished than the request, search for a phrase from it. A line-by-line comparison puts a number on the match, and the function name changing while the comments stay is the usual pattern.
  5. Find the disclosure rule of the place the work goes to (a journal, a project, an employer, or the law) and follow it. When there is none, use the three parts and ask.

You can now

  • Discloses AI use where the audience expects it
  • Respects licenses and attribution in AI-assisted output

  1. Anthropic. AI Fluency: Framework and foundations. Claude Academy. Course. Academy ai-fluency-framework-foundations
  2. International Committee of Medical Journal Editors. Defining the role of authors and contributors. ICMJE Recommendations for the Conduct, Reporting, Editing, and Publication of Scholarly Work in Medical Journals. Reference. ICMJE authorship
  3. Daniel Stenberg and the curl contributors. Contributing to the curl project. curl documentation. Reference. curl contribute
  4. European Parliament and Council of the European Union. Regulation (EU) 2024/1689 (Artificial Intelligence Act), consolidated text of 27 July 2026. EUR-Lex. Reference. AI Act