Agent-scoped Keep/Undo — unapply on close, restore on reopen

Feature request for product/service

Cursor IDE

Describe the request

It would be nice if each agent’s changes could be scoped by closing/opening each agent. I’ve had multiple agents doing things which creates a combined change set of undo/keep’s. If I decide I don’t want one of the agent’s changes for the moment, I could just close the agent and it’s changes would be removed. I could then process the other agent’s changes and maybe restore the closed agent’s changes at some point in the future. Also, I’ve run into where I’ve had agent changes and did not undo or keep them; change git branches, and these changes are still hanging around even though I’ve closed the agents. I just think the flows of multiple agent handling could work better.

Hey @Scott_Alden!

Thanks for the feedback. It trips me up as well when I’m working with multiple agents and the changes all end up on one branch.

Worktrees are one way of isolating changes between agents. Each agent gets its own Git checkout, so its edits never touch your main checkout or another agent’s. If you’re working in the Agents Window you can start one from there; in the IDE it’s /worktree <task>, with /apply-worktree to bring the result back and /delete-worktree to drop it.

It’s still not super intuitive, and I’m not sure Worktrees will be the final answer for workspace isolation for agents, but it’s worth trying if you haven’t tried them out!