Thoughts on disclosing AI usage through commits
Posted: | Tags: status softwareIn general, I’m in favour of disclosing AI-generated or assisted code in commits. In recent months, I’ve been seeing more and more of them across various open source repositories, and it’s a good indicator to me on how the project was developed and is being maintained. I want to actively avoid using, relying on, or contributing to repositories that are AI-generated or heavily AI-assisted.
Disclosing these tools, or at the very least mentioning they were used, in a commit message allows me to judge the work that was done. If the AI use is excessive, it’s a signal that any contributions I make would be insignificant to the overall project, or would be overrun by agents. It’s also a signal that the author might not care much for the project.
For example, I look for documentation or guides that are maintained by the community and are open source, as they’re sometimes more useful than what’s packaged with a service or tool. If I come across a guide written by AI, I know to immediately avoid it, even if it doesn’t have the obvious tell-tales of AI writing.
On the other hand, if the commit log shows a human is driving the project, making architectural decisions, and writing code with AI helping or authoring repetitive tasks, I’m generally okay with this. It’s hard enough to avoid LLM in day-to-day human communications sometimes, I don’t expect the codebase to be pristine.
Including Assisted-by or Co-authored-by keys in a commit message has precedence as git trailers long before it was used by AI. Git supports them, and so do many tools; parsing them is quite trivial. While it does work as somewhat of an advertisement to the vendor, simply stating that an LLM was used is enough for me. Akseli, the author of Stop advertising in your commits!, mentions that disclosing the tools in a merge request, if required, should be sufficient. But, I don’t feel that’s enough. Especially given that git trailers already exist and are parseable, shoving these details in a merge request would mean it’s probably lost.
While the exact model or vendor is not important, Xe makes a good point of why it might be:
Not only does this make it trivial for automation to detect when AI tools are being used (and add appropriate tagging so reviewers can be more particular), it lets you know which AI tools cause more issues in the longer run. This can help guide policy and assist contributors that want to use AI tooling into picking the best tools for the job.
Please keep tagging your commits, so I can decide what to avoid!
Update 2026-05-27: While reading the comments on lobste.rs to Akseli’s post I came across user hongminhee who makes a distinction between using Co-authored-by for humans and Assisted-by for AI tools. I like this.
They then reference the formatting used by the Linux kernel’s AI coding assistants guidelines:
Assisted-by: AGENT_NAME:MODEL_VERSION [TOOL1] [TOOL2]