Connector calls, semantic rules, and DuckDB memory keep long runs stable, and stream retry stops chats from stalling. Co-authored-by: Cursor <cursoragent@cursor.com>
22 lines
542 B
Python
22 lines
542 B
Python
"""Feature flags for native business connectors."""
|
|
|
|
from __future__ import annotations
|
|
|
|
import os
|
|
|
|
|
|
def _truthy(name: str, default: str = "0") -> bool:
|
|
return os.environ.get(name, default).strip().lower() in {"1", "true", "yes", "on"}
|
|
|
|
|
|
def native_connectors_v1_enabled() -> bool:
|
|
return _truthy("KAMIDSO_NATIVE_CONNECTORS_V1", "0")
|
|
|
|
|
|
def didar_connector_enabled() -> bool:
|
|
return _truthy("KAMIDSO_DIDAR_CONNECTOR", "0")
|
|
|
|
|
|
def is_production() -> bool:
|
|
return os.environ.get("KAMIDSO_ENV", "").strip().lower() == "production"
|