Real-time memory recall for AI conversations.
XMem watches what you type in ChatGPT, Claude, Gemini, Perplexity, and DeepSeek — then surfaces relevant memories from your personal memory store before you hit send.
demo.mp4
extension-settings-1773462173011.mp4
You type in an AI chat
|
v
XMem debounces your input (600ms)
|
v
Semantic search hits your XMem server
|
v
Relevant memories appear as ghost text + floating chip
|
v
Tab to accept · Click chip to browse · Memories inject into your prompt
As you type in any supported AI chat, XMem performs semantic search against your memory store and renders ghost text inline — press Tab to accept, Escape to dismiss. A floating chip displays the count of matching memories. Searches fire only after 8+ characters and only when the cursor is at the end of input.
| Tab | What it does |
|---|---|
| Memories | Browse results with domain tags (profile, temporal, summary) and relevance scores |
| Ask Memory | Ask natural-language questions — get LLM-generated answers backed by your stored memories |
| Settings | Connection status, configured domains, version info |
Your outgoing messages are captured and ingested automatically after the AI finishes responding. You can also right-click any selected text on any page and choose "Save to XMem Memory".
| Command | Mode |
|---|---|
/Xingest |
Queue-based ingestion — saves conversations to memory without blocking the UI |
/Xsearch |
Auto-inject synthesized memory context when you send a message |
/Xide |
Auto-inject codebase context on send (IDE mode) |
/Xrepo |
Browse and query your codebase structure via a file tree panel |
Browse a codebase directory tree from the left panel. Query it semantically ("What does the payment service do?") and get streaming responses with file and symbol references extracted automatically.
| Platform | Domain |
|---|---|
| ChatGPT | chatgpt.com chat.openai.com |
| Claude | claude.ai |
| Gemini | gemini.google.com |
| Perplexity | perplexity.ai |
| DeepSeek | chat.deepseek.com |
| Other | Any page with standard <textarea> or contenteditable fields |
- Chrome browser
- A running XMem server (default:
http://localhost:8000) - Node.js 20+
npm install
npm run buildFor development with hot reload:
npm run dev- Open
chrome://extensions/ - Enable Developer mode (top-right toggle)
- Click Load unpacked
- Select the
dist/folder
- Click the XMem icon in the Chrome toolbar
- Enter your API URL (e.g.
http://localhost:8000) - Enter your API Key (if required)
- Set your User ID
- Click Save Settings
- Click Test to verify the connection — a green dot confirms you're live
| Setting | Storage key | Default | Description |
|---|---|---|---|
| API URL | xmem_api_url |
http://localhost:8000 |
XMem backend endpoint |
| API Key | xmem_api_key |
— | Authentication token |
| User ID | xmem_user_id |
chrome-extension-user |
Your user identifier |
| Memory Active | xmem_enabled |
true |
Master on/off switch |
| Live Suggestions | xmem_live_suggest |
true |
Ghost text inline suggestions |
| IDE Org ID | xmem_ide_org_id |
— | Organization for code context |
| IDE Repo | xmem_ide_repo |
— | Repository for code context |
| Effort Level | xmem_effort_level |
low |
Ingestion detail level (low / high) |
xmem-extension/
src/
api.ts API client + request queue (wraps xmem-ai SDK)
background.ts Service worker — context menus, message routing
content.ts Core logic — editor detection, live search, sidebar, auto-save
popup.html Settings UI (dark mode, 360px popup)
popup.ts Settings persistence via chrome.storage.sync
icons/ Extension icons (16, 48, 128 px)
manifest.json Chrome Manifest V3
vite.config.ts Build config (@crxjs/vite-plugin)
| Method | Endpoint | Purpose |
|---|---|---|
POST |
/v1/memory/ingest |
Save messages and responses |
POST |
/v1/memory/search |
Semantic search across memory domains |
POST |
/v1/memory/retrieve |
LLM-synthesized answers from memory |
GET |
/health |
Server connectivity check |
GET |
/ping |
Health status with version |
POST |
/v1/code/query_stream |
Stream code query results |
GET |
/v1/code/directory_tree |
Codebase directory structure |
GET |
/v1/code/list_repos |
Available repositories |
- Request queue — All API calls are serialized to prevent
INVALID_CONCURRENT_GRAPH_UPDATEerrors from the LangGraph backend - Editor detection — A
MutationObserverwatches the DOM for editable fields using per-site CSS selectors - React compatibility — Uses native property setters to update React-controlled textareas (ChatGPT)
- Theme-aware — Detects light/dark backgrounds to style ghost text appropriately
- Ingestion queue — Separate queue for batch saves so the UI never blocks
Built by Xortex