39 lines
881 B
Python
39 lines
881 B
Python
from pathlib import Path
|
|
|
|
from pydantic_settings import BaseSettings
|
|
|
|
_env_file = Path(__file__).resolve().parents[2] / ".env"
|
|
|
|
|
|
class Settings(BaseSettings):
|
|
model_config = {"env_file": str(_env_file), "env_file_encoding": "utf-8"}
|
|
|
|
# Database
|
|
DATABASE_URL: str = "postgresql+asyncpg://velobrain:velobrain@localhost:5432/velobrain"
|
|
|
|
# Anthropic
|
|
ANTHROPIC_API_KEY: str = ""
|
|
|
|
# Gemini
|
|
GEMINI_API_KEY: str = ""
|
|
GEMINI_MODEL: str = "gemini-2.5-pro"
|
|
|
|
# App
|
|
APP_SECRET_KEY: str = "change-me-in-production"
|
|
DEBUG: bool = True
|
|
|
|
# Auth / JWT
|
|
JWT_SECRET_KEY: str = "change-me-jwt-secret"
|
|
JWT_ALGORITHM: str = "HS256"
|
|
JWT_ACCESS_TOKEN_EXPIRE_MINUTES: int = 1440 # 24 hours
|
|
|
|
# Telegram
|
|
TELEGRAM_BOT_TOKEN: str = ""
|
|
TELEGRAM_BOT_USERNAME: str = ""
|
|
|
|
# Upload
|
|
UPLOAD_DIR: str = "./uploads"
|
|
|
|
|
|
settings = Settings()
|