From c137e5c4e61f1b375f782d617590b287cc1e0453 Mon Sep 17 00:00:00 2001 From: Mara Averick Date: Tue, 30 Dec 2025 09:56:53 -0700 Subject: [PATCH 1/3] docs: draft AI usage guidelines Refs: #9347 --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- docs/contributing/ai_usage_guidelines.md | 86 ++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 docs/contributing/ai_usage_guidelines.md diff --git a/docs/contributing/ai_usage_guidelines.md b/docs/contributing/ai_usage_guidelines.md new file mode 100644 index 000000000000..151bdbec04c9 --- /dev/null +++ b/docs/contributing/ai_usage_guidelines.md @@ -0,0 +1,86 @@ + + + + +# 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. + +## 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] + + + + From ac56511f0a1735bf8109339e122706fdb7a4eb5f Mon Sep 17 00:00:00 2001 From: Mara Averick Date: Wed, 7 Jan 2026 05:42:38 -0700 Subject: [PATCH 2/3] docs: add code review to use cases --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- docs/contributing/ai_usage_guidelines.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/contributing/ai_usage_guidelines.md b/docs/contributing/ai_usage_guidelines.md index 151bdbec04c9..11032f898aca 100644 --- a/docs/contributing/ai_usage_guidelines.md +++ b/docs/contributing/ai_usage_guidelines.md @@ -44,6 +44,7 @@ Artificial Intelligence (AI) and Large Language Models (LLMs) tools are rapidly - 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 From eb3bf4df2a72a5de357e862e37a08a4b6938fc47 Mon Sep 17 00:00:00 2001 From: Mara Averick Date: Wed, 7 Jan 2026 06:05:57 -0700 Subject: [PATCH 3/3] chore: update copyright year and add dummy sections --- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: passed - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: na - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: passed - task: lint_typescript_tests status: na - task: lint_license_headers status: passed --- --- docs/contributing/ai_usage_guidelines.md | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/docs/contributing/ai_usage_guidelines.md b/docs/contributing/ai_usage_guidelines.md index 11032f898aca..b1420a610031 100644 --- a/docs/contributing/ai_usage_guidelines.md +++ b/docs/contributing/ai_usage_guidelines.md @@ -2,7 +2,7 @@ @license Apache-2.0 -Copyright (c) 2025 The Stdlib Authors. +Copyright (c) 2026 The Stdlib Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -20,6 +20,20 @@ limitations under the License. + + +
+ +
+ + + +
+ +
+ + + # Guidelines for Using AI in stdlib Contributions > Guidelines for using AI tools when contributing to the stdlib project.