September 21, 2026
You can learn to steer an AI agent for free: a 6-lesson course has arrived on VS Code Learn
Agent Foundations shows three levels of agent autonomy and lets you roll back its edits one by one. Every lesson includes text and video.

Visual Studio Code
@code
🤖 Building with an AI agent in the lead A detailed lesson is now available in our VS Code Learn library. @madebygps shows how to work effectively with AI agents in VS Code: agent workflows, rules and guardrails, debugging, execution environments, and hands-on app development. ▶️ https://youtu.be/K040jc0PQWI

· 26.6K views
An agent made ten edits to a file, and nine turned out to be correct. You can roll back the one bad edit with a button, without touching the rest.
VS Code has put these techniques into a free Agent Foundations course: 6 lessons on guiding an agent and checking its work. Every lesson has a text version and its own video.
Five pillars. The course breaks agent work down into harness, model, context, tools and prompt. In VS Code, the GitHub Copilot Chat panel is the harness, with three modes: Ask only talks, Plan waits for plan approval, and Agent works independently.
An approval picker controls autonomy, also across three levels. Default approvals asks for confirmation on calls, Bypass approvals runs tools without asking and stops on a blocking question, and Autopilot approves calls itself, retries errors and resolves blocking questions, which VS Code warns about when it is first enabled.
Edits do not make it into the code until they are accepted. A files changed bar appears above the input field, and every edit in the diff has its own Keep and Undo.
Every agent response serves as a checkpoint: Restore Checkpoint restores both the code and the conversation, without git stash. Fork starts a second session from the same checkpoint, while the first remains untouched.
The agent has gone in the wrong direction, but you do not need to stop it. Steer with message lets the current tool call finish and immediately gives it a new instruction, Stop and send cancels the request and starts again, and Add to queue puts a message in the queue. The docs recommend Steer.
Context usage is visible in the chat panel, and the indicator opens a live budget breakdown. When the window fills up, VS Code compresses the conversation automatically, while the /compact command does it manually and selectively.
A separate lesson covers where the agent runs. Local keeps it inside the editor with access to the workspace and terminal, Copilot moves it into a neighboring process on the same machine and runs several sessions in parallel, and Cloud sends it to GitHub infrastructure, where the agent commits and opens a pull request itself.
The Developer panel explains unclear behavior: Open Agent Debug Panel. It shows instruction and skill loading, tool calls and model requests, but logs live only until the editor is restarted.
What you need to start. VS Code with GitHub Copilot configured, plus Python 3.13 or later and the uv package manager for practice.
The path concludes with the sixth lesson: building a first application together with an agent.
* Meta Platforms Inc. is recognized in Russia as an extremist organization, and its activities are prohibited; Facebook and Instagram are blocked. Meta AI and other company products are products of this organization.
Source
