44 lines
1.2 KiB
Python
44 lines
1.2 KiB
Python
from pydantic_settings import BaseSettings, SettingsConfigDict
|
|
|
|
|
|
class Settings(BaseSettings):
|
|
model_config = SettingsConfigDict(env_file=".env", env_file_encoding="utf-8", extra="ignore")
|
|
|
|
# Database
|
|
database_url: str = "postgresql://postgres:postgres@localhost:5432/kg_db"
|
|
db_schema: str = "kg_admin"
|
|
db_migrations_enabled: bool = True
|
|
|
|
# FalkorDB
|
|
falkordb_host: str = "localhost"
|
|
falkordb_port: int = 6379
|
|
falkordb_graph: str = "guiyang"
|
|
falkordb_password: str = ""
|
|
|
|
# Auth
|
|
auth_secret: str = "change-me-at-least-32-chars-long-secret"
|
|
auth_algorithm: str = "HS256"
|
|
auth_token_expire_minutes: int = 480
|
|
auth_default_username: str = "admin@example.com"
|
|
auth_default_password: str = "admin"
|
|
|
|
# LLM
|
|
llm_api_base: str = ""
|
|
llm_api_key: str = ""
|
|
llm_model: str = "deepseek-chat"
|
|
llm_timeout_seconds: int = 30
|
|
llm_extraction_enabled: bool = False
|
|
|
|
# App
|
|
default_tenant: str = "guiyang"
|
|
default_project: str = "default"
|
|
ingest_api_keys: str = "dev-key-1"
|
|
|
|
# AMap / Gaode JS API
|
|
amap_web_key: str = ""
|
|
amap_js_key: str = ""
|
|
amap_security_jscode: str = ""
|
|
|
|
|
|
settings = Settings()
|