answered from live GitHub & Hugging Face data

How do I use commit trailers like Assisted-by for code contributions from AI coding agents like Codex?

MaintMaintained · 5mo ago
Stars2
Issues0 open
MaintMaintained · 2mo ago
Stars0
Issues0 open
MaintActive · 3d ago
Stars0
Issues0 open

Use a plain Assisted-by: trailer to disclose agent help, and never add Signed-off-by for the agent. Only the human adds that line.

The real question is how to label agent-written commits without breaking the kernel's sign-off rules. The steps below cover both.

What the rules say

How trailers work in git

Git reads a trailer as a key: value line in the final block of the message. That block must follow a blank line (git-interpret-trailers).

Steps

  1. Write the commit subject and body first.
  2. Leave one blank line before the trailer block.
  3. Add the trailer. Name the agent and the work type. For example: Assisted-by: <model> (code generation).
  4. Review the code yourself. Then add your own Signed-off-by line.
  5. Check the result with git log -1 --format=%B.

To add the trailer with git's own tool, run:

git interpret-trailers --trailer "Assisted-by: <model> (code generation)" --in-place msg.txt

GitHub co-author lines

Co-authored-by is a different feature. It credits a person, and it counts toward that person's contribution graph only if the email is linked to their GitHub account (GitHub Docs). Do not use it to mark agent help unless your project asks for it.

Helper tools

I checked four small projects. None has broad adoption. Star counts come from search results.

Project Stars Last push License Verdict
bcmyguest/assisted-by 2 148 days ago NOASSERTION ⚠️ Enforces kernel-style trailers. Covers Codex.
rokokol/ai-commit-trailers-skill 0 49 days ago MIT ⚠️ Adds Assisted-by and Generated-by.
franks-ai-skills/assisted-by-trailers 0 3 days ago AGPL-3.0 ✅ Newest. Its description uses the Assisted-by: <model> (code generation|code review) form.
JordanNewell/assisted-by 0 4 days ago MIT ✅ A commit hook that rewrites vendor trailers into one Assisted-by: line.

I could not load full metadata for the first two because of a rate limit. Their maintenance status comes from search results only.

Recommendation

Use plain git. A single git interpret-trailers command does the job, with no dependency. Add a helper only if you need automatic enforcement across many agents.

If you run agents that push to GitHub, githug gives each agent its own key. Its commits name the accountable human, the agent and the run in trailers. Its Co-authored-by line for the human is opt-in and off by default.

docs.kernel.org/process/coding-assistants.htmlgit-scm.com/docs/git-interpret-trailersdocs.github.com/en/pull-requests/committing-changes-to-your-project/creating-and-editing-commits/creating-a-commit-with-multiple-authorsgithub.com/bcmyguest/assisted-bygithub.com/rokokol/ai-commit-trailers-skillgithub.com/franks-ai-skills/assisted-by-trailersgithub.com/quanxinwang18-a11y/pi-git-attributiongithub.com/JordanNewell/assisted-bydocs.kernel.org/process/submitting-patches.html
Answered live from GitHub & Hugging Face · anthropic/claude-haiku-5.5 · 11/11/2026

Ask your own open-source question →