feat: add Pydantic Settings configuration

This commit is contained in:
2026-05-25 18:41:57 +02:00
parent 5103c327ae
commit 8b75fb438f
4 changed files with 175 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
from pydantic_settings import BaseSettings
class Settings(BaseSettings):
api_host: str = "0.0.0.0"
api_port: int = 8000
api_key: str
rate_limit_per_minute: int = 10
rate_limit_per_hour: int = 100
worker_url: str = "http://claude-worker:3001"
db_path: str = "/data/opus-agent.db"
claude_model: str = "claude-sonnet-4-6"
model_config = {
"env_file": ".env",
"env_file_encoding": "utf-8",
}
settings = Settings()