Summary of "Reviewing and controlling agent changes | Ep 3 of 6 - VS Code Learn"
Episode 3 — Reviewing and controlling agent changes
Scope
This episode demonstrates how to steer, edit, review, fork, and restore work done by a VS Code “agent” (automated code assistant) while it edits files and runs tasks in your workspace. It provides a practical walkthrough covering:
- Changing a prompt and steering agent behavior mid-action
- Reviewing diffs and running generated code/tests
- Branching experiments via session forks
- Reverting unwanted changes via checkpoints
Key product features & UI elements shown
Edit a message / prompt
- Click a message to modify the agent’s instructions. This keeps a cleaner action history compared with many follow-up messages.
Steering agent actions
Options are available from a drop-down beside a message:
- Steer with message — sent at the agent’s next yield opportunity.
- Stop and send — stop the current action and send a message immediately.
- Add to queue — enqueue a message to run after the current request completes.
Change review UI
- After edits, a status/summary bar above the chat shows files changed and lines added/removed (example: “changes to 2 files, 78 lines added, 2 removed”).
- Options to accept changes:
- Keep all changes.
- Keep per profile.
- Open files and accept/reject individual changes (additions shown in green, removals in red).
- Ability to inspect and run generated code/examples immediately to verify behavior.
Session branching and checkpoints
- Fork session: use
/forkor the fork icon to create a new session that inherits history — useful for exploring alternate implementations (for example, keep a CLI session while experimenting with a FastAPI refactor in the fork). - Restore checkpoint: revert the workspace to a prior checkpoint to undo agent edits or the last request — useful when experiments produce unwanted changes.
Agent-run tasks and terminal
- Agents can execute tests and commands.
- You can view the agent’s hidden terminal and see test run output (for example, when an agent converted a CLI to FastAPI and updated tests).
Workflow tips
- Edit prompts to request specific changes (e.g., “input should be provided by a CLI argument”).
- Use steering to add follow-up tasks like “also add tests” while the agent is working.
- Use forks to parallelize exploration and checkpoints to safely experiment and roll back.
Tutorial / guide elements covered
- How to edit an agent prompt/message to change behavior.
- How to steer an agent mid-action (steer, stop & send, add to queue).
- How to review agent-made changes (summary, diffs, accept/reject at file or hunk level).
- How to run and verify generated code and tests.
- How to fork a session to explore alternate directions without losing the original.
- How to restore to a previous checkpoint to undo unwanted edits.
Takeaway / next steps
This episode covers practical control and review tools for safely iterating with agents: editing prompts, steering actions, accepting or undoing changes, forking sessions, and reverting via checkpoints. The next video will cover the session view for monitoring multiple sessions and ongoing work.
Main speaker / source
VS Code Learn instructor / demonstrator (narrator of the VS Code Learn episode).
Category
Technology
Share this summary
Is the summary off?
If you think the summary is inaccurate, you can reprocess it with the latest model.