Hydrate for GitHub Copilot — install in five minutes
After this page: the@hydrateparticipant is available in Copilot Chat, thehydrate_recallandhydrate_compresslanguage model tools are auto-invoked by Copilot when relevant, and memory from your Claude Code and Codex sessions is accessible inside VS Code.
Prerequisites
- Hydrate installed (
hydrate doctorall-green). See Free install. - VS Code 1.90+ with the GitHub Copilot extension installed and active.
Install
hydrate install-vscode
This runs code --install-extension <vsix> using the
hydrate.vsix that ships with the Hydrate release. Output:
✓ VS Code extension installed: sedasoft.hydrate
Alternatively, install manually from within VS Code: open the Extensions panel, search for
Hydrate, install sedasoft.hydrate.
After installation, reload VS Code (or run Developer: Reload Window from the command palette).
Verify
Open a Copilot Chat panel and type:
@hydrate /recall auth middleware Expected: a response drawing from your Hydrate memory — prior decisions, facts, and session summaries related to auth middleware. If you have no sessions captured yet, the response will say so; run a Claude Code session first.
To confirm the extension is active:
- Open the command palette (
Cmd+Shift+P/Ctrl+Shift+P). - Run
Hydrate: Open Dashboard— your local dashboard should open in a browser tab.
What you get
@hydrate chat participant
A dedicated Copilot Chat participant with three commands:
| Command | What it does |
|---|---|
@hydrate /recall <topic> | Retrieve prior decisions, facts, and summaries related to a topic |
@hydrate /drain | Pull any queued memory injections and mark them consumed |
@hydrate /capture | Flush the current Copilot Chat session to Hydrate immediately (rather than waiting for session end) |
Use @hydrate /recall when you remember you worked on something before but do not remember the details. Example:
@hydrate /recall why we chose postgres over sqlite for the session store Language model tools (auto-invoked)
Two tools are registered as LM tools, meaning Copilot can invoke them automatically without
you using @hydrate:
hydrate_recall — invoked when Copilot detects you are referencing
past work. Input: a short topic phrase. Output: relevant facts and session summaries from your
Hydrate store. Copilot uses this when you ask things like "what did we decide about X?" or
"why is Y configured this way?"
hydrate_compress — invoked when Copilot needs to read a large
document (README, ARCHITECTURE.md, vendor page) that would exceed the context window. Hydrate
compresses it to a dense semantic summary first. Returns the compressed form with an estimate
of tokens saved.
hydrate_read_file — reads a workspace file, automatically routing
through hydrate_compress when the file is large. Copilot uses this instead of
reading large files directly.
VS Code commands
Accessible from the command palette (Cmd+Shift+P):
| Command | What it does |
|---|---|
Hydrate: Open Dashboard | Open the local Hydrate dashboard in a browser |
Hydrate: Show Queued Injections | Show memory items queued for the next prompt |
Hydrate: Dehydrate Open File | Extract facts from the currently open file into Hydrate |
Hydrate: Dehydrate Workspace Docs | Extract facts from all docs in the workspace |
Hydrate: Compress This Doc | Compress the active document and show token savings |
Cross-runtime memory
Facts from your Claude Code and Codex sessions are immediately available in Copilot. No sync
step needed — all three runtimes read from the same ~/.hydrate/data.db.
Example flow:
- In a Claude Code session, pin a fact:
hydrate canon add "always use structured logging, never fmt.Println". - Open VS Code with the same project.
- In Copilot Chat, ask Copilot about logging. It auto-invokes
hydrate_recalland injects the pinned fact before responding.
Copilot Chat vs inline completions
Hydrate integrates with Copilot Chat (the panel-based assistant), not with
inline completions. VS Code does not expose third-party APIs for inline completion context.
The token savings from hydrate_compress apply to Chat turns where Copilot would
otherwise send a large document as raw context.
Measured token savings
In two measurement passes (Hydrate's own repo and an unrelated codebase):
| Surface | Savings |
|---|---|
hydrate_recall (context preview) | ~87–95% reduction vs. rediscovering the same context |
hydrate_compress (direct compression) | 10,903–36,423 tokens saved per pass |
Methodology and raw data: docs/measurement/2026-04-21-copilot-savings.md.
Environment variables
The extension reads the same variables as the CLI:
| Variable | Default | Purpose |
|---|---|---|
HYDRATE_CONTEXT_API | http://localhost:<port> | Local server URL (auto-detected from ~/.hydrate/server.port) |
HYDRATE_CONTEXT_KEY | read from ~/.hydrate/server.key | API key for the local server |
For enterprise installs where the server is not on localhost, set HYDRATE_CONTEXT_API in VS Code's settings.json:
{
"hydrate.serverUrl": "http://192.168.1.100:8095"
} What changed on your machine
| Path | Purpose |
|---|---|
~/.vscode/extensions/sedasoft.hydrate-<version>/ | Extension files |
The extension communicates with the already-running hydrate-server — no new
daemon is started.
Troubleshooting
| Symptom | Likely cause | Fix |
|---|---|---|
@hydrate not visible in Copilot Chat | Extension not installed or reload needed | Run Hydrate: Open Dashboard to confirm the extension is active; reload VS Code |
@hydrate /recall returns nothing | No captured sessions | Run a Claude Code or Codex session, let it end naturally, retry |
hydrate_recall auto-invocation not happening | Copilot not recognising the tool | Confirm VS Code is 1.90+; check that Copilot's LM Tools feature is enabled in settings |
| Dashboard command opens blank page | hydrate-server not running | hydrate server start from a terminal, then retry |
| Token savings lower than expected | Short files do not trigger hydrate_compress | The tool activates on files above a token threshold (~2000 tokens); small files pass through uncompressed |
Next steps
- Claude Code integration — the memory substrate Copilot draws from
- Codex integration — another client sharing the same facts
- Pro install — unlock Hydration Packs to export/import project memory