diff --git a/docs/contributing.md b/docs/contributing.md index 7bc862a5be7..bf1969d3abe 100644 --- a/docs/contributing.md +++ b/docs/contributing.md @@ -19,6 +19,43 @@ again. In other words, the Google CLA is not scoped to a specific project. If you sign the Google CLA, it applies to other Google open-source projects as well (including future projects). +### Use of AI and LLM tools + +You are welcome to use generative AI and LLM tools ("AI") to help create +contributions as long as you review and edit what it produces to follow the +project guidelines. However, please do not use AI and agents to communicate with +the community, including Discord, issues, and pull requests. + +1. **You are the author.** AI is a tool you may use while creating a + contribution, but you are the author. If a substantial part of your + contribution is generated by AI, please disclose this by adding an + `Assisted-by` trailer at the end of the commit message. Examples: + + ``` + Assisted-by: Claude Opus 4.8 + Assisted-by: Kimi K3 + Assisted-by: GPT 5.6 Sol + ``` + +2. **You must understand what you are contributing.** If you do not understand + what AI has generated, please do not contribute it. If you would like help + understanding code that is already part of the project, please ask in Discord + or GitHub Discussions. + +3. **We want to talk to you, not your AI.** When communicating with the + community, do not paste the output from AI or allow an AI agent to post for you. + This includes, but is not limited to: + + - Creating pull requests and responding to feedback + - Creating or replying to GitHub issues + - Posting messages in Discord and GitHub Discussions + + Avoid using AI to generate commit messages. Writing the commit message + yourself ensures you understand and agree with what you're writing. + + It is acceptable to use AI to translate to English, but please also include + your writing in its original language. + ### Commit guidelines Unlike many GitHub projects (but like many VCS projects), we care more about the