Spaces:
Sleeping
Sleeping
| # api/config.py | |
| import os | |
| import logging | |
| from typing import Optional | |
| # Setup logging | |
| logging.basicConfig( | |
| level=logging.INFO, | |
| format='%(asctime)s - %(name)s - %(levelname)s - %(message)s' | |
| ) | |
| logger = logging.getLogger(__name__) | |
| class Settings: | |
| """Application settings""" | |
| APP_TITLE: str = "Legal Assistant API" | |
| APP_VERSION: str = "2.0.0" | |
| APP_DESCRIPTION: str = "Multi-country legal RAG with streaming & human-in-the-loop" | |
| # CORS | |
| CORS_ORIGINS: list = ["*"] | |
| # API Settings | |
| STREAM_DELAY: float = 0.02 # Delay between tokens in streaming | |
| # System | |
| chat_manager: Optional[object] = None | |
| graph: Optional[object] = None | |
| system_initialized: bool = False | |
| settings = Settings() |