-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.py
More file actions
26 lines (21 loc) · 830 Bytes
/
app.py
File metadata and controls
26 lines (21 loc) · 830 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
"""Main FastAPI Application Entry Point."""
import uvicorn
from fastapi import FastAPI
from backend.app.routers.health_checker import health_checker_router
from backend.app.routers.question_router import question_router
from backend.app.routers.upload_document_router import documents_router
from logs.log_generator import log_message
from settings import SETTINGS_VAR
app = FastAPI(
title="Tractian Challenge - RAG API",
description="API for Document Ingestion and Retrieval Augmented Generation",
version="1.0.0",
)
app.include_router(documents_router)
app.include_router(question_router)
app.include_router(health_checker_router)
if __name__ == "__main__":
log_message("Booting API...", "info")
uvicorn.run(
"app:app", host=SETTINGS_VAR.API_HOST, port=SETTINGS_VAR.API_PORT, reload=False
)