{
  "schema_version": 1,
  "diagram_type": "architecture",
  "meta": {
    "title": "Curren Quant Intelligence Platform",
    "subtitle": "Capability → responsibility → implementation technology",
    "quality_profile": "showcase",
    "visual_preset": "blueprint",
    "views": [
      {"id":"research","label":"Research core","focus":["market-data","canonical-market","timeframes","primitives","event-factory","event-store","hypothesis-view","oos-selection","alpha-history","nautilus-bridge","streaming-parity"],"note":"Rust/Python causal computation, Arrow/Parquet evidence, DuckDB/Polars views, OOS selection and execution-simulation parity."},
      {"id":"runtime","label":"Signal runtime","focus":["source-data","signal-runtime","ml-gate","lifecycle-risk","execution","reconciliation","publication"],"note":"Python/FastAPI signal orchestration, fail-closed ML quality, durable lifecycle state, guarded venue execution and reconciliation."},
      {"id":"product","label":"Product surface","focus":["publication","public-read-model","api-clients","subscriber-delivery","social-factory","access","marketing"],"note":"Next.js/FastAPI/product services consume approved projections and remain isolated from private trading authority."},
      {"id":"full","label":"Full system","focus":[],"note":"Cross-system platform view showing technology choices at the capability boundary rather than repository topology."}
    ]
  },
  "components": [
    {"id":"market-data","type":"external","label":"Exchange market data","sublabel":"closed bars · funding · PIT availability","tech":"Binance · Bybit APIs","pos":[40,110],"size":[170,82]},
    {"id":"canonical-market","type":"database","label":"Canonical PIT market","sublabel":"immutable market evidence","tech":"Arrow · Parquet","pos":[250,110],"size":[185,82],"tag":"research truth"},
    {"id":"timeframes","type":"backend","label":"Shared timeframe store","sublabel":"causal resampling","tech":"Rust · Python","pos":[475,110],"size":[180,82]},
    {"id":"primitives","type":"backend","label":"Shared primitive store","sublabel":"ATR · RSI · OBV · pivots · regimes","tech":"Rust · Python · NumPy","pos":[695,110],"size":[195,82]},
    {"id":"event-factory","type":"backend","label":"Causal event factory","sublabel":"shared event semantics","tech":"Rust core · Python interface","pos":[930,105],"size":[185,90],"tag":"shared core"},
    {"id":"event-store","type":"database","label":"Versioned PIT event store","sublabel":"partitions · manifests · hashes","tech":"Arrow · Parquet","pos":[1155,105],"size":[205,90]},
    {"id":"hypothesis-view","type":"backend","label":"Hypothesis view engine","sublabel":"predicates · joins · windows","tech":"DuckDB · Polars · Python","pos":[1155,250],"size":[205,92]},
    {"id":"oos-selection","type":"security","label":"OOF / multiplicity selection","sublabel":"purge · embargo · holdout discipline","tech":"Python · SciPy · Statsmodels","pos":[930,250],"size":[185,92]},
    {"id":"alpha-history","type":"database","label":"Alpha History","sublabel":"append-only pass/fail lineage","tech":"Python · Parquet manifests","pos":[695,250],"size":[195,92]},
    {"id":"nautilus-bridge","type":"backend","label":"Execution simulation bridge","sublabel":"orders · fills · portfolio · risk","tech":"NautilusTrader","pos":[475,250],"size":[180,92]},
    {"id":"streaming-parity","type":"security","label":"Offline ↔ streaming parity","sublabel":"replay · restart · catch-up · identity","tech":"Rust/Python replay contracts","pos":[250,250],"size":[185,92],"tag":"release gate"},

    {"id":"source-data","type":"external","label":"External alpha-source data","sublabel":"normalized source observations","tech":"Python adapters","pos":[40,470],"size":[190,82]},
    {"id":"signal-runtime","type":"backend","label":"Signal intelligence runtime","sublabel":"candidate parsing · scoring · state","tech":"Python · FastAPI","pos":[280,465],"size":[200,90],"tag":"production"},
    {"id":"ml-gate","type":"security","label":"ML quality gate","sublabel":"accept / block · fail closed","tech":"LightGBM · Scikit-learn","pos":[530,465],"size":[180,90]},
    {"id":"lifecycle-risk","type":"backend","label":"Lifecycle & risk state","sublabel":"entry · targets · SL · P&L · recovery","tech":"PostgreSQL · SQLite","pos":[760,465],"size":[195,90]},
    {"id":"execution","type":"backend","label":"Guarded execution lane","sublabel":"intent · venue adapter · hard risk gates","tech":"Exchange APIs · idempotent workers","pos":[1005,465],"size":[190,90]},
    {"id":"reconciliation","type":"database","label":"Durable reconciliation","sublabel":"orders · fills · restart-safe state","tech":"PostgreSQL · SQLite","pos":[1245,465],"size":[185,90]},
    {"id":"publication","type":"security","label":"Sanitized publication boundary","sublabel":"approved read-only projection","tech":"Python · typed contracts","pos":[1005,620],"size":[190,90],"tag":"one-way"},
    {"id":"public-read-model","type":"database","label":"Public verification read model","sublabel":"immutable plan · lifecycle · outcome","tech":"FastAPI · PostgreSQL/SQLite","pos":[1245,620],"size":[195,90]},
    {"id":"api-clients","type":"frontend","label":"API · CLI · MCP","sublabel":"human + AI read-only clients","tech":"Python · FastAPI · MCP","pos":[1245,765],"size":[195,70]},
    {"id":"subscriber-delivery","type":"frontend","label":"Subscriber delivery","sublabel":"tiered realtime/delayed distribution","tech":"Python · durable scheduling","pos":[760,620],"size":[195,90]},
    {"id":"social-factory","type":"frontend","label":"Content production pipeline","sublabel":"canonical result → native social media","tech":"Python · native renderers","pos":[530,620],"size":[180,90]},
    {"id":"access","type":"security","label":"Access & membership","sublabel":"onboarding · referrals · optional checkout","tech":"FastAPI · PostgreSQL","pos":[280,620],"size":[200,90]},
    {"id":"marketing","type":"frontend","label":"Public web surface","sublabel":"product narrative · discovery","tech":"Next.js · TypeScript","pos":[40,620],"size":[190,90]}
  ],
  "boundaries": [
    {"kind":"region","label":"Quant research & evidence system","wraps":["market-data","canonical-market","timeframes","primitives","event-factory","event-store","hypothesis-view","oos-selection","alpha-history","nautilus-bridge","streaming-parity"],"pad":22},
    {"kind":"security-group","label":"Private operational runtime","wraps":["source-data","signal-runtime","ml-gate","lifecycle-risk","execution","reconciliation"],"pad":22},
    {"kind":"region","label":"Failure-isolated product & distribution","wraps":["publication","public-read-model","api-clients","subscriber-delivery","social-factory","access","marketing"],"pad":22}
  ],
  "connections": [
    {"id":"r1","from":"market-data","to":"canonical-market","variant":"emphasis"},
    {"id":"r2","from":"canonical-market","to":"timeframes"},
    {"id":"r3","from":"timeframes","to":"primitives"},
    {"id":"r4","from":"primitives","to":"event-factory","variant":"emphasis"},
    {"id":"r5","from":"event-factory","to":"event-store","variant":"emphasis"},
    {"id":"r6","from":"event-store","to":"hypothesis-view"},
    {"id":"r7","from":"hypothesis-view","to":"oos-selection"},
    {"id":"r8","from":"oos-selection","to":"alpha-history","variant":"security"},
    {"id":"r9","from":"oos-selection","to":"nautilus-bridge","label":"finalists"},
    {"id":"r10","from":"nautilus-bridge","to":"streaming-parity","variant":"security"},
    {"id":"r11","from":"streaming-parity","to":"signal-runtime","label":"shared strategy/event semantics","variant":"dashed"},

    {"id":"p1","from":"source-data","to":"signal-runtime","variant":"emphasis"},
    {"id":"p2","from":"signal-runtime","to":"ml-gate"},
    {"id":"p3","from":"ml-gate","to":"lifecycle-risk","variant":"security"},
    {"id":"p4","from":"lifecycle-risk","to":"execution"},
    {"id":"p5","from":"execution","to":"reconciliation","variant":"security"},
    {"id":"p6","from":"lifecycle-risk","to":"subscriber-delivery","label":"approved signal state"},
    {"id":"p7","from":"lifecycle-risk","to":"social-factory","label":"read-only result authority"},
    {"id":"p8","from":"lifecycle-risk","to":"publication","label":"sanitized projection","variant":"emphasis"},
    {"id":"p9","from":"publication","to":"public-read-model","variant":"security"},
    {"id":"p10","from":"public-read-model","to":"api-clients","variant":"emphasis"},
    {"id":"p11","from":"access","to":"subscriber-delivery","label":"entitlement"},
    {"id":"p12","from":"marketing","to":"access","label":"conversion"}
  ],
  "cards": [
    {"dot":"cyan","title":"Research architecture","items":["Rust handles reusable causal computation while Python remains the research/ML control plane","Arrow/Parquet form the typed cross-language evidence boundary and DuckDB/Polars query it cheaply","NautilusTrader owns execution-simulation semantics rather than notebook-specific fills"]},
    {"dot":"emerald","title":"Production architecture","items":["FastAPI/Python own signal orchestration and LightGBM is a fail-closed quality filter, not signal authority","PostgreSQL/SQLite persist lifecycle and reconciliation state","Exchange adapters sit behind idempotent intent and hard-risk boundaries"]},
    {"dot":"rose","title":"Product boundary","items":["Next.js/TypeScript, access services and content pipelines consume approved projections only","FastAPI API/CLI/MCP surfaces are read-only","Technology choice follows authority ownership rather than repository topology"]}
  ]
}
