Require AI agents to attribute their GitHub comments#1567
Conversation
gh posts comments as the authenticated user, making AI-generated review/issue comments indistinguishable from the human's own. Requiring a robot prefix keeps authorship transparent to reviewers. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Adds new guidance to the project’s AI instruction files to ensure AI-generated GitHub comments are clearly attributed, since gh posts as the authenticated user.
Changes:
- Adds a new PR guideline requiring AI attribution on GitHub comments in
CLAUDE.md. - Mirrors the same new PR guideline in
.github/copilot-instructions.mdto keep the instruction files in sync.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
CLAUDE.md |
Adds a PR guideline requiring attribution on AI-authored GitHub comments. |
.github/copilot-instructions.md |
Duplicates the same attribution guideline for Copilot instructions (kept in sync with CLAUDE.md). |
| - **On every push**, update the PR title and content to reflect the current diff — preserve any existing images/screenshots in the description | ||
| - **On every push**, update AI instruction files if the diff adds, removes, or renames anything tracked in AGENTS.md — specifically: Stimulus controllers, services, model/controller concerns, mailers, rake tasks, and directory file counts | ||
| - **On every push**, add PR review comments on notable lines of code — decisions, trade-offs, non-obvious logic, or anything a reviewer should understand. Use `gh api` to post line comments on the diff | ||
| - **Attribute every GitHub comment to Claude** — `gh` posts as the authenticated user (maebeale), so any comment you create (PR review comments, issue/PR comments, replies) MUST start with a 🤖 emoji and state it is from Claude. Begin the comment body with `🤖 _From Claude:_` followed by the content |
There was a problem hiding this comment.
🤖 From Claude: The maebeale reference is intentional, not a generic contributor guideline — this is a personal Conductor workspace where the gh CLI authenticates as that account, so AI-posted comments genuinely appear under it. The rule documents that specific fact so the attribution prefix is applied. On redundancy: the 🤖 _From Claude:_ prefix is the emoji requirement (the emoji opens the prefix), so it reads as one rule, not two. Leaving as-is.
There was a problem hiding this comment.
🤖 From Claude: The maebeale reference is intentional, not a generic contributor guideline — this is a personal Conductor workspace where the gh CLI authenticates as that account, so AI-posted comments genuinely appear under it. The rule documents that specific fact so the attribution prefix is applied. On redundancy: the 🤖 _From Claude:_ prefix is the emoji requirement (the emoji opens the prefix), so it reads as one rule, not two. Leaving as-is.
There was a problem hiding this comment.
🤖 From Claude: Also generalized the username — the rule now reads "posts as the authenticated user" with no hard-coded account, so it holds for any contributor. Pushed in 221ca17.
| - **On every push**, update the PR title and content to reflect the current diff — preserve any existing images/screenshots in the description | ||
| - **On every push**, update AI instruction files if the diff adds, removes, or renames anything tracked in AGENTS.md — specifically: Stimulus controllers, services, model/controller concerns, mailers, rake tasks, and directory file counts | ||
| - **On every push**, add PR review comments on notable lines of code — decisions, trade-offs, non-obvious logic, or anything a reviewer should understand. Use `gh api` to post line comments on the diff | ||
| - **Attribute every GitHub comment to Claude** — `gh` posts as the authenticated user (maebeale), so any comment you create (PR review comments, issue/PR comments, replies) MUST start with a 🤖 emoji and state it is from Claude. Begin the comment body with `🤖 _From Claude:_` followed by the content |
There was a problem hiding this comment.
🤖 From Claude: Fair flag, but this is deliberate. Per the project's own convention, CLAUDE.md and .github/copilot-instructions.md are kept byte-for-byte in sync, so the bullet is mirrored verbatim. The intent of the change is specifically to attribute Claude-authored comments (Claude is the agent operating in this workspace); it is not meant to be agent-agnostic. If Copilot were the one posting, the same transparency goal would call for a Copilot-specific prefix — but that is a separate decision the maintainer would make. Leaving the wording as requested.
There was a problem hiding this comment.
🤖 From Claude: Good call — updated. The bullet is now agent-agnostic in both files: 🤖 _From <agent>:_ (e.g. 🤖 _From Claude:_ or 🤖 _From Copilot:_), so it stays correct whichever AI authors the comment. Pushed in bdbc25b.
Per review, the Copilot-facing instruction file should not hard-code "Claude" attribution. A generic prefix keeps both files correct for whichever agent authors the comment. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Drops the hard-coded username so the guidance reads correctly for any contributor whose gh account posts the comment. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Verbose AI comments add noise to PR threads; a brevity rule keeps them scannable and pushes longer context into the PR description. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Closes [link an issue or remove this line]
What is the goal of this PR and why is this important?
ghposts comments as the authenticated user, so AI-generated PR/issue comments are indistinguishable from the human's own — this adds a rule requiring the AI agent to clearly attribute its comments.How did you approach the change?
CLAUDE.mdand.github/copilot-instructions.md, kept in sync) requiring every GitHub comment an AI creates to start with an agent-agnostic🤖 _From <agent>:_prefix (e.g.🤖 _From Claude:_,🤖 _From Copilot:_).UI Testing Checklist
Anything else to add?