Version control
Git branch
A parallel copy of your code where you can make changes without touching the working version.
A branch lets you build a feature or try a risky idea in isolation, then merge it back into the main line once it works — like editing a copy of a document instead of the original. You might keep `main` as the live version and do the AI's mid-refactor on an `add-checkout` branch. This is your undo button at project scale: if the changes go sideways, you throw the branch away and `main` is completely untouched.