snapshot: NODE1 production state 2026-02-09

Complete snapshot of /opt/microdao-daarion/ from NODE1 (144.76.224.179).
This represents the actual running production code that has diverged
significantly from the previous main branch.

Key changes from old main:
- Gateway (http_api.py): expanded from ~40KB to 164KB with full agent support
- Router: new /v1/agents/{id}/infer endpoint with vision + DeepSeek routing
- Behavior Policy: SOWA v2.2 (3-level: FULL/ACK/SILENT)
- Agent Registry: config/agent_registry.yml as single source of truth
- 13 agents configured (was 3)
- Memory service integration
- CrewAI teams and roles

Excluded from snapshot: venv/, .env, data/, backups, .tgz archives

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Apple
2026-02-09 08:46:46 -08:00
parent 134c044c21
commit ef3473db21
9473 changed files with 408933 additions and 2769877 deletions

View File

@@ -14,12 +14,14 @@ import logging
import os
import subprocess
import tempfile
import time
from pathlib import Path
import httpx
from minio import Minio
from minio.error import S3Error
from nats.aio.client import Client as NATS
import nats.errors
logging.basicConfig(level=logging.INFO)
logger = logging.getLogger(__name__)
@@ -32,6 +34,9 @@ MINIO_SECRET_KEY = os.getenv("MINIO_SECRET_KEY", "minioadmin")
MINIO_BUCKET = os.getenv("MINIO_BUCKET", "artifacts")
MINIO_SECURE = os.getenv("MINIO_SECURE", "false").lower() == "true"
# Rate-limit for "idle, no messages" log (seconds)
IDLE_LOG_INTERVAL = int(os.getenv("RENDER_PDF_IDLE_LOG_INTERVAL", "60"))
minio_client = Minio(
MINIO_ENDPOINT,
access_key=MINIO_ACCESS_KEY,
@@ -130,8 +135,16 @@ async def main() -> None:
nc = NATS()
await nc.connect(servers=[NATS_URL])
sub = await nc.subscribe("artifact.job.render_pdf.requested")
last_idle_log = 0.0
while True:
msg = await sub.next_msg()
try:
msg = await sub.next_msg()
except nats.errors.TimeoutError:
now = time.monotonic()
if now - last_idle_log >= IDLE_LOG_INTERVAL:
logger.info("idle, no messages (subject=artifact.job.render_pdf.requested)")
last_idle_log = now
continue
try:
payload = msg.data.decode("utf-8")
data = json.loads(payload)
@@ -142,5 +155,4 @@ async def main() -> None:
if __name__ == "__main__":
import json
asyncio.run(main())