Persistent memory for GitHub Copilot in VS Code
Install the cachly Brain extension from the VS Code Marketplace. Copilot then starts each chat with a briefing from your project's memory and gets matching lessons before each prompt.
Set it up
In VS Code, open Extensions (Ctrl+Shift+X), search for “cachly Brain” and click Install.
Trust the workspace when VS Code asks. In Restricted Mode the extension writes nothing.
Sign in once in the browser when asked. If Copilot shows a Start button above cachly in .vscode/mcp.json, click it once.
What happens automatically
- Chat start
- A short briefing: the most useful lessons of this project.
- Every prompt
- Lessons that match the prompt are added before Copilot answers.
On top of that, GitHub Copilot can call the cachly tools itself, for example smart_recall before a task and learn_from_attempts after a fix.
Files cachly writes
- .vscode/mcp.json
- Connects the cachly MCP server for Copilot.
- .github/copilot-instructions.md, AGENTS.md
- Tell Copilot when to use its memory.
- .github/hooks/cachly-ambient.json
- The hooks for the briefing and the lessons per prompt.
- .mcp.json, CLAUDE.md
- The same for Claude Code inside VS Code.
Limits
- In Restricted Mode the extension writes no files. Trust the workspace first.
- Copilot may show a Start button above the cachly entry in .vscode/mcp.json the first time. Click it once.
Frequently asked questions
How does cachly help Copilot remember things between chats?
Copilot reads your instructions files, which you write yourself. With cachly, lessons stored after a fix come back in later chats: as a briefing at the start and before each prompt that matches.
Do I need a terminal command for VS Code?
No. The extension writes the files and the hooks when you trust the workspace. The terminal command autopilot is only needed for editors without an extension.
Where is my memory stored?
On cachly servers in Nuremberg, Germany. Your project files hold no key; the key comes from your environment or from ~/.cachly/credentials.json on your machine.
Can my other coding tools use the same memory?
Yes. A lesson stored from one tool is available in every other tool connected to the same Brain, and to teammates who share it. Claude Code, Cursor, GitHub Copilot, JetBrains, Codex CLI and Gemini CLI all read from one Brain.