Spaces:
Paused
Paused
Download app/config.py from MuhammadSaad16/chat: direct link, hf CLI and curl.
- Browser
- Download file 655 Bytes
-
https://huggingface.co/spaces/MuhammadSaad16/chat/resolve/main/app/config.py
- Command line
-
hf download hf://spaces/MuhammadSaad16/chat/app/config.py
-
curl -L -o config.py https://huggingface.co/spaces/MuhammadSaad16/chat/resolve/main/app/config.py
655 Bytes
| # app/config.py | |
| from pydantic_settings import BaseSettings | |
| class Settings(BaseSettings): | |
| # OpenAI Configuration (Required) | |
| OPENAI_API_KEY: str | |
| # Database Configuration (Required) | |
| NEON_DATABASE_URL: str | |
| # Qdrant Vector Database (Required) | |
| QDRANT_URL: str | |
| QDRANT_API_KEY: str | |
| # OpenAI Model Configuration (Optional - defaults provided) | |
| OPENAI_MODEL_CHAT: str = "gpt-4o-mini" | |
| OPENAI_MODEL_EMBEDDING: str = "text-embedding-3-small" | |
| class Config: | |
| env_file = ".env" | |
| env_file_encoding = 'utf-8' | |
| extra = "ignore" # Ignore extra env vars like legacy gemini_api_key | |
| settings = Settings() | |