ci_inputs_system / ci_sync_monitor.py
Ihorog's picture
Rename ci_sinc_monitor.py to ci_sync_monitor.py
935bd79 verified
raw
history blame contribute delete
885 Bytes
from datetime import datetime
from typing import Dict
class CiSyncMonitor:
def __init__(self):
self.log_file = "memory.log"
def log_event(self, event: Dict[str, str]):
with open(self.log_file, "a", encoding="utf-8") as f:
f.write(f"{datetime.now().isoformat()} | {event['назва']} | {event['вузлові_показники'] if 'вузлові_показники' in event else '-'}\n")
def check_alignment(self, event):
фаза = event.get("вузлові_показники", {}).get("фаза", "")
if фаза.startswith("інь"):
print("[ALIGN] → Спокійна фаза, можливе розширення ідей (Malja)")
elif фаза.startswith("ян"):
print("[ALIGN] → Активна фаза, ініціація подій (PoDija)")
sync_monitor = CiSyncMonitor()