Orchestrating Multiple AI Agents in VS Code
AI Engineergo watch the original →
the gist
Developers can reduce cognitive load by delegating tasks to local, background, and cloud-based AI agents simultaneously within a single VS Code control plane.
Agent Classification and Workflow
Effective agentic workflows rely on selecting the right execution environment based on the level of human oversight required. Developers should categorize tasks into three distinct modes:
- Local Agents: Use these for high-touch tasks, such as writing and debugging unit tests, where human-in-the-loop iteration is necessary to ensure code quality.
- Background Agents: Utilize these for isolated, time-consuming tasks like front-end UI generation. By leveraging git worktrees, developers can maintain an isolated branch for the agent to work on while continuing their primary development tasks.
- Cloud Agents: Offload low-touch, repetitive maintenance tasks such as repository documentation, README generation, or making a project open-source friendly to cloud-based agents running in GitHub Actions.
Unified Control Plane
VS Code serves as a centralized hub for managing these heterogeneous agent types. The editor provides a unified interface to configure and trigger agents, including first-party GitHub Copilot tools and third-party integrations like Claude. Key configuration features include:
- Custom Instructions: Define specific behaviors and constraints for each agent.
- MCP Servers: Use the Model Context Protocol to extend agent capabilities, such as connecting to Playwright for automated UI testing or accessing external documentation sources.
- Agent Skills: Utilize pre-built or custom skills to automate specific actions like pull request creation or error handling.
- Safety Controls: Cloud agents operate in isolated environments with network firewalls and restricted access to main branches, ensuring that automated tasks do not compromise repository integrity.