Skip to content

noworneverev/graphrag-api

Folders and files

NameName
Last commit message
Last commit date
Jan 21, 2025
Dec 23, 2024
Aug 12, 2024
Dec 18, 2024
Dec 17, 2024
Jan 21, 2025
Jan 21, 2025
Dec 17, 2024
Dec 17, 2024
Dec 18, 2024
Dec 18, 2024
Jan 21, 2025

Repository files navigation

GraphRAG API

This project provides a FastAPI-based server implementation for handling both global and local structured searches using GraphRAG.

Installation

Clone the repository and install the required dependencies using the following commands:

git clone [email protected]:noworneverev/graphrag-api.git
cd graphrag-api
python -m venv venv
source venv/bin/activate # for Linux
venv\Scripts\activate # for Windows
pip install -r requirements.txt

Usage

  1. Copy the following files and the lancedb folder into the artifacts folder:
    lancedb
    create_final_communities.parquet
    create_final_community_reports.parquet
    create_final_nodes.parquet
    create_final_entities.parquet
    create_final_relationships.parquet
    create_final_covariates.parquet
    create_final_text_units.parquet
    
  2. Run the API
    python api.py
    

Open http://127.0.0.1:8000/docs/ to see the API documentation.

You can also use the interface at GraphRAG Visualizer to run queries against the server.

search

API Endpoints

  • /search/global: Perform a global search using GraphRAG.
  • /search/local: Perform a local search using GraphRAG.
  • /search/drift: Perform a DRIFT search using GraphRAG.
  • /status: Check if the server is up and running.

About

GraphRAG Server

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages