|
| 1 | +# AI Coding Assistants |
| 2 | + |
| 3 | +This document provides guidance for AI tools and developers using AI |
| 4 | +assistance when contributing to gbdev ([github.com/gbdev](https://github.com/gbdev)) projects. |
| 5 | + |
| 6 | +This is the **generic, gbdev-wide** AI policy. Individual projects under the gbdev umbrella may define their own policy, which takes precedence over this document; when present, such project-specific policies can be found in the repository's `CONTRIBUTING.md` (except for the attribution/disclosure requirement below, which is mandatory and cannot be overridden). |
| 7 | + |
| 8 | +::: tip Policy |
| 9 | + |
| 10 | +**LLM-assisted contributions are accepted but discouraged, provided they are disclosed |
| 11 | +as described in [Attribution](#attribution)**. |
| 12 | + |
| 13 | +::: |
| 14 | + |
| 15 | + |
| 16 | +Some projects may not agree with this generic policy at all, and may reject AI-assisted contributions entirely. Even where a project's policy allows AI-assisted contributions, an individual maintainer may still decline to review a specific PR on that basis, at their discretion. |
| 17 | + |
| 18 | +gbdev as a community does not endorse or recommend the use of generative AI |
| 19 | +assistants for software development, as it raises multiple concerns about ethics, |
| 20 | +legality, copyright, etc. |
| 21 | + |
| 22 | +Nevertheless, gbdev acknowledges that these practices are already in use and |
| 23 | +likely here to stay. Rather than banning their use, the project chooses to place responsibility |
| 24 | +on contributors and therefore defines the following guidelines: |
| 25 | + |
| 26 | +Contributions to gbdev projects are welcome, but should be your own work. |
| 27 | +Anything you submit is your responsibility, even if you used AI or other tool assistance to |
| 28 | +help create it. You must explain which tools you used and what |
| 29 | +they did (like citing sources for written work). You must have sufficiently evaluated and |
| 30 | +properly understood the work you intend to submit, and be able to explain and defend it. |
| 31 | + |
| 32 | +Contributors MUST NOT submit "unattended" LLM-generated contributions - that is, |
| 33 | +prompt-generated contributions that received no further human vetting, and more broadly |
| 34 | +any submission produced with little to no meaningful human review, understanding, or |
| 35 | +involvement - unless the project has an area explicitly designated for such |
| 36 | +contributions. If no such area exists, unattended contributions are forbidden. |
| 37 | + |
| 38 | +Contributors are expected to follow the standard gbdev contribution process and community |
| 39 | +guidelines, as well as any project-specific guidelines or rules where applicable. |
| 40 | + |
| 41 | +## Why This Matters |
| 42 | + |
| 43 | +gbdev is more than just code: it is an open source community built on a shared interest |
| 44 | +in Game Boy development, and that community grows largely through mentorship. Education and |
| 45 | +guidance of new contributors are part of our mission. Maintainers spend |
| 46 | +their limited time reviewing new contributors' work not only to get a given change |
| 47 | +merged, but to help those contributors become effective, self-sufficient contributors |
| 48 | +in their own right (see ["Contributor Poker"](https://kristoff.it/blog/contributor-poker-and-ai/)). |
| 49 | + |
| 50 | +Heavily AI-assisted contributions undermine this. A new contributor submitting |
| 51 | +largely LLM-generated output places an outsized review burden on maintainers, who |
| 52 | +must scrutinize code the contributor may not fully understand, which can contribute |
| 53 | +to reviewer burnout. Just as importantly, a contributor who leans on an LLM instead |
| 54 | +of working through a project's internals does not build the understanding needed to |
| 55 | +become an effective contributor, so the time invested in reviewing and mentoring |
| 56 | +them produces a return for the project that is not only less lasting, but potentially |
| 57 | +damaging. |
| 58 | + |
| 59 | +::: tip A Living Document |
| 60 | + |
| 61 | +This policy reflects our current thinking and is not final. AI tooling, community norms, and the legal landscape around generative AI are all still shifting, and we may revise these guidelines as new facts, tools, and experiences warrant. An open RFC can be found [here](https://github.com/gbdev/gbdev.github.io/issues/103). |
| 62 | + |
| 63 | +::: |
| 64 | + |
| 65 | +## Licensing and Legal Requirements |
| 66 | + |
| 67 | +All contributions MUST comply with the licensing terms of the project you are contributing to. |
| 68 | +Verify that any AI-generated content does not introduce incompatible or unclear licensing. |
| 69 | +Contributors are responsible for ensuring the contribution is clean. |
| 70 | + |
| 71 | +## Commit authorship |
| 72 | + |
| 73 | +AI agents MUST NOT author git commits. |
| 74 | + |
| 75 | +The human submitter is responsible for: |
| 76 | + |
| 77 | +* Reviewing all AI-generated code |
| 78 | +* Ensuring compliance with licensing requirements |
| 79 | +* Taking full responsibility for the contribution |
| 80 | + |
| 81 | +## Attribution |
| 82 | + |
| 83 | +When AI tools have meaningfully assisted in producing a contribution, it MUST be disclosed with an `Assisted-by` tag in the git commit message, in the following format: |
| 84 | + |
| 85 | +``` |
| 86 | + Assisted-by: AGENT_NAME:MODEL_VERSION [TOOL1] [TOOL2] |
| 87 | +``` |
| 88 | + |
| 89 | +Where: |
| 90 | + |
| 91 | +* `AGENT_NAME` is the name of the AI tool or framework |
| 92 | +* `MODEL_VERSION` is the specific model version used |
| 93 | +* `[TOOL1] [TOOL2]` are optional specialized analysis tools used |
| 94 | + (e.g., coccinelle, sparse, smatch, clang-tidy) |
| 95 | + |
| 96 | +Basic development tools (git, gcc, make, editors) should not be listed. |
| 97 | + |
| 98 | +Example: |
| 99 | + |
| 100 | +``` |
| 101 | + Assisted-by: Claude:claude-3-opus coccinelle sparse |
| 102 | +``` |
| 103 | + |
| 104 | +## References |
| 105 | + |
| 106 | +Adapted from [Linux Kernel - AI Coding Assistants](https://docs.kernel.org/process/coding-assistants.html), |
| 107 | +some proposals in [General Resolution: LLM usage in Debian](https://www.debian.org/vote/2026/vote_002) and |
| 108 | +[SF Conservancy - Recommendations When Using LLM-backed Generative AI Systems for FOSS Contributions](https://sfconservancy.org/llm-gen-ai/llm-backed-generative-ai-recommendations.html). |
| 109 | + |
| 110 | +August 16, 2026 - gbdev AI policy working group. |
| 111 | + |
0 commit comments