diff --git a/AI-POLICY.md b/AI-POLICY.md new file mode 100644 index 000000000..d1d7e8bb8 --- /dev/null +++ b/AI-POLICY.md @@ -0,0 +1,116 @@ +# AI-assisted contributions policy + +This document defines how artificial intelligence (AI) and machine-assisted +tools may be used when contributing to Weston. It applies to all code, +documentation, and derivative works under the Weston project. + +AI tools can help with productivity, but they cannot replace understanding. +Contributors remain fully responsible for what they submit. The goals of this +policy are to preserve code quality, maintain license compliance, and ensure +that human accountability remains central. + +--- + +## 1. Scope + +This policy applies to all Weston contributions: +- Source code and headers +- Documentation and comments +- Commit messages, changelogs, and design notes +- Derived configuration or data files included in the repository + +The policy covers both human-written and AI-assisted material that becomes part +of the Weston source tree or its official documentation. + +--- + +## 2. Human responsibility + +- Each contributor is responsible for the correctness, clarity, and license + compliance of their work. +- AI tools may assist, but they do not author. The human submitting the change + must understand every part of it. +- Contributors must be able to explain the logic, intent, and expected behavior + of any code they contribute. + +Do not submit unverified AI output. Submissions that the author does not +understand will not be accepted. + +--- + +## 3. Disclosure of AI use + +If a contribution includes material generated or heavily assisted by AI, this +must be disclosed clearly in the commit message or merge request description. + +Use one or both of the following trailers: + +- AI-Assisted: yes +- AI-Tool: + +Minor or incidental AI use, such as spell checking or text reflow, does not +require disclosure. + +Disclosure is for transparency, not judgment. + +--- + +## 4. Review and maintainability + +- Reviewers treat AI-assisted changes like any other submission: they must be + correct, readable, maintainable, and consistent with Weston’s architecture. +- If the AI-generated content is unclear, unidiomatic, or hard to maintain, + it must be rewritten before acceptance. +- Code and documentation merged into Weston must remain understandable by humans. +- "AI said so" is not an acceptable justification for a design or implementation + decision. + +--- + +## 5. Licensing and origin + +Weston is licensed under the MIT License. + +All submitted content, including AI-assisted material, must be compatible with +the MIT license and must not include any restricted or incompatible material. + +AI tools may produce content resembling third-party sources. It is the +contributor's duty to ensure that no copyrighted or restricted code is copied +or derived. When in doubt, rewrite manually or omit the section. + +--- + +## 6. Weston data and model training + +Weston's source code, documentation, and related materials are licensed under +the MIT license. External parties using Weston data to train AI models must: + +- Respect the MIT license and attribution requirements. +- Avoid implying Weston's endorsement of any trained model. +- Provide clear provenance and licensing information for derived models. + +Aggressive scraping of Weston infrastructure is forbidden. Use official +mirrors or published tarballs when possible. + +--- + +## 7. Violations and corrections + +If a submission violates this policy (for example, undisclosed AI use or +license incompatibility): + +1. The maintainer may request clarification or rewriting. +2. The change may be rejected or reverted. +3. Repeated or intentional violations may affect contributor trust. + +--- + +### TL;DR + +- Humans decide; AI assists. +- Understand what you submit. +- Disclose significant AI help. +- Respect Weston (MIT) licensing. +- Keep Weston readable and maintainable. + +--- diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index dc58f1c0b..3e0f9e0a2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -26,6 +26,14 @@ Weston formerly accepted patches via `git-send-email`, sent to [tracked using Patchwork](https://patchwork.freedesktop.org/project/wayland/). New email patches are no longer accepted. +### AI-Policy + +Based on similar policies from +[Fedora](https://communityblog.fedoraproject.org/council-policy-proposal-policy-on-ai-assisted-contributions/) +and from [OpenInfra](https://openinfra.org/legal/ai-policy) Weston has a +dedicated [AI-policy](AI-POLICY.md) related to that. Please read that before +opening an MR. + Finding something to work on ----------------------------