Refer to the exhibit. What is the most effective way to address the agent's modification of build artifacts?
Updating the .claudeignore file is the standard configuration fix for this issue. It prevents the agent from seeing or touching these files in future tasks. Reverting the changes via Git ensures the repository returns to a clean state, correcting the mistake effectively and efficiently.
Why this answer
The correct approach is to stop the agent, exclude the build artifacts via .claudeignore, and revert the changes to those specific files using Git. This protects the integrity of the build process and ensures the agent stays focused on source code. By teaching the agent to respect these boundaries, you optimize future task performance and prevent similar errors in subsequent automated refactoring steps.
Exam trap
Candidates often try to manually delete build artifacts without updating configuration. This causes the agent to recreate them, leading to a loop of unnecessary modifications and wasted compute resources.