# LinearRAG

A relation-free graph-construction method for GraphRAG that eliminates LLM token costs during indexing, making graph-based retrieval-augmented generation faster over large corpora.

LinearRAG is a graph-construction method for GraphRAG, graph-based retrieval-augmented generation, that builds its knowledge graph without extracting explicit relations between entities, relying instead on lightweight entity recognition and semantic linking. This removes the large-language-model token cost that relation extraction normally adds during graph construction, and gives the method linear time and space complexity.

It supports deep, multi-hop retrieval through semantic bridging without needing an explicit relational graph, aiming for comprehensive contextual understanding while scaling to large corpora. Usage involves installing Python dependencies, downloading a spaCy language model, a separate biomedical spaCy model for the medical dataset, setting an OpenAI-compatible API key and base URL, and downloading benchmark datasets from Hugging Face.

The paper behind LinearRAG was accepted at ICLR 2026; the same research group has released a related GraphRAG benchmark and several other GraphRAG-adjacent projects.

Website: https://arxiv.org/pdf/2510.10114
