|
Some checks failed
Publish Memory Graph / publish (push) Has been cancelled
## Summary Addresses user feedback about the graph view: content in node popovers was hard-truncated at 100 characters with no way to read the full text or navigate to the document. ### Changes **Scrollable popover content (no more truncation)** - Removed the `truncate(content, 100)` call -- full content is now rendered in the popover - Made the content area scrollable with `maxHeight: 100px` and `overflowY: auto` - Increased version timeline entry truncation from 60 to 120 characters - Increased version timeline container height from 120px to 160px **"View document" in shortcuts panel** - Added an eye icon + "View document" entry to the shortcuts panel (alongside existing arrow navigation) - Clicking opens the Document Modal for the corresponding document - Works for both document nodes (opens that document) and memory nodes (opens the parent document) - Popover is automatically dismissed before the modal opens (prevents z-index overlap) - Wired `onOpenDocument` callback through the full component chain: `page.tsx` -> `GraphLayoutView` -> `MemoryGraph` wrapper -> `MemoryGraphBase` -> `NodeHoverPopover` **Shortcuts panel visual cleanup** - Icon badges (`KeyBadge`) retain dark background and border for a keyboard-key badge look - All icons (including the new EyeIcon) are uniformly wrapped in `KeyBadge` for consistent styling - Removed background, border, and border-radius from the shortcuts panel container itself - Widened shortcuts panel from 100px to 160px so navigation labels are fully visible **Type safety improvement** - Changed `MemoryGraphProps.colors` from `GraphThemeColors` to `Partial<GraphThemeColors>` to match actual usage (callers pass partial overrides that get merged with defaults) - Replaced `as Partial<typeof import(...)>` cast with proper `satisfies Partial<GraphThemeColors>` using a direct type import ### Files changed - `packages/memory-graph/src/components/node-hover-popover.tsx` -- scrollable content, EyeIcon + "View document" in shortcuts, KeyBadge styling, NavButton icon type broadened to `React.ReactNode`, all icons wrapped in KeyBadge - `packages/memory-graph/src/components/memory-graph.tsx` -- popover dismissal wrapper (`handleOpenDocument`), prop forwarding - `packages/memory-graph/src/types.ts` -- `onOpenDocument` prop on `MemoryGraphProps`, `colors` changed to `Partial<GraphThemeColors>` - `apps/web/components/graph-layout-view.tsx` -- accepts and passes `onOpenDocument` - `apps/web/components/memory-graph/memory-graph-wrapper.tsx` -- `onOpenDocument` in wrapper props, clean type import - `apps/web/app/(app)/page.tsx` -- `handleOpenDocumentById` handler, wired to `GraphLayoutView` ## Testing ### Unit Tests (154/154 passed) - **Command:** `cd packages/memory-graph && bun run test` - **Result:** 9 test files, 154 tests passed (107 existing + 47 new) - **New test file:** `packages/memory-graph/src/__tests__/node-hover-popover.test.tsx` covering: - Layout constants (`SHORTCUTS_W=160`, `CARD_W=280`, `TOTAL_W` formula) - Content area scrollability (`maxHeight:100`, `overflowY:auto`, `flex:1 1 auto`, no truncation) - KeyBadge styles (has `backgroundColor: colors.controlBg`, has `border` with `colors.controlBorder`) - Shortcuts panel styles (no `backgroundColor`, no `border`, no `borderRadius`) - EyeIcon SVG component (`aria-hidden`, viewBox, path, circle, stroke) - "View document" button render guard (`onOpenDocument && documentId`) - `documentId` derivation (memory vs document node) - VersionTimeline truncation limit (120 chars) and container maxHeight (160) - `onOpenDocument` prop wiring - NavButton icon prop type (`React.ReactNode`), all icons wrapped in KeyBadge - `handleOpenDocument` wrapper in MemoryGraph (dismiss calls, ordering, useCallback deps) ### Build - **Command:** `bun run --filter=@supermemory/memory-graph build` - **Result:** Build succeeds, 0 errors ### Lint/Format - **Command:** `bunx biome ci --changed --since=origin/main --no-errors-on-unmatched` - **Result:** 6 files checked, no fixes applied, 0 errors ### Type Checking - `packages/memory-graph`: 0 errors - `apps/web`: 0 new errors introduced ### CI - "CI - Type Check, Format & Lint" workflow passes - "Claude Code Review" workflow fails due to repo config (`non-human actor: vorflux` not in `allowed_bots` list) -- not related to code changes --- **Session Details** - Session: [View Session](https://supermemory.us1.vorflux.com/agent-sessions/d0c067f1-38c1-40c5-ada9-b2ffb7331d1c) - Requested by: Mahesh Sanikommu (mahesh@supermemory.com) - Address comments on this PR. Add `(aside)` to your comment to have me ignore it. |
||
|---|---|---|
| .github/workflows | ||
| apps | ||
| packages | ||
| skills/supermemory | ||
| .gitignore | ||
| biome.json | ||
| bun.lock | ||
| CLAUDE.md | ||
| CONTRIBUTING.md | ||
| LICENSE | ||
| package.json | ||
| portless.json | ||
| README.md | ||
| turbo.json | ||
State-of-the-art memory and context engine for AI.
Docs · Quickstart · Dashboard · Discord
Supermemory is the memory and context layer for AI. #1 on LongMemEval, LoCoMo, and ConvoMem — the three major benchmarks for AI memory.
We are a research lab building the engine, plugins and tools around it.
Your AI forgets everything between conversations. Supermemory fixes that.
It automatically learns from conversations, extracts facts, builds user profiles, handles knowledge updates and contradictions, forgets expired information, and delivers the right context at the right time. Full RAG, connectors, file processing — the entire context stack, one system.
| 🧠 Memory | Extracts facts from conversations. Handles temporal changes, contradictions, and automatic forgetting. |
| 👤 User Profiles | Auto-maintained user context — stable facts + recent activity. One call, ~50ms. |
| 🔍 Hybrid Search | RAG + Memory in a single query. Knowledge base docs and personalized context together. |
| 🔌 Connectors | Google Drive · Gmail · Notion · OneDrive · GitHub — auto-sync with real-time webhooks. |
| 📄 Multi-modal Extractors | PDFs, images (OCR), videos (transcription), code (AST-aware chunking). Upload and it works. |
All of this is in our single memory structure and ontology.
Use Supermemory
🧑💻 I use AI toolsBuild your own personal supermemory by using our app. Builds persistent memory graph across every conversation. Your AI remembers your preferences, projects, past discussions — and gets smarter over time. |
🔧 I'm building AI productsAdd memory, RAG, user profiles, and connectors to your agents and apps with a single API. No vector DB config. No embedding pipelines. No chunking strategies. |
Give your AI memory
The Supermemory App, browser extension, plugins and MCP server gives any compatible AI assistant persistent memory. One install, and your AI remembers you.
The app
You can use supermemory without any code, by using our consumer-facing app for free.
Start at https://app.supermemory.ai
It also comes with an agent embedded inside, which we call Nova.
Supermemory Plugins
Supermemory comes built with Plugins for Claude Code, OpenCode, OpenClaw, and Hermes.
These plugins are implementations of the supermemory API, and they are open source!
You can find them here:
- Openclaw plugin: https://github.com/supermemoryai/openclaw-supermemory
- Claude code plugin: https://github.com/supermemoryai/claude-supermemory
- OpenCode plugin: https://github.com/supermemoryai/opencode-supermemory
- Hermes agent (Supermemory memory provider): https://github.com/NousResearch/hermes-agent
MCP - Quick install
npx -y install-mcp@latest https://mcp.supermemory.ai/mcp --client claude --oauth=yes
Replace claude with your client: cursor, windsurf, vscode, etc.
Read more about our MCP here - https://supermemory.ai/docs/supermemory-mcp/mcp
What your AI gets
| Tool | What it does |
|---|---|
memory |
Save or forget information. Your AI calls this automatically when you share something worth remembering. |
recall |
Search memories by query. Returns relevant memories + your user profile summary. |
context |
Injects your full profile (preferences, recent activity) into the conversation at start. In Cursor and Claude Code, just type /context. |
How it works
Once installed, Supermemory runs in the background:
- You talk to your AI normally. Share preferences, mention projects, discuss problems.
- Supermemory extracts and stores the important stuff. Facts, preferences, project context — not noise.
- Next conversation, your AI already knows you. It recalls what you're working on, how you like things, what you discussed before.
Memory is scoped with projects (container tags) so you can separate work and personal context, or organize by client, repo, or anything else.
Supported clients
Claude Desktop · Cursor · Windsurf · VS Code · Claude Code · OpenCode · OpenClaw · Hermes
The MCP server is open source — view the source.
Manual configuration
Add this to your MCP client config:
{
"mcpServers": {
"supermemory": {
"url": "https://mcp.supermemory.ai/mcp"
}
}
}
Or use an API key instead of OAuth:
{
"mcpServers": {
"supermemory": {
"url": "https://mcp.supermemory.ai/mcp",
"headers": {
"Authorization": "Bearer sm_your_api_key_here"
}
}
}
}
Build with Supermemory (API)
If you're building AI agents or apps, Supermemory gives you the entire context stack through one API — memory, RAG, user profiles, connectors, and file processing.
Install
npm install supermemory # or: pip install supermemory
Quickstart
import Supermemory from "supermemory";
const client = new Supermemory();
// Store a conversation
await client.add({
content: "User loves TypeScript and prefers functional patterns",
containerTag: "user_123",
});
// Get user profile + relevant memories in one call
const { profile, searchResults } = await client.profile({
containerTag: "user_123",
q: "What programming style does the user prefer?",
});
// profile.static → ["Loves TypeScript", "Prefers functional patterns"]
// profile.dynamic → ["Working on API integration"]
// searchResults → Relevant memories ranked by similarity
from supermemory import Supermemory
client = Supermemory()
client.add(
content="User loves TypeScript and prefers functional patterns",
container_tag="user_123"
)
result = client.profile(container_tag="user_123", q="programming style")
print(result.profile.static) # Long-term facts
print(result.profile.dynamic) # Recent context
Supermemory automatically extracts memories, builds user profiles, and returns relevant context. No embedding pipelines, no vector DB config, no chunking strategies.
Framework integrations
Drop-in wrappers for every major AI framework:
// Vercel AI SDK
import { withSupermemory } from "@supermemory/tools/ai-sdk";
const model = withSupermemory(openai("gpt-4o"), { containerTag: "user_123", customId: "conv-1" });
// Mastra
import { withSupermemory } from "@supermemory/tools/mastra";
const agent = new Agent(withSupermemory(config, "user-123", { mode: "full" }));
Vercel AI SDK · LangChain · LangGraph · OpenAI Agents SDK · Mastra · Agno · Claude Memory Tool · n8n
Search modes
// Hybrid (default) — RAG + Memory in one query
const results = await client.search.memories({
q: "how do I deploy?",
containerTag: "user_123",
searchMode: "hybrid",
});
// Returns deployment docs (RAG) + user's deploy preferences (Memory)
// Memories only
const results = await client.search.memories({
q: "user preferences",
containerTag: "user_123",
searchMode: "memories",
});
User profiles
Traditional memory relies on search — you need to know what to ask for. Supermemory automatically maintains a profile for every user:
const { profile } = await client.profile({ containerTag: "user_123" });
// profile.static → ["Senior engineer at Acme", "Prefers dark mode", "Uses Vim"]
// profile.dynamic → ["Working on auth migration", "Debugging rate limits"]
One call. ~50ms. Inject into your system prompt and your agent instantly knows who it's talking to.
Connectors
Auto-sync external data into your knowledge base:
Google Drive · Gmail · Notion · OneDrive · GitHub · Web Crawler
Real-time webhooks. Documents automatically processed, chunked, and searchable.
API at a glance
| Method | Purpose |
|---|---|
client.add() |
Store content — text, conversations, URLs, HTML |
client.profile() |
User profile + optional search in one call |
client.search.memories() |
Hybrid search across memories and documents |
client.search.documents() |
Document search with metadata filters |
client.documents.uploadFile() |
Upload PDFs, images, videos, code |
client.documents.list() |
List and filter documents |
client.settings.update() |
Configure memory extraction and chunking |
Full API reference → supermemory.ai/docs
Benchmarks
Supermemory is state of the art across all major AI memory benchmarks:
| Benchmark | What it measures | Result |
|---|---|---|
| LongMemEval | Long-term memory across sessions with knowledge updates | 81.6% — #1 |
| LoCoMo | Fact recall across extended conversations (single-hop, multi-hop, temporal, adversarial) | #1 |
| ConvoMem | Personalization and preference learning | #1 |
We also built MemoryBench — an open-source framework for standardized, reproducible benchmarks of memory providers. Compare Supermemory, Mem0, Zep, and others head-to-head:
bun run src/index.ts run -p supermemory -b longmemeval -j gpt-4o -r my-run
Benchmarking your own memory solution
We provide an Agent skill for companies to benchmark their own context and memory solutions against supermemory.
npx skills add supermemoryai/memorybench
Simply run this and do /benchmark-context - Supermemory will automatically do the work for you!
How memory works under the hood
Your app / AI tool
↓
Supermemory
│
├── Memory Engine Extracts facts, tracks updates, resolves contradictions,
│ auto-forgets expired info
├── User Profiles Static facts + dynamic context built from engine, always fresh
├── Hybrid Search RAG + Memory in one query
├── Connectors Real-time sync from Google Drive, Gmail, Notion, GitHub...
└── File Processing PDFs, images, videos, code → searchable chunks
Memory is not RAG. RAG retrieves document chunks — stateless, same results for everyone. Memory extracts and tracks facts about users over time. It understands that "I just moved to SF" supersedes "I live in NYC." Supermemory runs both together by default, so you get knowledge base retrieval and personalized context in every query. Read more about this here - https://supermemory.ai/docs/concepts/memory-vs-rag
Automatic forgetting. Supermemory knows when memories become irrelevant. Temporary facts ("I have an exam tomorrow") expire after the date passes. Contradictions are resolved automatically. Noise never becomes permanent memory.
Links
- 📖 Documentation
- 🚀 Quickstart
- 🧪 MemoryBench
- 🔌 Integrations
- 💬 Discord
- 𝕏 Twitter
Give your AI a memory. It's about time..