Skip to main content
ReclaimLLM integrates natively with GitHub Copilot in Visual Studio Code using the official VS Code Agent Hooks specification. When running Copilot in Agent mode, ReclaimLLM captures the full lifecycle of your sessions — prompts, responses, tool executions, file modifications with diffs, and token analytics — directly to your ReclaimLLM dashboard. In addition to session capture, the installer configures the ReclaimLLM Model Context Protocol (MCP) server so Copilot can search past sessions, pull prior context, and summarize historical work.
GitHub Copilot hook capture requires VS Code with agent hooks support (such as VS Code Insiders or the latest VS Code release with Copilot Chat agent mode) and Workspace Trust enabled for your repository.

Quick start

1

Install or update rclm

Install the latest rclm package from PyPI:
2

Run the hook installer

Run rclm-hooks-install to register hooks and MCP across all supported providers (including GitHub Copilot):
To install only for GitHub Copilot / VS Code:
The installer writes hook definitions and registers the ReclaimLLM MCP server automatically:
3

Verify in VS Code

Open VS Code in your workspace, open Copilot Chat, and run an agent prompt (e.g. @workspace or agent mode). When the session completes, ReclaimLLM finalizes the session record and uploads it to your dashboard.

Hook configuration & scopes

ReclaimLLM supports both global (user-wide) and workspace-local configuration:

Global installation

By default, hooks are placed in ~/.copilot/hooks/rclm.json. Any VS Code window with Workspace Trust enabled will execute the hook commands across all projects.

Workspace-local installation

When using --local, ReclaimLLM writes the hook definitions to .github/hooks/rclm.json and the MCP server configuration to .vscode/mcp.json. This keeps hooks scoped strictly to the current repository and allows committing the hook configuration to source control for team consistency.

Supported lifecycle events

The rclm-copilot-hooks binary hooks into the VS Code agent lifecycle:
All hook executions run fail-open and exit with code 0. If any local operation fails, it will never disrupt or terminate your Copilot agent session.

Model Context Protocol (MCP) integration

When you run rclm-hooks-install, MCP server registration is enabled by default. This exposes ReclaimLLM’s memory tools directly to GitHub Copilot:
  • search_sessions: Semantic and keyword search across past agent sessions.
  • search_by_filename: Find prior sessions that modified a specific file.
  • summarize_session: Generate a compact context summary of a past task.
  • get_session: Retrieve session details and dashboard links.
  • file_brief: Get a quick history of recent edits to a file.
  • handoff: Create a continuation package for long sessions.

MCP configuration structure

For global installations, ReclaimLLM updates ~/.copilot/mcp-config.json:
For workspace-local installations, ReclaimLLM updates .vscode/mcp.json:
To skip MCP installation when registering hooks, pass --no-with-mcp:

Historical session sync

If you previously used GitHub Copilot CLI or had existing agent session state, backfill your previous sessions into ReclaimLLM using rclm-sync:
Historical sync scans ~/.copilot/session-state/**/events.jsonl, parses conversation turns, tool calls, and model metadata, and uploads them to your ReclaimLLM account.

Uninstalling hooks

To remove ReclaimLLM hooks from GitHub Copilot without affecting other tools:
This cleans up the ReclaimLLM hook entries and removes the hook configuration file if no other hooks remain.

Verification & troubleshooting

VS Code restricts agent hooks and MCP servers to trusted workspaces for security. If hooks are not triggering:
  1. Check the bottom status bar or run Workspaces: Manage Workspace Trust from the Command Palette (Cmd+Shift+P / Ctrl+Shift+P).
  2. Ensure the current folder is marked as Trusted.
VS Code logs all hook invocations to an internal output channel:
  1. Open the Output panel in VS Code (Cmd+Shift+U / Ctrl+Shift+U).
  2. In the dropdown selector on the right, select GitHub Copilot Chat Hooks.
  3. You will see logs of SessionStart, UserPromptSubmit, and tool hook invocations as Copilot runs.
Open the Command Palette (Cmd+Shift+P / Ctrl+Shift+P) and run:
or type /hooks directly in Copilot Chat. Ensure the ReclaimLLM hook file (~/.copilot/hooks/rclm.json or .github/hooks/rclm.json) is listed and active.
Before upload, completed sessions are spooled locally. You can inspect spooled records with:
If files appear here after closing a session, hooks are capturing successfully.
If Copilot does not recognize ReclaimLLM MCP tools immediately after running the installer, reload the VS Code window:
  1. Open the Command Palette (Cmd+Shift+P / Ctrl+Shift+P).
  2. Run Developer: Reload Window.