File size: 817 Bytes
0ce8172 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | import os
from pathlib import Path
from dotenv import load_dotenv
load_dotenv()
AI_NAME = os.getenv("AI_NAME", "LittleFox")
# Optional local integrations
WOLFRAM_APP_ID = os.getenv("WOLFRAM_APP_ID", "")
TESSERACT_PATH = os.getenv("TESSERACT_PATH", "")
# Runtime mode marker for the rest of the app
DEFAULT_MODE = "offline_local"
_use_tiny_model_raw = os.getenv("USE_TINY_MODEL", "auto").strip().lower()
if _use_tiny_model_raw in {"auto", ""}:
USE_TINY_MODEL = Path("models/tiny_local_model.pt").exists()
else:
USE_TINY_MODEL = _use_tiny_model_raw in {"1", "true", "yes", "on"}
ENABLE_WEB_TRAINING = os.getenv("ENABLE_WEB_TRAINING", "1").strip().lower() in {"1", "true", "yes", "on"}
AUTO_WEB_SEARCH_FALLBACK = os.getenv("AUTO_WEB_SEARCH_FALLBACK", "0").strip().lower() in {"1", "true", "yes", "on"}
|