Add real-time market truth layer

This commit is contained in:
Codex
2026-05-07 00:12:12 +08:00
parent 057c1debd0
commit 82c1f20879
27 changed files with 2398 additions and 39 deletions
+4 -1
View File
@@ -11,6 +11,7 @@ if str(ROOT) not in sys.path:
sys.path.insert(0, str(ROOT))
from src.services.execution import AccountRiskState, ExecutionService
from src.services.market_state import MarketStateService, get_market_truth_supervisor
def build_account_risk_state_from_env(env=None) -> AccountRiskState:
@@ -31,7 +32,9 @@ def build_account_risk_state_from_env(env=None) -> AccountRiskState:
def main(env=None) -> int:
env = os.environ if env is None else env
output_json = _get_bool(env, "EXECUTION_OUTPUT_JSON", False)
service = ExecutionService()
service = ExecutionService(
market_state_service=MarketStateService(market_truth_supervisor=get_market_truth_supervisor())
)
signal_id = 1
execution_mode = "paper"
account_state = build_account_risk_state_from_env(env=env)