"""
Architectural pillars (from public accounts of Renaissance / Medallion-style shops).

This module is the single source of truth for *what* we are trying to approximate in code.
Implementation lives in sibling modules as they are added.

1. Statistical arbitrage & market neutrality
   Pairs / baskets / cointegration; long–short construction; target beta ≈ 0 vs benchmarks.

2. Microscopic edge at scale
   Many weakly predictive events; law of large numbers; avoid over-sizing single calls.

3. Sequence / state-space models
   HMMs and related models treat observations as emissions from latent states — applicable
   to noisy price/feature sequences (historical IBM speech-recognition lineage).

4. Alternative data + unified model
   Rich feature store; one research funnel into one deployable model or ensemble with
   shared representation where possible.

5. Leverage (risk layer)
   Separates *signal quality* from *capital efficiency*; only responsible after neutrality
   and drawdown controls are validated.

6. Automated execution
   Deterministic rules, no discretionary kill-switch unless risk limits breach.

Integration notes (this repo):
  - Daily sequence tensors: 6_build_daily_sequence_dataset.py, 6_train_xgb_daily.py
  - Long-only score backtest: 6_backtest_xgb_daily.py
  - Dollar-neutral L/S (top/bottom by signal): RenTech/run_cs_neutral_backtest.py
  - Multi-timeframe MR + momentum: RenTech/strategy_stack/ (main.py)
"""

from __future__ import annotations

from dataclasses import dataclass
from typing import Sequence


@dataclass(frozen=True)
class Pillar:
    id: int
    name: str
    summary: str


PILLARS: tuple[Pillar, ...] = (
    Pillar(1, "Stat arb & neutrality", "Spreads / pairs; hedged long–short; low market beta"),
    Pillar(2, "Edge × scale", "~50–51% per trade OK if diversified and repeated often"),
    Pillar(3, "HMM / state space", "Latent-state models on sequential market data"),
    Pillar(4, "Data + unified model", "Many features → one modeling pipeline"),
    Pillar(5, "Leverage", "Amplify only after neutral, stable residual returns"),
    Pillar(6, "Automation", "Full systematic execution and risk limits"),
)


def print_outline(pillars: Sequence[Pillar] = PILLARS) -> None:
    for p in pillars:
        print(f"{p.id}. {p.name}: {p.summary}")


if __name__ == "__main__":
    print_outline()
