chore: capture semantic pipeline baseline

This commit is contained in:
OpenCode
2026-09-21 15:52:17 -03:00
parent 9dcc263217
commit 6731eeca08
47 changed files with 3724 additions and 15 deletions
+14
View File
@@ -31,6 +31,20 @@ class Settings:
cest_dataset_url: str = os.getenv("CEST_DATASET_URL", "https://www.confaz.fazenda.gov.br/legislacao/convenios/2018/CV142_18")
dataset_storage_path: str = os.getenv("DATASET_STORAGE_PATH", "./data/datasets")
http_timeout_seconds: float = float(os.getenv("HTTP_TIMEOUT_SECONDS", "30"))
# ---- AI semantic layer V1 ----
# Credentials live ONLY in the Hub environment; the Windows Agent never sees them.
ai_enabled: bool = os.getenv("AI_ENABLED", "0") == "1"
ai_provider: str = os.getenv("AI_PROVIDER", "baseline") # baseline | openai | ... (AISemanticProvider)
ai_model: str = os.getenv("AI_MODEL", "baseline-deterministic-v1")
ai_max_batch_size: int = int(os.getenv("AI_MAX_BATCH_SIZE", "20"))
ai_max_run_cost_usd: float = float(os.getenv("AI_MAX_RUN_COST_USD", "5.0"))
ai_min_confidence: float = float(os.getenv("AI_MIN_CONFIDENCE", "0.6"))
ai_price_in_per_m: float | None = float(os.getenv("AI_PRICE_IN_PER_M")) if os.getenv("AI_PRICE_IN_PER_M") else None
ai_price_out_per_m: float | None = float(os.getenv("AI_PRICE_OUT_PER_M")) if os.getenv("AI_PRICE_OUT_PER_M") else None
# Real-LLM evaluation (OpenAI-compatible). The key lives ONLY in this environment.
# Z.ai general endpoint (NOT the /api/coding/paas/v4 coding-plan endpoint).
ai_api_key: str = os.getenv("AI_API_KEY", "")
ai_base_url: str = os.getenv("AI_BASE_URL", "https://api.z.ai/api/paas/v4")
settings = Settings()