Practical overview
When it fits
Use Linearrag when you want a codebase for prototyping or studying graph-based retrieval over a corpus and can supply its local models, dataset, and API configuration.
Who it is for
- Researchers studying GraphRAG construction and retrieval.
- Developers prototyping RAG systems over large document collections.
- Practitioners comparing retrieval approaches and construction-time LLM token use.
Documented uses
- Prepare a graph-based retrieval workflow using a dataset, embedding model, spaCy model, and LLM configuration.
- Explore relation-free graph construction intended to avoid LLM token costs during graph construction.
- Run the documented multi-hop dataset example and optionally select vectorized retrieval when a strong GPU is available.
Requirements & limits
The repository is public and lists a GPL-3.0 license.
- The documented workflow requires local Python dependencies, a spaCy model, dataset files, an embedding model, and OpenAI API configuration.
- The README prefers Python 3.9.
- The optional vectorized retrieval mode is described for strong GPUs; BFS iteration is the stated alternative.
- The medical dataset requires a separate scientific/biomedical spaCy model.
Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.
Run the documented 2wikimultihop example
Use the repository's example command with its stated dataset and model settings.
Before you start
- The setup prerequisites described in the repository README
- A configured spaCy model, embedding model, dataset, and LLM model
- GPU acceleration is relevant only if enabling the optional vectorized retrieval mode
Steps
Set SPACY_MODEL to en_core_web_trf and EMBEDDING_MODEL to model/all-mpnet-base-v2.
Set DATASET_NAME to 2wikimultihop and LLM_MODEL to gpt-4o-mini.
Set MAX_WORKERS to 16.
Run python run.py with the documented --spacy_model, --embedding_model, --dataset_name, --llm_model, and --max_workers arguments.
Enable --use_vectorized_retrieval only when using the optional GPU-oriented retrieval path; otherwise use the documented BFS iteration approach.
Expected outcome
The repository's example workflow is invoked with the listed dataset and model configuration.
Guide limitations
- The README does not make the optional vectorized mode a requirement and recommends it only with a strong GPU.
- The command and setup are documented instructions, not an execution or compatibility guarantee.
Compare options for Retrieval-augmented applications
These projects document a common task and share a project role. This is a source-based comparison, not an execution benchmark or a guarantee of interchangeability.
| Project | Documented purpose | Platform | Access and requirements |
|---|---|---|---|
| Linearrag | Prepare a graph-based retrieval workflow using a dataset, embedding model, spaCy model, and LLM configuration. | Linux, macOS, Windows | The repository is public and lists a GPL-3.0 license. |
| Langsearch | Crawl website or local data for a knowledge base. | CLI, Self-hosted, Server | |
| Hybrid Search Rag | Combine document retrieval and language-model generation in a configurable workflow. |
Sources & review
Source record details
- Source availability
- Active
- Sources checked
- 9 October 2026
- Original website title
- DEEP-PolyU/LinearRAG · Official homepage title · retained in its source language

