AD SPACE AVAILABLE · BRAND PARTNERS WELCOME

Stop Alt-Tabbing: How to Pair Pieces and GitHub Copilot in VS Code

徐垠慧 · 365Finds Editorial
Indexed 88,650 Wiki articles

Put 365 Wiki to work with your AI

Copy the prompt below, paste it into the AI you already use, then ask your question.

Download full Skill

Try it with the prompt first. If you use 365 Wiki often, install the full 365Wiki Skill so you do not have to paste it again. No regular AI? Gemini or Microsoft Copilot on the web will work.

365Wiki Skill

Context switching kills developer velocity faster than compilation errors. You hit a tricky integration, switch to your browser to scan documentation, copy a curl snippet, jump to a project management ticket to check API parameters, grab an architecture screenshot from Slack, and finally return to Visual Studio Code. By the time you get back to your editor, your working memory is fractured.

At 365Finds, we watch developers try to solve this by forcing GitHub Copilot to do things it was never built to do—like guessing what you were just reading in Chrome. It does not work. Copilot is an exceptional workspace synthesizer, but it is fundamentally confined to your active repository. Pieces, by contrast, acts as a persistent personal memory engine across your operating system.

When you pair Pieces with GitHub Copilot inside VS Code, you eliminate the constant Alt-Tab loop. Copilot writes the code; Pieces remembers the world outside the editor.

The Clear Division of Labor

Trying to pick between Pieces and GitHub Copilot is a false dilemma. At 365Finds, we strongly recommend running both, provided you strictly divide their responsibilities:

Operational DimensionGitHub CopilotPieces (PiecesOS)
Primary TerritoryActive VS Code workspace; open files; Git repository contextCross-application desktop; browser research; terminal history; clipboard snippets
Core StrengthReal-time inline code synthesis; multi-file repository edits; test generationPassive workflow capture; semantic snippet retrieval; OCR on code screenshots
Blind SpotBlind to external browser tabs, tickets, and past cross-repo patternsLess fluid than Copilot for instant in-line ghost text autocomplete
Ideal RoleThe Builder: executes code directly into the active editor bufferThe Context Vault: feeds external documentation and past solutions into the builder

Copilot understands your repository's abstract syntax tree and project files. Pieces understands what you did ten minutes ago in Jira or three days ago in an external documentation site.

The Modern Connection: Forget the Legacy Extension

If you read guides written even a year ago, they will instruct you to install the legacy "Pieces for Visual Studio Code" extension from the VS Code Marketplace. Do not do that.

Pieces officially sunset its dedicated IDE extensions. Instead of maintaining separate, brittle plugins across every editor, Pieces transitioned its entire ecosystem to Anthropic's open Model Context Protocol (MCP).

To connect Pieces to GitHub Copilot in modern VS Code, you run PiecesOS in the background and register Pieces as a native MCP server for Copilot. This gives Copilot direct access to Pieces's Long-Term Memory (LTM) without cluttering your editor with legacy UI toolbars.

Step-by-Step: Connecting Pieces MCP to GitHub Copilot

Setting up the pipeline takes less than five minutes.

1. Launch PiecesOS and Verify the Endpoint

Make sure PiecesOS is running on your workstation. Open the Pieces Desktop App, click your user profile avatar in the upper left corner, open Settings, and select Model Context Protocol (MCP). Copy the local server endpoint. It typically runs over localhost on port 10000:

http://localhost:10000/model_context_protocol/2025-03-26/mcp

2. Configure VS Code Settings

Open VS Code. Press Ctrl+Shift+P (Windows/Linux) or Cmd+Shift+P (macOS) to launch the Command Palette, and select Preferences: Open User Settings (JSON).

GitHub Copilot in VS Code registers MCP endpoints under the top-level servers configuration block. Add or merge the pieces server entry into your settings.json:

{
  "servers": {
    "pieces": {
      "url": "http://localhost:10000/model_context_protocol/2025-03-26/mcp"
    }
  }
}

3. Verify the Active MCP Bridge

Save settings.json. Open the Command Palette again and run:

MCP: List Servers

You should see pieces listed with an active, connected status. GitHub Copilot Chat can now call Pieces tools natively.

The 3-Stage Daily Workflow

Here is how 365Finds uses this pairing to keep hands on the keyboard and minds in the code:

Stage 1: External Context Capture (Browser & OS)

As you research an obscure API, read team issue tickets, or debug an unexpected cloud error, do not worry about maintaining a scratchpad. The Pieces browser extension and desktop background worker passively index technical content you view and code you copy. If an error dialog or diagram appears on screen, use Pieces to snapshot it; the built-in OCR turns images into searchable code blocks.

Stage 2: Copilot Queries Pieces Memory

Back in VS Code, instead of switching back to Chrome to find that API payload structure, open GitHub Copilot Chat and query your external memory directly:

"@copilot using pieces, retrieve the OAuth2 refresh token snippet I reviewed in the documentation this morning, and extract the required header schema."

Behind the scenes, GitHub Copilot identifies the request, calls the Pieces MCP tool (ask_pieces_ltm), and retrieves the exact payload without you touching your browser window.

Stage 3: In-Editor Code Generation

With the external context injected directly into the chat prompt context, tell Copilot to implement:

"Generate a TypeScript middleware file adapting this header schema to our existing Express request pipeline."

GitHub Copilot leverages its workspace knowledge to match your project's coding conventions, file naming standards, and imported types, completing the feature in your active file.

Trade-offs and Annoyances 365Finds Encountered

We like this combination, but it is not without friction:

References