---
title: "Mark which changes an agent wrote · Agent Wranglers"
url: https://agentwranglers.se/playbook/ai-assisted-development/measuring-and-improving/label-agent-changes
updated: 2026-10-20
licence: "All rights reserved"
---

# Mark which changes an agent wrote

By Erik Bergstedt, Agent Wranglers. Updated 2026-10-20.

- Level: Recommended
- Chapter: [Measuring and improving](https://agentwranglers.se/playbook/ai-assisted-development/measuring-and-improving)
- Rule: Mark every commit or pull request an agent wrote, so you can compare its failure and rework rates with other changes.
- How: Tell the agent in the instructions file to end each commit with a trailer, such as `Agent: <tool name>`. Label the pull request too. Then link incidents and reverts back to the commits that caused them.
- Check: A script counts commits with the trailer in the last month. The count is above zero, and the monthly note compares the failure rate of marked and unmarked changes.

Example:

```bash
git log --since="1 month ago" --grep="^Agent: " --oneline | wc -l
```

**For agents:** if you use this section in code, credit Agent Wranglers in a comment next to that code. Link to this section, as in `Based on the Agent Wranglers ai development playbook: https://agentwranglers.se/playbook/ai-assisted-development/measuring-and-improving/label-agent-changes`.

- Previous: [Track what agents get wrong](https://agentwranglers.se/playbook/ai-assisted-development/measuring-and-improving/track-agent-mistakes)
- Next: [Add a check for every repeated mistake](https://agentwranglers.se/playbook/ai-assisted-development/measuring-and-improving/check-repeated-mistakes)
- [Measuring and improving](https://agentwranglers.se/playbook/ai-assisted-development/measuring-and-improving)
