Update README.md
Browse files
README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
| 2 |
|
| 3 |
Production-grade Retrieval-Augmented Generation (RAG) backend built with FastAPI, FAISS (ANN), and Google Gemini β featuring hybrid retrieval, HNSW indexing, cross-encoder reranking, evaluation logging, and analytics.
|
| 4 |
|
| 5 |
-
This repository demonstrates how modern AI backend systems are actually built in industry
|
| 6 |
|
| 7 |
π What This Project Is
|
| 8 |
|
|
@@ -96,30 +96,44 @@ Persistent vector store
|
|
| 96 |
|
| 97 |
ποΈ System Architecture
|
| 98 |
|
|
|
|
| 99 |
Frontend (HTML / JS)
|
|
|
|
| 100 |
β
|
|
|
|
| 101 |
FastAPI Backend
|
| 102 |
β
|
|
|
|
| 103 |
Document Ingestion (PDF / TXT)
|
| 104 |
β
|
|
|
|
| 105 |
Sentence Chunking + Metadata
|
| 106 |
β
|
|
|
|
| 107 |
Embeddings (SentenceTransformers)
|
| 108 |
β
|
|
|
|
| 109 |
FAISS ANN Index (HNSW)
|
| 110 |
β
|
|
|
|
| 111 |
Hybrid Retrieval (Vector + Keyword)
|
| 112 |
β
|
|
|
|
| 113 |
Cross-Encoder Reranking
|
| 114 |
β
|
|
|
|
| 115 |
Prompt Assembly
|
| 116 |
β
|
|
|
|
| 117 |
Google Gemini LLM
|
| 118 |
β
|
|
|
|
| 119 |
Answer + Confidence + Citations
|
| 120 |
β
|
|
|
|
| 121 |
Evaluation Logging + Analytics
|
| 122 |
|
|
|
|
| 123 |
π§ Core Concepts Demonstrated
|
| 124 |
Retrieval-Augmented Generation (RAG)
|
| 125 |
|
|
@@ -168,6 +182,7 @@ Clean Git hygiene
|
|
| 168 |
Incremental system evolution
|
| 169 |
|
| 170 |
π οΈ Tech Stack
|
|
|
|
| 171 |
Backend
|
| 172 |
|
| 173 |
Python
|
|
@@ -209,14 +224,30 @@ Virtual Environments (venv)
|
|
| 209 |
βοΈ Setup & Run Locally
|
| 210 |
|
| 211 |
1οΈβ£ Clone Repository
|
|
|
|
| 212 |
git clone https://github.com/LVVignesh/gemini-rag-fastapi.git
|
|
|
|
| 213 |
cd gemini-rag-fastapi
|
|
|
|
|
|
|
|
|
|
| 214 |
python -m venv venv
|
|
|
|
| 215 |
venv\Scripts\activate
|
|
|
|
|
|
|
|
|
|
| 216 |
pip install -r requirements.txt
|
|
|
|
|
|
|
|
|
|
| 217 |
GEMINI_API_KEY=your_api_key_here
|
|
|
|
|
|
|
|
|
|
| 218 |
uvicorn main:app --reload
|
| 219 |
|
|
|
|
| 220 |
β οΈ Known Limitations
|
| 221 |
|
| 222 |
Scanned/image-only PDFs require OCR (not included)
|
|
|
|
| 2 |
|
| 3 |
Production-grade Retrieval-Augmented Generation (RAG) backend built with FastAPI, FAISS (ANN), and Google Gemini β featuring hybrid retrieval, HNSW indexing, cross-encoder reranking, evaluation logging, and analytics.
|
| 4 |
|
| 5 |
+
This repository demonstrates how modern AI backend systems are actually built in industry.
|
| 6 |
|
| 7 |
π What This Project Is
|
| 8 |
|
|
|
|
| 96 |
|
| 97 |
ποΈ System Architecture
|
| 98 |
|
| 99 |
+
|
| 100 |
Frontend (HTML / JS)
|
| 101 |
+
|
| 102 |
β
|
| 103 |
+
|
| 104 |
FastAPI Backend
|
| 105 |
β
|
| 106 |
+
|
| 107 |
Document Ingestion (PDF / TXT)
|
| 108 |
β
|
| 109 |
+
|
| 110 |
Sentence Chunking + Metadata
|
| 111 |
β
|
| 112 |
+
|
| 113 |
Embeddings (SentenceTransformers)
|
| 114 |
β
|
| 115 |
+
|
| 116 |
FAISS ANN Index (HNSW)
|
| 117 |
β
|
| 118 |
+
|
| 119 |
Hybrid Retrieval (Vector + Keyword)
|
| 120 |
β
|
| 121 |
+
|
| 122 |
Cross-Encoder Reranking
|
| 123 |
β
|
| 124 |
+
|
| 125 |
Prompt Assembly
|
| 126 |
β
|
| 127 |
+
|
| 128 |
Google Gemini LLM
|
| 129 |
β
|
| 130 |
+
|
| 131 |
Answer + Confidence + Citations
|
| 132 |
β
|
| 133 |
+
|
| 134 |
Evaluation Logging + Analytics
|
| 135 |
|
| 136 |
+
|
| 137 |
π§ Core Concepts Demonstrated
|
| 138 |
Retrieval-Augmented Generation (RAG)
|
| 139 |
|
|
|
|
| 182 |
Incremental system evolution
|
| 183 |
|
| 184 |
π οΈ Tech Stack
|
| 185 |
+
|
| 186 |
Backend
|
| 187 |
|
| 188 |
Python
|
|
|
|
| 224 |
βοΈ Setup & Run Locally
|
| 225 |
|
| 226 |
1οΈβ£ Clone Repository
|
| 227 |
+
|
| 228 |
git clone https://github.com/LVVignesh/gemini-rag-fastapi.git
|
| 229 |
+
|
| 230 |
cd gemini-rag-fastapi
|
| 231 |
+
|
| 232 |
+
2οΈβ£ Create Virtual Environment
|
| 233 |
+
|
| 234 |
python -m venv venv
|
| 235 |
+
|
| 236 |
venv\Scripts\activate
|
| 237 |
+
|
| 238 |
+
3οΈβ£ Install Dependencies
|
| 239 |
+
|
| 240 |
pip install -r requirements.txt
|
| 241 |
+
|
| 242 |
+
4οΈβ£ Configure Environment Variables
|
| 243 |
+
|
| 244 |
GEMINI_API_KEY=your_api_key_here
|
| 245 |
+
|
| 246 |
+
5οΈβ£ Run Server
|
| 247 |
+
|
| 248 |
uvicorn main:app --reload
|
| 249 |
|
| 250 |
+
|
| 251 |
β οΈ Known Limitations
|
| 252 |
|
| 253 |
Scanned/image-only PDFs require OCR (not included)
|