From 0cd720d7f60efdf7ac06b315bec5a5aa718c2406 Mon Sep 17 00:00:00 2001 From: Dscano Date: Tue, 10 Mar 2026 13:34:16 -0400 Subject: [PATCH 1/2] Add P4 Consortium Policy: AI Tool Use in Contribution Signed-off-by: Dscano --- AIPOLICY.md | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 AIPOLICY.md diff --git a/AIPOLICY.md b/AIPOLICY.md new file mode 100644 index 0000000..eb213a5 --- /dev/null +++ b/AIPOLICY.md @@ -0,0 +1,30 @@ +# P4 Project Policy: AI Tool Use in Contributions +The P4 Project permits the use of AI tools to assist with writing code and documentation. [Our approach follows the Linux Foundation’s Generative AI Guidance](https://www.linuxfoundation.org/legal/generative-ai) and adds organization-specific requirements. + +**Contributors remain fully accountable for their submissions** and are always the authors of their work. Review should be requested only when the contributor is confident the contribution is high quality and understands the code well enough to explain it.**In all cases, a human must remain in the loop.** + +This policy applies to all contribution types, including (but not limited to): +- code changes (PRs) +- RFCs/design proposals +- Issues or security reports +- Comments and feedback on pull requests + +# Contributor Responsibility +To ensure meaningful self-review and ownership, contributors should write PR descriptions themselves, AI tools may be used only for translation or copy-editing. PR descriptions must clearly cover the motivation, implementation approach, expected impact, and any open questions, to the same standard as non-AI contributions. First-time contributors who use AI tools must disclose that use in the PR description, commit message, or wherever authorship is normally indicated; long-time contributors and maintainers are exempt from mandatory disclosure but remain responsible for ensuring contributions comply with Linux Foundation and P4 community guidelines. A human must remain in the loop. Agents or automation may not take actions in project spaces, such as opening PRs, pushing commits, or posting review comments, without explicit human approval. + +**Contributors must avoid maintainer-burdening contributions**. In other words, submissions that offload excessive review work onto maintainers, for example, submitting unreviewed LLM output. The rule is simple: a contribution should deliver more value than the maintainer time required to review it. + +If a maintainer judges a submission to be non-compliant with this policy, they may request revisions, e.g., reducing scope or improving usefulness. In more serious cases, they may escalate to moderators/admins to lock the thread if it remains unproductive. + +# Intellectual Property and Licensing +Using AI tools does not remove copyright or change licensing obligations. You must ensure AI-assisted output does not include third-party copyrighted material or introduce license terms that are incompatible with the project. If there is any reasonable risk the output contains or reproduces third-party code or text, you must verify rights and license compatibility, add any required attribution/notices, or remove and replace the material before submitting it. + +Non-compliant contributions may be reverted or removed, just like any other licensing or copyright violation. + +# Examples: +- +- + +# References: +- LLVM AI Tool Use Policy: https://llvm.org/docs/AIToolPolicy.html +- Linux Foundation’s Generative AI Guidance: https://www.linuxfoundation.org/legal/generative-ai \ No newline at end of file From b962510f6b8dd69ce1330497cd90120f8b579ab7 Mon Sep 17 00:00:00 2001 From: Davide Scano Date: Sun, 15 Mar 2026 01:30:52 +0100 Subject: [PATCH 2/2] Example added Signed-off-by: Davide Scano --- AIPOLICY.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/AIPOLICY.md b/AIPOLICY.md index eb213a5..187df28 100644 --- a/AIPOLICY.md +++ b/AIPOLICY.md @@ -1,5 +1,5 @@ # P4 Project Policy: AI Tool Use in Contributions -The P4 Project permits the use of AI tools to assist with writing code and documentation. [Our approach follows the Linux Foundation’s Generative AI Guidance](https://www.linuxfoundation.org/legal/generative-ai) and adds organization-specific requirements. +The P4 Project permits the use of AI tools to assist with writing code and documentation. Our approach follows the [Linux Foundation’s Generative AI Guidance](https://www.linuxfoundation.org/legal/generative-ai) and adds organization-specific requirements. **Contributors remain fully accountable for their submissions** and are always the authors of their work. Review should be requested only when the contributor is confident the contribution is high quality and understands the code well enough to explain it.**In all cases, a human must remain in the loop.** @@ -22,9 +22,9 @@ Using AI tools does not remove copyright or change licensing obligations. You mu Non-compliant contributions may be reverted or removed, just like any other licensing or copyright violation. # Examples: -- +- This [PR](https://github.com/p4lang/gsoc/pull/98) demonstrates how humans stay in the loop when using agents or automation. - # References: - LLVM AI Tool Use Policy: https://llvm.org/docs/AIToolPolicy.html -- Linux Foundation’s Generative AI Guidance: https://www.linuxfoundation.org/legal/generative-ai \ No newline at end of file +- Linux Foundation’s Generative AI Guidance: https://www.linuxfoundation.org/legal/generative-ai