Guide Home 1. Solution Topology 2. Aspire as 3. Shared Configuration 4. Metadata with 5. Upload API 6. Object Storage 7. Worker Ingestion 8. Extracting and 9. Literary Artifacts 10. AI Provider 11. Qdrant Vector 12. Ask Flow 13. Prompting and 14. Testing the 15. Local Development All Guides
Guide navigationIndex and chapters
Chapter 11

Qdrant Vector Storage

RAG.Core/Services/QdrantVectorStore.cs owns Qdrant interaction.

Decorative chapter image for Qdrant Vector Storage
Each vector carries citation payload
new Dictionary<string, object?>
{
    ["documentId"] = chunk.Chunk.DocumentId.ToString(),
    ["fileName"] = chunk.Chunk.FileName,
    ["chunkIndex"] = chunk.Chunk.ChunkIndex,
    ["text"] = chunk.Chunk.Text,
    ["chunkType"] = chunk.Chunk.ChunkType
}

RAG.Core/Services/QdrantVectorStore.cs owns Qdrant interaction.

Each point stores:

The vector search endpoint returns matching chunks and payloads. Payloads become citations, diagnostics, and LLM context. Preserving provenance in Qdrant means a generated book-club profile can survive the round trip from ingestion to retrieval to citation rendering without being confused with source text.

The store also supports two non-vector retrieval helpers:

These exist because vector search is not always enough. If a user asks a comparison question with named characters, exact-name lookup can ensure each named subject contributes evidence.

That is how the project handles questions like:

Can you find any similarities between Calpurnia and Hermione?

Pure top-k semantic retrieval may over-focus on one book. The improved retrieval path combines semantic search, profile chunks, and exact-name chunks.

The vector store also has a document-level delete operation. Reindexing and deletion both call DeleteDocumentAsync so old vector points do not remain after derived data changes or a user removes a document.