GitHub Copilot is unmatched at predicting the next line of code or generating a standard function on the fly inside Visual Studio Code. Yet almost every developer encounters its sharp boundary: project-scoped amnesia. Copilot’s context window is strictly bounded by active files, recent editor tabs, and local workspace indexing. The moment you switch repositories or need an obscure regex pattern, database transaction boilerplate, or API wrapper you saved three weeks ago, Copilot has no memory of it.
Pieces solves this specific structural flaw. By running as an intelligent, contextual background engine via PiecesOS and exposing its Long-Term Memory (LTM) through the Model Context Protocol (MCP), Pieces turns GitHub Copilot into a developer assistant with persistent, cross-project recall.
At 365Finds, we evaluate this setup not as two redundant AI tools competing for the same sidebar, but as a deliberate division of labor: GitHub Copilot handles real-time generation and workspace syntax, while Pieces acts as the personal snippet vault and cross-application memory bank.
The Architectural Shift: Why MCP Replaced the Legacy Extension
If you used Pieces previously, you might recall installing a dedicated Pieces for VS Code extension. Pieces has officially sunset its standalone IDE extensions in favor of Anthropic’s open Model Context Protocol (MCP).
This transition matters. Instead of running a heavy, proprietary plugin that constantly competes with Copilot inside the editor UI, modern integration runs through a clean protocol:
- PiecesOS as Local Daemon: Runs silently on macOS, Windows, or Linux, managing your local snippet database, metadata enrichment (AST analysis, tags, origin URLs, related links), and local vector embeddings.
- Local MCP Endpoint: PiecesOS serves an MCP endpoint over local HTTP/SSE (typically running on
http://localhost:39300). - VS Code MCP Client: VS Code natively connects GitHub Copilot Chat (Agent mode) to the Pieces MCP server.
- Tool Calling (
ask_pieces_ltm): When you ask GitHub Copilot a question referencing saved code, previous projects, or historical debugging sessions, Copilot dynamically invokesask_pieces_ltmto fetch the snippet and its context before formulating the answer.
Step-by-Step: Setting Up Pieces with GitHub Copilot in VS Code
Connecting your persistent Pieces snippet memory to GitHub Copilot takes less than five minutes.
1. Ensure PiecesOS and Long-Term Memory are Active
- Download and launch PiecesOS (and the Pieces Desktop application).
- Open Pieces Desktop settings or the PiecesOS system tray menu.
- Confirm that Long-Term Memory (LTM) is enabled. Without LTM active, the MCP server cannot query your historical workflow context.
2. Configure the MCP Server in VS Code
You can link the Pieces MCP server using either the Pieces CLI or VS Code configuration files.
Option A: Automatic Setup via Pieces CLI (Recommended)
Open your terminal and run:
pieces mcp setup
Select VS Code from the interactive list, choose User Settings (to ensure Pieces snippet memory is available across all workspaces globally), and press Enter. Verify the connection:
pieces mcp status
Option B: Manual Configuration (mcp.json)
If you prefer managing editor settings manually:
- Open the VS Code Command Palette (
Ctrl+Shift+Pon Windows/Linux,Cmd+Shift+Pon macOS). - Type and select
MCP: Open User Configuration. - Obtain your local schema URL from the Pieces Desktop App under Settings > MCP.
- Add the Pieces server definition to your configuration:
{
"servers": {
"pieces": {
"type": "http",
"url": "http://localhost:39300/model_context_protocol/YOUR_SCHEMA_DATE/mcp"
}
}
}
- Save the file and restart VS Code.
3. Verify the Active Connection
- Open the Extensions / MCP panel in VS Code.
- Locate
piecesunder configured MCP servers and confirm it displays a green checkmark or active status. - Open GitHub Copilot Chat in the sidebar, ensure Agent mode is active, and test the integration.
How Long-Term Snippet Memory Works in Daily Coding
Once the bridge is active, you do not need to manually search the Pieces desktop UI, copy a snippet, switch back to VS Code, and paste it into Copilot.
Cross-Repository Snippet Retrieval
Imagine you wrote a resilient exponential backoff retry handler in a microservice six months ago and saved it to Pieces. In an entirely new repository, you prompt GitHub Copilot Chat:
"Retrieve the retry helper snippet I saved in Pieces and adapt it to work with this Axios HTTP client."
Copilot invokes ask_pieces_ltm, PiecesOS retrieves the snippet alongside its language metadata and tags, and Copilot writes the adapted implementation directly into your current project context.
Origin and Context Awareness
When Pieces saves code snippets, it automatically captures surrounding metadata: the source URL, the Git repository origin, detected dependencies, and descriptive summaries. When GitHub Copilot accesses this snippet via MCP, it gains the "why" behind the code, helping it avoid deprecated APIs or missing prerequisites that raw code dumps usually suffer from.
Pieces vs GitHub Copilot: Division of Responsibility
| Capability | GitHub Copilot | Pieces (via MCP) |
|---|---|---|
| Primary Strength | Inline autocompletion; repository-level synthesis; chat debugging | Persistent snippet storage; cross-workspace recall; workflow LTM |
| Context Scope | Current file, open tabs, active repository index | Global personal snippets, browser clippings, cross-repo history |
| Trigger Mechanism | Keystroke ghost text; Copilot Chat prompt | MCP tool call (ask_pieces_ltm) orchestrated by Copilot |
| Data Privacy | Cloud inference via GitHub / Azure infrastructure | Local PiecesOS on-device storage; local embedding index |
| Setup Overhead | VS Code extension login | PiecesOS daemon + VS Code MCP registration |
The 365Finds Verdict: Practical Trade-Offs
365Finds firmly recommends pairing Pieces with GitHub Copilot if your development workflow spans multiple repositories, frameworks, or client projects. Standard Copilot treats you like a stranger every time you open an empty folder. Pieces provides the continuity.
However, keep these practical boundaries in mind:
- Chat Agent vs Ghost Text: The Pieces MCP integration works through GitHub Copilot Chat agent tool calling. It does not passively inject thousands of personal snippets into Copilot's millisecond-level inline ghost text completions. This prevents latency degradation and prompt context bloat, but it requires developers to actively engage Copilot Chat to pull historical snippets.
- Local Daemon Overhead: PiecesOS runs continuously in the background to handle indexing, OCR, and LTM capture. While lightweight on modern machines, developers on constrained hardware should monitor background memory usage.
- Snippet Hygiene: MCP retrieval depends on Pieces’ semantic index. If your saved snippets lack descriptive context or are bloated with throwaway code, retrieval relevance drops.
When configured via MCP, Pieces turns GitHub Copilot from a workspace-bound code generator into an assistant that remembers your personal engineering track record across machines and projects.