147 lines
10 KiB
Markdown
147 lines
10 KiB
Markdown
# Current Status — NT8 SDK
|
|
**Last Updated:** 2026-08-16 (weekly Sunday republish — see `docs/02-runbooks/weekly_roadmap_cadence.md`)
|
|
|
|
## RESOLVED 2026-08-16 — Dirty working tree blocked Gate 3 freeze
|
|
Earlier freeze attempts today (`freeze_20260816_003543`, `freeze_20260816_003653`, plus
|
|
`verify_20260816_003653`) failed because `git status --porcelain` was not clean. The reviewed
|
|
governance, runtime remediation, GAP-037/038 tests, and standalone `tools/` tree were committed
|
|
in logical groups. `preflight.ps1 --freeze` then succeeded and produced
|
|
`docs/gate-runs/gate3/baseline.json` from `freeze_20260816_170304`. `DEC-GATE3-CONFIG.md`
|
|
remains `Status: draft` because GAP-034 is still open, not because the freeze capture failed.
|
|
|
|
## BLOCKER 1 — GAP-034: Silent zero-trade defect (UNDIAGNOSED)
|
|
Sessions on 2026-08-03, 08-04, and 08-13 produced **zero trades on days with clear NQ
|
|
breakouts**. Root cause is NOT identified. Gate Run #3 cannot start until it is.
|
|
|
|
**Proven:** `ProcessStrategyIntent` writes a `SIGNAL:` line to the session file log
|
|
unconditionally for every realtime intent (`NT8StrategyBase.cs` ~1236). No `SIGNAL:` line
|
|
appears in any of these sessions. Therefore no intent was produced — the failure is
|
|
**upstream of the execution pipeline**.
|
|
|
|
**Ruled out:** portfolio risk block, per-strategy risk rejection, sizing failure, order
|
|
submission, broker rejection, runner/scaler leg logic, connection-loss latch
|
|
(`_connectionLost` is correctly cleared on restore, `NT8StrategyBase.cs` ~870).
|
|
|
|
**The defect is INTERMITTENT, not a hard failure.** Broker-confirmed trades executed on
|
|
2026-08-07 and 2026-08-10 (DEC-20260810-02) between the zero-trade days. Any hypothesis
|
|
requiring a persistent latch is therefore weakened.
|
|
|
|
**Remaining candidates** — all four log via `_logger` only (NT8 Output window), never to
|
|
file, which is why session logs cannot distinguish them:
|
|
1. **Grade filter rejection** (composite score below `MinTradeGrade=5` / Grade A) —
|
|
RANKED FIRST. Score varies day to day, which fits an intermittent pattern exactly.
|
|
A "clear breakout" visually is not the same as a Grade A confluence score.
|
|
2. ORB range never established on the HFT Algo Bars primary series — plausible if bar
|
|
construction varies with volume/tick density between sessions.
|
|
3. `MaxDailyTrades` latch — `_dailyTradeCount` pre-incremented by historical replay.
|
|
WEAKENED: would likely persist across days once latched, yet 08-07 and 08-10 traded.
|
|
Still possible if enable time relative to the ORB window differs by day.
|
|
4. RTH window guard evaluating outside 09:30-10:00 — WEAKENED for the same reason; a
|
|
timezone fault would be constant, not intermittent.
|
|
|
|
**Next step (per DEC-20260814-01):** finish GAP-035 (route all rejection reasons to
|
|
`FileLog`), redeploy during the current disarmed window, then run one session with the
|
|
Output window open as a cross-check that file and Output agree. Full instructions in
|
|
`TASK_GAP035_GAP034_PROMPT.md`.
|
|
|
|
## Verified implementation state
|
|
- **Last completed task:** Gate 3 cleanup/freeze capture — reviewed and committed the weekend remediation/tooling tree; `baseline.json` exists.
|
|
- **Active task:** GAP-034 — diagnose the silent zero-trade defect using the newly committed GAP-035 rejection file logging.
|
|
- **Blocked task:** Gate Run #3 start (blocked on GAP-034, RUNNER-001 execution/result, and manual NinjaScript compile/re-arm evidence)
|
|
- **Deferred:** GAP-025 Runner No-Fill Diagnosis; GAP-022-FOLLOWUP connection-state seam
|
|
|
|
## Build and test evidence
|
|
- `verify-build.bat` is not executable under Windows `cmd.exe` because the tracked batch file uses LF-only line endings.
|
|
- Release build/test command: `dotnet test NT8-SDK.sln --configuration Release --verbosity minimal` passed.
|
|
- Tests: **511 passed, 0 failed** — 422 Core, 79 Integration, 10 Performance.
|
|
|
|
## Gate readiness
|
|
- Trade provenance now reads grade, weighted score, and ORB ticks from the accepted intent metadata and records the exact runner mode resolved for submission.
|
|
- `MaxDailyTrades` now remains enforced after position-flat events and resets only when the trading session date rolls over.
|
|
- Session startup now records per-series load configuration/counts, factor warm-up readiness, and warns if the SimSimple gate account has its kill switch disabled.
|
|
- Every real-time signal writes its `TEST MODE ACTIVE` or `LIVE MODE` status to the session file log.
|
|
- GAP-022 has five real scenario assertions. Its remaining three requirements are deferred architecture work, not fabricated tests.
|
|
- **Runner leg is unfrozen pending RUNNER-001** (DEC-20260815-01, supersedes DEC-20260810-02):
|
|
the breakeven trigger (20 ticks) sits close to the scaler target (16 ticks) and the
|
|
ATR-derived target (28 ticks observed), leaving the runner little room to extend. The
|
|
18-combination sweep (`tools/runnersweep`) must run and produce a superseding decision entry
|
|
with the selected trigger distance **before** `DEC-GATE3-CONFIG` is finalized.
|
|
- **Before Gate 3 start:** resolve GAP-034, execute the RUNNER-001 sweep, complete the pending
|
|
NinjaTrader compile/re-arm check, and enforce the no-deploy rule. The freeze capture exists
|
|
at `docs/gate-runs/gate3/baseline.json`.
|
|
|
|
## Resolved since last republish (2026-08-14 → 2026-08-16)
|
|
- **`EnableShortTrades` source/runtime mismatch — RESOLVED.** DEC-20260814-04 (accepted
|
|
2026-08-16): `SimpleORBNT8.SetDefaults()` now sets `EnableShortTrades = true` so a clean
|
|
checkout matches live workspace usage. Covered by
|
|
`tests/NT8.Core.Tests/Adapters/SimpleORBNT8DefaultsTests.cs`.
|
|
- **`StartBehavior=AdoptAccountPosition` undocumented change — RESOLVED.** Same DEC-20260814-04
|
|
entry documents and retains this setting; it avoids NT8 start-up synchronization
|
|
submitting/flattening during historical replay bursts before the first live bar.
|
|
|
|
## Open findings carried forward
|
|
- **Config drift persists.** 2026-08-11 settings export = `Sim101` / 1 Minute; 2026-08-13
|
|
session = `SimSimple ORB` / HFTAlgoBarsType. Two accounts, two bar types, concurrent.
|
|
Single-frozen-account doctrine is still being violated. `tools/configdiff` (TOOL-002) is now
|
|
built specifically to catch this going forward — run it against the last 3 exports as part
|
|
of every freeze/verify cycle.
|
|
- **No settings export exists for 2026-08-13.** The session that matters has no captured
|
|
config. Unusable as gate evidence regardless of trade outcome.
|
|
- **`EnableVerboseLogging=False`** on the 08-13 running instance, contradicting the
|
|
frozen-parameter requirement. Suppresses the `Print` diagnostics needed for GAP-034.
|
|
- **`EnableKillSwitch=False`** on the gate account. GAP-033 warning fired correctly; the
|
|
setting itself is still wrong.
|
|
- **`risk_mode` provenance — FIXED.** GAP-036 now sources `intent.Metadata["risk_mode"]` with
|
|
the previous config-parameter lookup retained as fallback.
|
|
- **`MaxDailyTrades` regression coverage — ADDED.** GAP-037 four-case suite is committed in
|
|
`tests/NT8.Core.Tests/MaxDailyTradesTests.cs`.
|
|
- **`ConfigHash` includes `BarsPeriod` — FIXED.** GAP-038 is wired through
|
|
`ConfigHashCalculator` and covered by `tests/NT8.Integration.Tests/ConfigHashTests.cs`.
|
|
- **`_dailyTradeCount` realtime-only guard — FIXED.** GAP-039 prevents historical replay from
|
|
latching the daily trade count while preserving backtest enforcement.
|
|
- **Daily bars loaded dropped 129 (08-03/04) to 87 (08-13)** with identical
|
|
`DaysToLoad=365`. Warm-up still SATISFIED, not blocking, but unexplained.
|
|
- **`DaysToLoad=3` on the primary series** in every observed session. Factor warm-up is
|
|
unaffected (it reads the daily series), but this is far below the intended 180. Startup
|
|
WARNING for this case is GAP-040 (added 2026-08-14), not yet scheduled into a work window.
|
|
|
|
## Backtest/live asymmetry (documented, not a defect)
|
|
A backtest showing no trades is **not** evidence that live would not have traded.
|
|
In Strategy Analyzer the secondary daily series loads only from the backtest start date:
|
|
- `BuildDailyBarContext` returns `Count=0` when fewer than 2 daily bars exist
|
|
(`SimpleORBNT8.cs` ~313), so daily-dependent factors score neutral and the composite
|
|
falls below the Grade A threshold.
|
|
- The regime gate requires `CurrentBars[1] >= SmaPeriodLong` (50 daily bars,
|
|
`NT8StrategyBase.cs` ~1122) and never arms on short backtests.
|
|
- Neither path errors. The NR7 warm-up advisory deliberately does not block (~546-554).
|
|
|
|
**Required:** set the Strategy Analyzer start date **at least 60 trading days** before the
|
|
target day, then read only the target day's results. This is now a mandatory validity rule
|
|
enforced by `tools/runnersweep` for the RUNNER-001 sweep (DEC-20260814-03, DEC-20260815-01).
|
|
|
|
**Caveat:** on non-time-based bars (HFT Algo Bars), NT8 builds bars in backtest from
|
|
historical minute data unless Tick Replay is enabled, while live builds from real ticks.
|
|
Bar boundaries differ, so breakout bars differ. Tick Replay must be on for comparability.
|
|
|
|
## Tooling status (all standalone, zero NT8 assembly references)
|
|
- **`tools/dashboard`** (DASH-001) — built, approved 2026-08-10. Read-only, three launch
|
|
modes (direct file, static localhost, live server with Apprise notifications).
|
|
- **`tools/logtriage`** (TOOL-001) — built. Produces the JSON the dashboard and weekly
|
|
status review both consume.
|
|
- **`tools/configdiff`** (TOOL-002) — built. Config-drift matrix across settings exports;
|
|
independently catches the DEC-20260810-01 hash-vs-BarsPeriod defect class.
|
|
- **`tools/preflight`** (TOOL-003) — built. Morning go/no-go checks plus Gate 3
|
|
freeze/verify capture — this is the tool both failed freeze attempts today came from.
|
|
- **`tools/runnersweep`** (RUNNER-001) — built, not yet executed against real exports. Required
|
|
before `DEC-GATE3-CONFIG` per DEC-20260815-01.
|
|
- All five directories above are committed as standalone tooling.
|
|
|
|
## Authoritative documents
|
|
- Master document: **v6.4, republished 2026-08-16** — supersedes the v6.1 reference below.
|
|
Delivered by the operator's Claude session; placing the file under `docs/` and updating this
|
|
pointer is tracked alongside the Blocker 1 cleanup commit.
|
|
- Prior reference (superseded): `docs/NT8_SDK_Master_Document_v6.1_Complete.docx`
|
|
- Operator runbook: `docs/02-runbooks/NT8_SDK_Operator_Runbook_v1.0.docx`
|
|
- Weekly cadence rule: `docs/02-runbooks/weekly_roadmap_cadence.md` (DEC-20260816-01)
|
|
- Decision correction: `DEC-20260713-02`
|