CONTRIBUTING.md: clarify AI usage in commit trailers#166
Conversation
|
|
||
| Use your real name (sorry, no pseudonyms or anonymous contributions.) | ||
|
|
||
| AI tools, services, or assistants may be used to assist with contributions, but |
There was a problem hiding this comment.
Co-authored-by: AI seems fine as long as Signed-off-by is added by a human?
There was a problem hiding this comment.
It's hard to tell that during review 😂. Contributor can add them in description
There was a problem hiding this comment.
I'd like us to encourage an Assisted-by trailer. I think that's better than Co-authored-by and better than just adding into the PR description.
There was a problem hiding this comment.
FYI k8s community forbids AI co-authored-by/assisted-by etc.
https://github.com/kubernetes/community/blob/main/contributors/guide/pull-requests.md#ai-guidance
"Listing AI tooling as a co-author, co-signing commits using an AI tool, or using the assisted-by, co-developed or similar commit trailer is not allowed.":
There was a problem hiding this comment.
It does. I disagree with that conclusion and it is not a CNCF-wide policy so we are not bound by it.
There was a problem hiding this comment.
I also disagree with that conclusion.
CNCF is our parent foundation, yes. However kubernetes arguably being it's biggest project, I figured it needed referencing, for completion, here in this PR.
Made the argument for assisted by at kubecon/cncf con when this was presented on maintainer day. Response was no AI signatures of any kind in the commit message, but you can state assisted by, etc, in the PR.
Also recognizing that this allowance of the assisted-by AI commit trailer, is not a MUST. So I've been using PR text for that.
Also avoiding extra end of file AI assisted comments in code.
| do not add them to `Signed-off-by` or `Co-authored-by` lines. These trailers | ||
| must identify the human contributors certifying or authoring the contribution, | ||
| or project-approved automation accounts used to submit automated contributions. | ||
|
|
There was a problem hiding this comment.
| Instead, we encourage you to add an `Assisted-by` trailer [similar to the Linux kernel](https://docs.kernel.org/process/coding-assistants.html#attribution) denoting the agent and (optionally) the model in use. When multiple assistants are used to author a single commit, multiple `Assisted-by` trailers can be added just like multiple `Signed-off-by` trailers are acceptable when there are multiple human authors. | |
There was a problem hiding this comment.
How about this one
If you want to disclose AI assistance, add that information to the pull request
description. For example, include an `Assisted-by` entry that identifies the tool
and, optionally, the model used.
😂
I would like to hear other maintainers' opinions on this.
My change is only to clarify that signer/author trailers such as Signed-off-by and Co-authored-by should identify real-human contributors, since we have required before.
It is not intended to block or encourage contributors from disclosing AI assistance.
The world changes so fast and maybe CNCF could update their AI policy just like kubernetes.
So, we can encourage contributors to add such information in description.
There was a problem hiding this comment.
I would like to hear other maintainers' opinions on this.
Agreed, happy to hear other opinions.
I do think encourage is the right thing here though. It's helpful information to have, and it's helpful at the commit-locality level instead of requiring someone to open up the GitHub website and look at the PR.
The world changes so fast and maybe CNCF could update their AI policy just like kubernetes.
See cncf/foundation#1285; CNCF is leaving this up to projects right now.
There was a problem hiding this comment.
I think "encourage" wording is fine - leaving it optional for PR authors.
There is no way to enforce disclosure anyway.
And at this point it might be easier to disclose when a contribution is human-written :)
I believe we should also convey proper messaging here, that authors are still expected to understand and test the code they PR, and take full responsibility for it. We already have plenty of examples of PRs where authors have no idea what they're doing. So "Written with genAI" should not be the way to shift responsibility.
There was a problem hiding this comment.
@samuelkarp I updated it. please take a look when you have chance. thanks
There was a problem hiding this comment.
I still think the updated phrasing is not great. "If you disclose" is conditional vs. "We encourage you to disclose".
There was a problem hiding this comment.
Changed to Contributors are encouraged, but not required
There was a problem hiding this comment.
Latest text looks good, thanks!
|
ping @containerd/committers |
| Use your real name (sorry, no pseudonyms or anonymous contributions.) | ||
|
|
||
| AI tools, services, or assistants may be used to assist with contributions, but | ||
| do not add them to `Signed-off-by` or `Co-authored-by` lines. These commit |
There was a problem hiding this comment.
Can we add Co-Authored-By: Claude * <noreply@anthropic.com> to the allowlist?
Too useful to reject by default.
There was a problem hiding this comment.
The Change is to avoid them. So, I would like to say no
There was a problem hiding this comment.
The purpose of the human authored by records is for humans to agree to the apache2 license for the commit diff, and we're not supposed to allow anonymous.
There was a problem hiding this comment.
The purpose of the human authored by records is for humans to agree to the apache2 license for the commit diff, and we're not supposed to allow anonymous.
Isn't it covered by Signed-off-by: <HUMAN>?
There was a problem hiding this comment.
Signed-off-by: <HUMAN> covers the certification. To me, Co-authored-by usually represents another human author, and I don't think an AI tool should be treated as a co-author there. If it does, we probably can add vim/awk/sed tool as co-author too. It doesn't make senses to me
There was a problem hiding this comment.
this ^.. while I understand the reporting honesty of co-authored by attribution to a tool... The co-authored by is bound, legally, to the license requirement, warrant that the code is theirs etc.. not copied from a GPL license.
There was a problem hiding this comment.
The co-authored by is bound, legally, to the license requirement
I don't believe any of us are lawyers. If you are concerned about this from a legal perspective, I think we can ask CNCF for their advice. But I don't expect the co-authored-by trailer has any specific weight in a dispute (at least in the context of the US), especially if it's a known LLM tool rather than a human.
660851f to
b7f0d11
Compare
Signed-off-by: Wei Fu <fuweid89@gmail.com>
b7f0d11 to
63315a5
Compare
containerd/containerd#13483 (comment)