When AI assistants make code changes on your behalf, proper attribution is essential. Modern AI coding agents like Claude Code and OpenCode now automatically add themselves as co-authors when they create commits - you don't need to configure anything.
However, you should still add yourself as a co-author to indicate that you reviewed and approved the AI's work.
| Tool | Default Behavior | Co-Author Format |
| Claude Code | ✅ Auto-adds co-author | Co-Authored-By: Claude <model> <noreply@anthropic.com> |
| OpenCode | ✅ Auto-adds attribution | Adds model as co-author |
| GitHub Copilot | ❌ No auto-attribution | Requires manual setup |
| Cursor | ❌ No auto-attribution | Requires manual setup |
TODO: Add screenshot of GitHub commit showing Claude as co-author
When working with AI agents on larger tasks, ask them to create commits in a logical order that "tells a story" of the implementation. This makes code reviews easier and helps future developers understand the evolution of a feature.
Prompt tip: When asking an AI agent to implement a feature with multiple components, include:
"Please commit changes in a logical order that tells a story - for example, data models first, then business logic, then UI components, and finally tests."
Example story-driven commit sequence:
feat: Add User database model and migrations - Foundation firstfeat: Implement user authentication service - Core logicfeat: Add login and registration API endpoints - Interface layerfeat: Create login form component - UI implementationtest: Add authentication unit and integration tests - VerificationThe standard Git co-author format:
git commit -m "feat: Add recipe search functionalityCo-authored-by: Your Name <your.email@example.com>"
To find your details, run: git config user.name and git config user.email
✅ DO add yourself when:
❌ DON'T add yourself for: