Docs / Validate documentation (push) Canceled after 0s
Docs / Deploy GitHub Pages (push) Canceled after 0s
CI Final Summary (AI) / AI Final Summary (push) Canceled after 0s
CI Final Summary (AI) / Push/PR event feed (push) Canceled after 0s
CI / CI Integrity and Change Classification (push) Canceled after 0s
CI / Code Quality & Tests (push) Canceled after 0s
Dependency Lock & Migration Safety / Dependency drift (lock vs pyproject) (push) Canceled after 0s
Dependency Lock & Migration Safety / Migration safety (fail-loud + version postconditions) (push) Canceled after 0s
JS Tests / Frontend JS Unit Tests (push) Canceled after 0s
Security / CodeQL Analysis (push) Canceled after 0s
Security / Trivy Vulnerability Scan (push) Canceled after 0s
Tests (OS Matrix) / Py Tests (macos-latest) (push) Canceled after 0s
Tests (OS Matrix) / Py Tests (windows-latest) (push) Canceled after 0s
CI / Extended Validation (Tier 2) (push) Canceled after 0s
CI / Heavy CI (database-provider) (push) Canceled after 0s
CI / Heavy CI (e2e) (push) Canceled after 0s
CI / Heavy CI (integration) (push) Canceled after 0s
CI / Heavy CI (model-validation) (push) Canceled after 0s
CI / Heavy CI (research-backtest) (push) Canceled after 0s
CI / Aggregate CI Results (push) Canceled after 0s
Full project import for the self-hosted code hosting (https://code.aifunny.ltd/gavindiaz/my-NexusTradingForexBot.git). Includes the live-freshness + scaler-hash fixes for the permanent STALE dashboard (tick_pipeline now_utc stamps; infer_probabilities computes model_input_hash on the actual scaled 70D tensor), the data-fetch default-path fix, the g29 web-auth test fixes, and a Chinese user manual (使用手册.md) for the web dashboard. Scratch diagnostic scripts (check*.py, contain a live web-auth token) and the .kilo/ agent-worktree directory are gitignored, not committed. Co-Authored-By: Claude Code <noreply@anthropic.com>
3.1 KiB
3.1 KiB
title, description, lang
| title | description | lang |
|---|---|---|
| Research Stack | How the research engine turns historical data into validated (or rejected) strategy candidates. | en |
Research Stack
The research side answers one question with evidence: is this candidate good enough to trust — and can we prove it on data it never saw?
Pipeline
DATA (canonical tick/bar datasets, provenance-fingerprinted)
→ FEATURES (same causal contract as live: 50D base, governed 70D assembly)
→ LABELING (triple-barrier, purged + embargoed)
→ TRAINING (deterministic seeds, walk-forward)
→ BACKTEST (friction-aware: spread / slippage / latency)
→ WALK-FORWARD VALIDATION
→ OOS GATE (hard: failure ⇒ REJECTED)
→ ROBUSTNESS STRESS
→ COUNTERFACTUAL / STRATIFICATION EVIDENCE
→ CANDIDATE REGISTRY (content-addressed)
→ SHADOW COMPARISON (zero order authority)
→ OPERATOR-GATED PROMOTION
Key guarantees
- Leakage prevention (INV-008): purged + embargoed walk-forward (Lopez de Prado); broker history REPLACE+ALIGN; liquidity features strictly causal (confirmation bars, completed HTF buckets only). Purge/embargo defaults are wired into the production research path (BUG-183 regression suite).
- Replay parity: the replay feature vector is bit-exact vs the dataset (anti-leakage tests); live = replay = training semantics.
- Determinism: seeded training, frozen datasets, fingerprinted artifacts (dataset ID, schema hash, git commit in manifests and run snapshots).
- Honest provenance: run snapshots record effective purge/embargo and
provenance fields —
NOT_RECORDEDis written when truthfully unknown, never backfilled.
Components
| Component | Module | Note |
|---|---|---|
| Dataset builder + quality gates | research/dataset.py, model_generation/ |
fingerprinted, versioned |
| Backtest engine | research/backtest.py |
deterministic, friction-aware |
| Walk-forward | research/walkforward.py, training/walk_forward_trainer.py |
purged/embargoed |
| OOS gate | research/oos.py |
macro-F1 / balanced-accuracy / ECE floors |
| Streaming replay | research/streaming_replay.py |
logical clock, zero sleeps; simulated fills on historical bid/ask; no order_send (test-enforced) |
| Forward tests | research/forward_test.py |
freeze capture at cutoff (model/scaler/strategy fingerprints), strict timestamp > cutoff streaming |
| Tick datasets | research/mt5_tick_dataset.py |
canonical adapter surface, offline after acquisition |
| Counterfactual engine | research/counterfactual.py |
walks NO_TRADE decisions on canonical ticks (CHG-0041) |
| Evidence + observability | research/evidence.py, research/observability.py |
gate model, events, evidence vault, worker health |
The 70D case study
The 70D series (scalp_v3: Base 50 + News 10 + Liquidity 10) is the reference
example of the stack working as designed: full parity/validation infrastructure
built, fair A/B/C benchmark run on real data — and the candidate rejected
(OOS NOT_ELIGIBLE). The live contract stayed 50D. Details:
Status · internal reports under docs/70D_*.md.