AI generated first iteration
This commit is contained in:
39
app/config.py
Normal file
39
app/config.py
Normal file
@@ -0,0 +1,39 @@
|
||||
"""Configuration management using pydantic-settings."""
|
||||
|
||||
from pydantic_settings import BaseSettings
|
||||
from typing import Optional
|
||||
|
||||
|
||||
class Settings(BaseSettings):
|
||||
"""Application configuration loaded from environment variables."""
|
||||
|
||||
# App
|
||||
APP_NAME: str = "Sanctum Chronicler"
|
||||
APP_ENV: str = "development"
|
||||
DEBUG: bool = False
|
||||
|
||||
# Database
|
||||
DATABASE_URL: str = "postgresql+asyncpg://sanctum:password@localhost:5432/sanctum"
|
||||
|
||||
# Twitch
|
||||
TWITCH_CLIENT_ID: Optional[str] = None
|
||||
TWITCH_CLIENT_SECRET: Optional[str] = None
|
||||
TWITCH_BOT_USERNAME: Optional[str] = None
|
||||
TWITCH_CHANNEL_NAME: Optional[str] = None
|
||||
|
||||
# LLM
|
||||
LLM_PROVIDER: Optional[str] = None # "openai", "ollama", "lm_studio", or None
|
||||
LLM_BASE_URL: Optional[str] = None
|
||||
LLM_API_KEY: Optional[str] = None
|
||||
LLM_MODEL: str = "gpt-3.5-turbo"
|
||||
|
||||
# Export
|
||||
EXPORT_PATH: str = "exports"
|
||||
|
||||
class Config:
|
||||
env_file = ".env"
|
||||
env_file_encoding = "utf-8"
|
||||
case_sensitive = True
|
||||
|
||||
|
||||
settings = Settings()
|
||||
Reference in New Issue
Block a user