Skip to main content
A in R2R is a knowledge graph that is associated with a specific. Each Graph contains:
  • Entities: Extracted information nodes from documents (e.g., people, places, concepts)
  • Relationships: Connections between entities defining how they relate
  • Communities: LLM generated descriptions of groupings of related entities found from Leiden clustering.
  • Document Mappings: Tracking which documents have contributed to the graph
Key features of Graphs in R2R:
  1. Git-like Model
    • Each Collection has an associated Graph that can diverge independently
    • The pull operation syncs document knowledge into the graph
    • Changes can be experimental without affecting the base Collection and underlying documents
  2. Knowledge Organization
    • Automatic entity and relationship extraction from documents
    • Community detection for hierarchical knowledge organization
    • Support for manual creation and editing of entities, relationships and communities
    • Rich metadata and property management
  3. Access Control
    • Graph operations are tied to Collection permissions
    • Superuser privileges required for certain operations like community building
    • Document-level access checks when pulling content

Core Operations

Entity Management

Similar CRUD endpoints exist by mapping /entities above to for relationships (/relationships) and communities (/communities).