diff --git a/docs/contributing/ai_usage_guidelines.md b/docs/contributing/ai_usage_guidelines.md new file mode 100644 index 000000000000..b1420a610031 --- /dev/null +++ b/docs/contributing/ai_usage_guidelines.md @@ -0,0 +1,101 @@ + + + + + + +
+ +
+ + + +
+ +
+ + + +# Guidelines for Using AI in stdlib Contributions + +> Guidelines for using AI tools when contributing to the stdlib project. + +As described in the our [contributing guidelines][contributing-guide] and [code of conduct][code-of-conduct], the stdlib community values respectful, authentic, empathic engagement across all channels. +Artificial Intelligence (AI) and Large Language Models (LLMs) tools are rapidly evolving, and this _living document_ provides guidance on the appropriate use of such tools when contributing to stdlib. + +## Key Principles + +1. Maintainer capacity to review contributions is a finite, valuable resource. As such, _all_ contributions should strive to meet the rigorous guidelines and standards of the project. This will both maximize the chances of getting your pull request reviewed and merged, and minimize maintainer burden. +2. All contributions are bound by the project's [licensing terms][stdlib-license] (the Apache License, Version 2.0), and must adhere to the [Developer's Certificate of Origin][contributing-dco]. +3. Contributing to stdlib requires human judgement and understanding of the project's structure and conventions. Contributors should be able to explain the reasoning behind their changes, and ensure that they meet the project's standards. +4. If AI tools are used to assist with a contribution such that you're effectively copying and pasting or inserting output without changes, this must be **clearly disclosed**. Disclosure should include a description of how AI was used and what specific contributions it made. Include the AI tool used and the version (if applicable) in the git commit footer (per the [Conventional Commits footer spec][conventional-commits-spec]) using the tag `Assisted-by: ToolNamevX.X.X`. +5. Do not use AI tools to resolve issues marked as **"Good First Issue"**. These issues are intended to help newcomers learn about the project and gain experience with the mechanics of contributing. + +## Use Cases + +- Inline code-completions and suggestions. +- Boilerplate code generation. +- Learning about and exploring the codebase. +- Explaining code or concepts. +- Asking for suggestions or improvements (always using manual validation). +- Setting up test fixtures. +- Proofreading documentation or code comments. +- Code review _after_ manual implementation. + +## Dos and Don'ts + + + +## Attribution + +This document was inspired by and borrows heavily from: + +- [ASF Generative Tooling Guidance][asf-generative-tooling-guidance] +- [scikit-learn Automated Contributions Policy][scikit-learn-automated-contributions-policy] +- [matplotlib Restrictions on Generative AI Usage][matplotlib-restrictions-on-generative-ai-usage] +- Fedora Council's [AI-Assisted Contribution Policy][fedora-ai-contribution-policy] +- [OpenInfra Foundation Policy for AI Generated Content][openinfra-ai-policy] + + + +