Files
Meeting-AI-Orchestration-Demo/backend/app/config.py
2026-06-27 13:50:11 +03:00

39 lines
1.4 KiB
Python

from functools import lru_cache
from pydantic import Field
from pydantic_settings import BaseSettings, SettingsConfigDict
class Settings(BaseSettings):
"""Runtime configuration shared by API, workers, and simulator."""
model_config = SettingsConfigDict(env_file=".env", env_file_encoding="utf-8", extra="ignore")
app_name: str = "AI Orchestrator Wedding Demo"
environment: str = "local"
database_url: str = "sqlite:///./orchestrator.db"
redis_url: str = "redis://redis:6379/0"
qdrant_url: str = "http://qdrant:6333"
anthropic_api_key: str | None = None
anthropic_model: str = "claude-sonnet-4-6"
wed_api_base_url: str = "http://localhost:8000"
wed_api_openapi_url: str | None = None
wed_api_bearer_token: str | None = None
wed_default_partner_id: str | None = None
wed_guest_first_name: str = "Demo"
wed_guest_last_name: str = "Customer"
wed_guest_email: str = "demo.customer@example.com"
wed_guest_phone: str | None = None
soniox_api_key: str | None = None
soniox_model: str = "stt-async-preview"
soniox_poll_interval_seconds: float = 3.0
soniox_poll_attempts: int = 240
planner_confidence_threshold: float = 0.72
backend_base_url: str = "http://localhost:9000"
cors_origins: list[str] = Field(default_factory=lambda: ["http://localhost:5173", "http://127.0.0.1:5173"])
@lru_cache
def get_settings() -> Settings:
return Settings()