memory-graph-visualizer
Admin Graph Exploration UI
| Property | Value |
|---|---|
| Repository | memory-graph-visualizer |
| Language | TypeScript/React |
| Type | Web Application |
| Framework | Vite + React 19 |
| Graph Engine | Sigma.js v3 + Graphology |
Purpose
Administrative UI for exploring and debugging the memory knowledge graph:
- Graph Visualization: Real-time exploration of entities and memories using Sigma.js.
- Side-by-Side Preview: Inspect the original document source and precise coordinates for any memory node.
- Search & Retrieval: Debug hybrid search results across JanusGraph and Qdrant.
Technical Architecture
Component Layout
graph TD
App[App] --> GV[GraphViewer]
GV --> SG[SigmaGraph Component]
GV --> SP[SourcePreview Panel]
SG --> Sigma[Sigma.js v3 Engine]
SG --> FA2[ForceAtlas2 Layout]
SP --> DV[DocumentViewer]
DV --> RPDF[react-pdf]
SP --> HO[HighlightOverlay]
Key Libraries
- @react-sigma/core (v5): React bindings for Sigma.js v3.
- @react-sigma/layout-forceatlas2: Integrated force-directed layout.
- react-pdf: PDF rendering engine.
- Graphology: Graph data structure and algorithms.
Side-by-Side Source Preview
The visualizer implements a "Document Intelligence" interface that maps memory nodes back to their exact location in raw documents.
Interaction Flow
- Node Selection: User clicks a "MemoryBlock" node in the graph.
- Component Synchronization:
GraphViewerupdatesselectedNodestate. - Source Resolution:
SourcePreviewextractsSourceLocationmetadata from the memory. - PDF Navigation:
DocumentViewerloads the PDF and navigates to the specificpageNumber. - Coordinate Mapping:
HighlightOverlayrenders translucent highlight boxes using normalized coordinates (0-1), ensuring resolution independence.
Acceptance Criteria (Platform 2.0)
- Migrated to Sigma.js v3 (@react-sigma/core v5)
- High-performance rendering of 5,000+ nodes
- Side-by-side PDF preview with
react-pdf - Precise highlighting using normalized (0-1) coordinates
- Real-time graph layout synchronization