Retrieval-Augmented Generation (RAG) systems universally rely on cosine similarity in flat embedding spaces, treating each knowledge fact as an independent point. This fails for chain-structured knowledge where the answer spans a sequence of connected steps; retrieval finds facts near the query but misses intermediate steps along the path. We propose Manifold Retrieval, which constructs a Riemannian manifold over the embedding space using diffusion maps and retrieves along geodesic shortest paths rather than within cosine similarity balls. Our method builds a k-nearest-neighbor graph with locally-scaled Gaussian kernels over 75,867 cybersecurity knowledge facts, computes a 12-dimensional diffusion map embedding, and retrieves facts along Dijkstra geodesics on the resulting manifold graph. We further incorporate Dynamic Time Warping (DTW) shape matching against known procedural chain signatures and Nyström extension for projecting unseen queries onto the manifold at inference time. Evaluated against a FAISS cosine baseline and an LLM-augmented retrieval system, Manifold Retrieval achieves +8% Recall@10 and +22% path completeness over the baseline at 2.4 seconds per query, 5× faster than the LLM-augmented approach with zero regression on Recall@5. The method requires only embeddings and is domain-agnostic: no entity extraction, schema design, or graph construction is needed beyond the embedding model itself.
Benjamin Olenick (Thu,) studied this question.