---
title: GraphRAG Backend
emoji: π¦
colorFrom: red
colorTo: pink
sdk: docker
---
π Financial Corporate GraphRAG
Massive-scale, graph-powered retrieval-augmented generation built for the TigerGraph Hackathon
[](https://opensource.org/licenses/MIT)
[](https://www.python.org/)
[](https://www.tigergraph.com/)
[](https://deepmind.google/technologies/gemini/)
[](#-the-benchmark-data)
---
## π Table of Contents
- [What is this?](#-what-is-this)
- [The Benchmark Data](#-the-benchmark-data)
- [System Architecture](#-system-architecture)
- [Advanced Graph Schema](#-advanced-graph-schema)
- [Quick Start Guide](#-quick-start-guide)
- [1. Database Setup](#1-database-setup-tigergraph)
- [2. Backend Setup](#2-backend-setup-fastapi)
- [3. Frontend Dashboard](#3-frontend-dashboard)
- [The Magic Query (GSQL)](#-the-magic-query-gsql)
---
## π‘ What is this?
Traditional RAG (Retrieval-Augmented Generation) struggles with complex, multi-hop financial queries because it relies on flat vector similarity.
**This project solves that.** We built a GraphRAG pipeline that ingests SEC EDGAR 10-K financial filings, extracts intricate corporate relationships (competitors, subsidiaries, risk factors) using **Gemini 2.5 Flash**, and stores them securely in **TigerGraph**.
The result? An AI that can answer complex questions like: *"What supply chain risks does Apple face, and which of their competitors are exposed to the exact same risks?"*
---
## π The Benchmark Data
This project processed over 105 million tokens from SEC 10-K filings to extract the entities and relationships used to construct the knowledge graph.