Skip to content

Document the AI agent attribution convention#2718

Merged
tatiana merged 1 commit into
claude-md-extract-agents-mdfrom
agents-md-no-coauthor-credit
May 22, 2026
Merged

Document the AI agent attribution convention#2718
tatiana merged 1 commit into
claude-md-extract-agents-mdfrom
agents-md-no-coauthor-credit

Conversation

@tatiana
Copy link
Copy Markdown
Collaborator

@tatiana tatiana commented May 21, 2026

Add a short "AI agent attribution" subsection to AGENTS.md: when a commit or PR is drafted with an AI coding agent, give the agent credit via a 🤖 Generated with … marker line rather than a Co-Authored-By trailer, so the GitHub contributor graph stays human-only.

Stacked on #2703 (which introduces AGENTS.md); GitHub will auto-retarget to main once #2703 merges.

🤖 Generated with Claude Code (https://claude.com/claude-code)

Add an "AI agent attribution" subsection under Commit Messages so the
preference is captured in the shared agent guidance:

* Do not add an AI coding agent as a ``Co-Authored-By`` trailer -- that
  trailer is for humans and shows up in GitHub's contributor graph and
  ``git shortlog -sn`` as if the agent were a person.
* Still give the agent credit, but via a plain marker line at the end of
  the commit body or PR description, e.g.
  ``🤖 Generated with Claude Code (https://claude.com/claude-code)``.

Living in AGENTS.md (not CLAUDE.md) so the rule applies to every agent
that reads the shared guidance, not just Claude.

🤖 Generated with Claude Code (https://claude.com/claude-code)
@tatiana tatiana requested review from a team, corsettigyg, dwreeves and jbandoro as code owners May 21, 2026 09:34
@tatiana tatiana requested review from pankajastro and pankajkoti and removed request for a team May 21, 2026 09:34
Copy link
Copy Markdown
Contributor

@pankajkoti pankajkoti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tatiana tatiana merged commit a77495e into claude-md-extract-agents-md May 22, 2026
3 checks passed
@tatiana tatiana deleted the agents-md-no-coauthor-credit branch May 22, 2026 11:20
tatiana added a commit that referenced this pull request May 27, 2026
Add a short "AI agent attribution" subsection to `AGENTS.md`: when a
commit or PR is drafted with an AI coding agent, give the agent credit
via a `🤖 Generated with …` marker line rather than a `Co-Authored-By`
trailer, so the GitHub contributor graph stays human-only.

Stacked on #2703 (which introduces `AGENTS.md`); GitHub will
auto-retarget to `main` once #2703 merges.

🤖 Generated with Claude Code (https://claude.com/claude-code)
tatiana added a commit that referenced this pull request May 27, 2026
Make the project's agent guidance reusable across AI coding tools:

- Move every agent-neutral section of `CLAUDE.md` (commands,
architecture, coding standards, commit-message format, documentation
style, etc.) into a new top-level `AGENTS.md`. The content is
byte-identical apart from the introductory paragraph, which is rewritten
in agent-neutral language and names `CLAUDE.md` as the canonical place
for Claude-only overrides.
- Slim `CLAUDE.md` to a small pointer that defers to `AGENTS.md`. The
pointer remains the file Claude Code reads on session start, but it no
longer duplicates project conventions. Claude-specific instructions can
accumulate there in the future without diverging from the shared
baseline.
- Document the AI-agent attribution convention (originally PR #2718,
since folded into this branch): give the assisting agent visible credit
via a trailing `🤖 Generated with …` marker, never via a `Co-Authored-By`
trailer (that surfaces in the GitHub contributor graph and `git
shortlog`, which should stay human-only).
- Add `AGENTS.md` to the `Check-changed-files` allowlist in
`.github/workflows/test.yml` so docs-only edits to `AGENTS.md` don't
trigger the full unit/integration matrix, mirroring how `CLAUDE.md` is
already handled.

This unlocks other agents — Cursor, Codex, Copilot, etc. — using the
same conventions Claude already does, without us maintaining parallel
copies.

## Review feedback addressed

- [x] Copilot: add `AGENTS.md` to the `Check-changed-files` allowlist in
`.github/workflows/test.yml` (mirrors the existing `CLAUDE.md` line).
- [x] Copilot: change British "behaviour" to American "behavior" in the
`AGENTS.md` intro paragraph for consistency with the rest of the
document.

## Rebased onto main

The original revision was stacked on `claude-md-require-precommit` (PR
#2702). #2702 has since squash-merged to main (commit
[`ea04d0da`](ea04d0d)),
so this branch has been rebased onto the current `main`. The redundant
pre-squash commits were dropped during rebase (`693c3d9c` identified as
"patch contents already upstream"; `f8a6bf03` skipped manually).

The companion attribution-convention PR #2718 has also been folded into
this branch since it built on top of `claude-md-extract-agents-md`.

## Test plan

- [x] `pre-commit run --files CLAUDE.md AGENTS.md
.github/workflows/test.yml` — all applicable hooks pass locally.
- [x] CI run on this PR — pre-commit.ci passes; the full
unit/integration matrix runs (because this PR touches
`.github/workflows/test.yml`, which is not — and should not be — on the
allowlist). Future docs-only `AGENTS.md` PRs will skip the matrix.

🤖 Generated with Claude Code (https://claude.com/claude-code)
@tatiana tatiana added this to the Cosmos 1.15.0 milestone May 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants