liveBook · Manning

Hierarchical community structure

As explained in Essential GraphRAG

A community hierarchy is an arrangement of graph communities across levels of increasing abstraction or aggregation.

A hierarchical community structure organizes graph communities at multiple granularities, supporting analysis of broad groups alongside finer subcommunities. Community detection assigns entities to groups, while generated summaries make those groups usable for retrieval. section 7.2.4

The smaller GraphRAG implementation uses one community level and therefore skips hierarchical processing. The hierarchy remains a design choice for larger graphs and broad information-discovery tasks. section 7.3.1 section 7.2.4

Selecting a community level creates a practical detail–efficiency trade-off:

  • Lower-level communities provide more detailed reports but require more LLM calls and processing time. section 7.3.1
  • Higher-level communities improve efficiency through more abstract summaries but can lose useful granularity. section 7.3.1
  • Community counts and sizes depend on graph structure, and Louvain results can vary between runs. section 7.2.4

Using communities for global search

A global retriever selects community summaries at a chosen hierarchy level, maps each summary to rated key points, filters and aggregates the strongest points, and gives them to an LLM for final synthesis. section 7.3.1

Figure 7.4 Global search
figure

Use the global-search diagram to trace how community-level summaries become intermediate evidence and then a synthesized answer. section 7.3.1

How Essential GraphRAG covers it

How deep it goes
Defines multiple granularities and their trade-offs but stops short of implementing hierarchy in the smaller graph.
Examples
Uses Louvain-detected communities, generated community reports, and a global-retriever query as concrete artifacts.
What it assumes
Assumes graph communities have been detected and summarized before hierarchy-aware retrieval begins.
What you can do after
Apply it via GraphRAG to select summary granularity and balance retrieval detail against processing cost.
How it connects
Connects community detection, Louvain algorithm, community summarization, GraphRAG, and global search.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Essential GraphRAG. The section links point to the parts of the book it draws on.