Skip to content

feat: VS Code MCP integration with partner agent support#1304

Open
bthillerup wants to merge 5 commits intothedotmack:mainfrom
bthillerup:GH-partner-agent
Open

feat: VS Code MCP integration with partner agent support#1304
bthillerup wants to merge 5 commits intothedotmack:mainfrom
bthillerup:GH-partner-agent

Conversation

@bthillerup
Copy link

@bthillerup bthillerup commented Mar 8, 2026

This PR adds support for using claude-mem when using GH Claude partner agent within VS. (And I'm sure it will also work for GH native agents.

https://github.com/settings/copilot/coding_agent

Summary

  • Add save_memory MCP tool wrapping POST /api/memory/save so agents can persist memories
  • Add worker auto-start with relative path resolution (works for npm global, marketplace, and repo installs)
  • Add VS Code MCP setup documentation (docs/public/usage/vscode-mcp.mdx) with step-by-step guide
  • Add agent instructions template (plugin/templates/claude-mem.instructions.md) for CLAUDE.md
  • Add VS Code MCP config template (plugin/templates/vscode-mcp.json)
  • Add dev MCP configs (.mcp.json for Claude partner agent, .vscode/mcp.json for Copilot agent mode)

Key discovery

The Claude partner agent in VS Code reads .mcp.json (project root, mcpServers key) — the same format as Claude Code CLI. It does not read .vscode/mcp.json (which uses the servers key and is for Copilot agent mode). Absolute paths are required.

Test plan

  • Install claude-mem via npm install -g claude-mem
  • Create .mcp.json in a project with absolute path to mcp-server.cjs
  • Open VS Code, verify Claude partner agent sees MCP tools
  • Test save_memory and search round-trip
  • Test smart_outline on a source file
  • Verify worker auto-starts when MCP server launches

🤖 Generated with Claude Code

bthillerup and others added 5 commits March 8, 2026 15:08
- Implemented a new API endpoint to save memories/observations with optional title and project association.
- Added a function to attempt auto-starting the worker service if it is not running, including checks for the bun executable.
- Enhanced worker availability check to include auto-start attempts and improved logging for worker status.
- Add save_memory MCP tool wrapping POST /api/memory/save
- Add worker auto-start with relative path resolution (works for npm global, marketplace, and repo installs)
- Add VS Code MCP setup docs (docs/public/usage/vscode-mcp.mdx)
- Add agent instructions template (plugin/templates/claude-mem.instructions.md)
- Add VS Code MCP config template (plugin/templates/vscode-mcp.json)
- Add dev MCP configs (.mcp.json for Claude partner agent, .vscode/mcp.json for Copilot)
- Remove copilot-instructions.md (partner agent reads CLAUDE.md instead)
- Revert unrelated build artifact changes

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…mory

- Rewrite instructions template to be explicit and mandatory (MUST use, NOT optional)
- Add save-as-you-work guidance for save_memory
- Document hooks providing automatic capture alongside MCP explicit tools
- Note Claude's local memory file works alongside claude-mem database

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant