Digitala Vetenskapliga Arkivet

Change search
CiteExportLink to record
Permanent link

Direct link
Cite
Citation style
  • apa
  • ieee
  • modern-language-association-8th-edition
  • vancouver
  • Other style
More styles
Language
  • de-DE
  • en-GB
  • en-US
  • fi-FI
  • nn-NO
  • nn-NB
  • sv-SE
  • Other locale
More languages
Output format
  • html
  • text
  • asciidoc
  • rtf
Evaluating Graph Retrieval-Augmented Generation with Neo4j and FAISS: A Performance Comparison in Hybrid Retrieval Systems
KTH, School of Electrical Engineering and Computer Science (EECS).
KTH, School of Electrical Engineering and Computer Science (EECS).
2025 (English)Independent thesis Basic level (degree of Bachelor), 10 credits / 15 HE creditsStudent thesisAlternative title
Utvärdering av grafbaserad Retrieval-Augmented Generation med Neo4j och FAISS : En prestandajämförelse i hybrida söksystem (Swedish)
Abstract [en]

Graph-based Retrieval-Augmented Generation (GraphRAG) is a method that improves the performance of large language models by combining semantic vector search with reasoning over a Knowledge Graph (KG). This enables the system to retrieve not only semantically similar documents, but also the explicit relationships between entities. This thesis compares two retrieval systems within the GraphRAG framework: one using Neo4j’s built-in vector search and graph traversal, and another combining Facebook AI Similarity Search (FAISS) for vector search with Neo4j for graph-based retrieval. Both systems were tested on a biomedical dataset from PubMed, with embeddings generated using a standard Sentence-Transformers model. The evaluation focuses on three key aspects: accuracy, latency, and scalability. The results show that while Neo4j offers seamless integration between vectors and graph data, the FAISS–Neo4j hybrid pipeline performs better in terms of accuracy, latency, and scalability, especially under larger workloads. These findings help clarify the strengths and limitations of each system and provide guidance on when to choose a fully integrated solution versus a specialised hybrid approach in knowledge-intensive retrieval tasks.

Abstract [sv]

GraphRAG är en metod som förbättrar prestandan hos stora språkmodeller genom att kombinera semantisk vektorsökning med informationshämtning baserad på relationer i ett KG. Detta gör det möjligt för systemet att inte endast hämta semantiskt liknande dokument, utan även explicita relationer mellan entiteter. Detta examensarbete jämför två söksystem inom GraphRAG-ramverk: ett som använder Neo4js inbyggda vektorsökning och graftraversering, och ett annat som kombinerar FAISS för vektorsökning med Neo4j för grafbaserad hämtning. Båda systemen testades på en biomedicinsk datamängd från PubMed, med inbäddningar genererade med en standardmodell från Sentence-Transformers. Utvärderingen fokuserar på tre centrala aspekter: noggrannhet, letens och skalbarhet. Resultaten visar att även om Neo4j erbjuder en smidig integration mellan vektorer och grafdata, presterar den hybrida FAISS–Neo4j pipelinen bättre när det gäller noggrannhet, latens och skalbarhet, särskilt vid större datamängder. Dessa resultat klargör styrkor och begränsningar hos respektive system och ger vägledning om när man bör välja en helintegrerad lösning eller en specialiserad hybridlösning för kunskapsintensiva sökuppgifter.

Place, publisher, year, edition, pages
2025. , p. 75
Series
TRITA-EECS-EX ; 2025:457
Keywords [en]
RAG, GraphRAG, Vector Search, Neo4j, FAISS, Hybrid Retrieval Systems
Keywords [sv]
RAG, GraphRAG, Vektorsökning, Neo4j, FAISS, Hybrida söksystem
National Category
Computer and Information Sciences
Identifiers
URN: urn:nbn:se:kth:diva-368024OAI: oai:DiVA.org:kth-368024DiVA, id: diva2:1986682
Supervisors
Examiners
Available from: 2025-08-10 Created: 2025-08-01 Last updated: 2025-08-10Bibliographically approved

Open Access in DiVA

fulltext(2086 kB)828 downloads
File information
File name FULLTEXT01.pdfFile size 2086 kBChecksum SHA-512
5e613f52e9df4e14aebf390ffa189c059312552a8fae709ba241862ebeac32646ce924fad6cbeb01a71f8848028f5aac0dc425ead674ffb8c6020045459ba8d8
Type fulltextMimetype application/pdf

By organisation
School of Electrical Engineering and Computer Science (EECS)
Computer and Information Sciences

Search outside of DiVA

GoogleGoogle Scholar
Total: 830 downloads
The number of downloads is the sum of all downloads of full texts. It may include eg previous versions that are now no longer available

urn-nbn

Altmetric score

urn-nbn
Total: 1294 hits
CiteExportLink to record
Permanent link

Direct link
Cite
Citation style
  • apa
  • ieee
  • modern-language-association-8th-edition
  • vancouver
  • Other style
More styles
Language
  • de-DE
  • en-GB
  • en-US
  • fi-FI
  • nn-NO
  • nn-NB
  • sv-SE
  • Other locale
More languages
Output format
  • html
  • text
  • asciidoc
  • rtf