Skip to main content
Version: 0.0.6

Installation

To use Agentic GraphRAG, install agentic-graphrag from your Python package manager, for example pip:

pip install agentic-graphrag

If you are using uv, create a virtual environment and install the package into it:

uv venv
uv pip install agentic-graphrag

To install uv, see the installation docs.

Agentic GraphRAG needs Python 3.11 or newer. It also needs a Neo4j database to store the graph. The Quickstart lists the connection settings.

The base install includes the loaders, the chunkers, the data models, and the default embedder. Storage, extraction, the agent, and the MCP server are extras.

Alternative PyTorch distributions

The embed-local, extract, and docling extras depend on PyTorch. Depending on your hardware, pick a different distribution of torch, for example a CPU-only build or a build for another accelerator. The PyTorch install page lists all the ways to install torch.

When you install with uv, add --torch-backend=auto. uv looks for a GPU driver. It installs the build that matches the driver, or the CPU build when it finds no GPU.

uv pip install "agentic-graphrag[neo4j,extract]" --torch-backend=auto

To always install the CPU build, use --torch-backend=cpu. This flag is a uv preview feature. It needs uv 0.6.9 or newer.

What the base install includes​

The base install has the parts of Agentic GraphRAG that need no database, no GPU, and no LLM client:

  • The data models, such as the graph schema and the search result.
  • Loaders for files, directories, and raw text. Docling reads Markdown, HTML, AsciiDoc, Word, PowerPoint, and Excel files without a model. Other loaders read plain text, XML, CSV, and JSON.
  • The section chunker, which packs the sections of every document into chunks.
  • The default embedder, which runs ONNX embedding models on the CPU.
  • The OpenTelemetry API calls that trace each step. Without the observability extra, these calls do nothing.

To build and search a graph, you also need a graph store and an extractor. Each one is an extra.

Available extras​

Other parts of Agentic GraphRAG need more third-party packages. These packages install only if you select them as extras. If an extra is missing, Agentic GraphRAG raises an error that names the extra to install.

The following table lists the extras. Install them with pip install "agentic-graphrag[NAME1,NAME2]" or uv pip install "agentic-graphrag[NAME1,NAME2]".

ExtraDescription
neo4jInstalls the Neo4j graph store and its native vector index.
embed-localInstalls Sentence Transformers, to embed with models that the default embedder does not support.
extractInstalls GLiNER 2.5, to run entity extraction on your machine.
llmInstalls BAML, to extract entities and review matches with an LLM.
agentsInstalls LangGraph, DeepAgents, and the LangChain OpenAI client for the built-in agent.
mcpInstalls the MCP SDK for the agrag-mcp server.
doclingInstalls the Docling layout and table models, to read PDF and image files.
observabilityInstalls the OpenTelemetry SDK, the OTLP exporter, and the asyncio and LangChain instrumentation.
communityInstalls Leiden community detection.
evalInstalls DeepEval, AgentEvals, er-evaluation, scikit-learn, the LangChain OpenAI client, and OpenTelemetry tracing support for the metrics in agrag.eval.
schema-formatsInstalls rdflib for OWL and RDFS Turtle imports.

Extras by goal​

GoalExtras
Build a first graph (the Quickstart)neo4j,extract
Also ask questions with the agentneo4j,extract,agents
Give an MCP client access to the graphneo4j,mcp
Read PDF and image filesAdd docling
Extract with an LLM instead of a local modelneo4j,llm
Find communities of related entitiesAdd community
Record tracesAdd observability
Measure answer qualityAdd eval and agents

Next steps​

Follow the Quickstart to build your first graph.