[GOV]: cleanup prompted task state
- SPRINT_BOARD.md: stage GAP-025/GAP-030 and correct GAP-062 deploy status - TASK_GAP025_RUNNER_ORDER_LIFECYCLE_LOGGING_PROMPT.md: add runner lifecycle logging prompt - TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md: add ORB hydration verify prompt - TASK_GAP051/052/059/060 prompts: record commit-only deploy instruction - TASK_GAP054_RUNNER_TRAIL_PROMPT.md: clarify SIM/replay validation path - docs/00-governance/2026-08-19-run-book.md: reconcile implemented/verified task states - docs/00-governance/active_work.md: update blocker status and validation requirements - docs/00-governance/decisions.md: record prompted follow-ups and resolved GAP-062 deploy status Build: clean | Tests: 569 passing | Deploy: GAP-062 deployed backup 20260826_005308
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
# NT8 SDK — Sprint Board
|
# NT8 SDK — Sprint Board
|
||||||
**Last Updated:** 2026-08-26 (GAP-062 implemented — trend_confirm direction fix; deploy skipped by prompt)
|
**Last Updated:** 2026-08-26 (GAP-025/GAP-030 prompted; GAP-062 deployed by operator request — see DEC-20260826-02)
|
||||||
**Truth source:** compiler output, test output, deployed-file comparisons, and runtime artifacts override board claims.
|
**Truth source:** compiler output, test output, deployed-file comparisons, and runtime artifacts override board claims.
|
||||||
|
|
||||||
## Current gate state
|
## Current gate state
|
||||||
@@ -102,10 +102,10 @@
|
|||||||
- Scoped observability-only: exposes `Avwap`/`AvwapSlope`/`TrendConfirm` raw values in `STATE_CONTEXT` (same class as GAP-059) so the remaining open question (whether early ORB-timing structurally blocks the price-vs-AVWAP bonus too) can be checked against real numbers. Does not fix `trend_confirm`'s asymmetry — that's a separate, not-yet-decided follow-up.
|
- Scoped observability-only: exposes `Avwap`/`AvwapSlope`/`TrendConfirm` raw values in `STATE_CONTEXT` (same class as GAP-059) so the remaining open question (whether early ORB-timing structurally blocks the price-vs-AVWAP bonus too) can be checked against real numbers. Does not fix `trend_confirm`'s asymmetry — that's a separate, not-yet-decided follow-up.
|
||||||
- Prompt: `TASK_GAP061_AVWAP_TELEMETRY_PROMPT.md`. Implemented as observability-only: `STATE_CONTEXT` now includes `Avwap` (`F2`), `AvwapSlope` (`F4`), and `TrendConfirm` (`F1`) when those existing `context.CustomData` keys are present. Missing keys are omitted with no placeholders. No scoring, `trend_confirm`, `STATE:`, `STATE_DETAIL:`, risk, sizing, or order-flow logic changed. Verification: focused tests 7/7, `verify-build.bat` 561/561, Core Release no-build 472/472. Deploy intentionally skipped by task prompt.
|
- Prompt: `TASK_GAP061_AVWAP_TELEMETRY_PROMPT.md`. Implemented as observability-only: `STATE_CONTEXT` now includes `Avwap` (`F2`), `AvwapSlope` (`F4`), and `TrendConfirm` (`F1`) when those existing `context.CustomData` keys are present. Missing keys are omitted with no placeholders. No scoring, `trend_confirm`, `STATE:`, `STATE_DETAIL:`, risk, sizing, or order-flow logic changed. Verification: focused tests 7/7, `verify-build.bat` 561/561, Core Release no-build 472/472. Deploy intentionally skipped by task prompt.
|
||||||
|
|
||||||
**[GAP-062] `trend_confirm` is direction-blind, capping every short's Trend factor** | Stage 1 | ✅ IMPLEMENTED — deploy skipped by prompt
|
**[GAP-062] `trend_confirm` is direction-blind, capping every short's Trend factor** | Stage 1 | ✅ IMPLEMENTED — deployed 2026-08-26 by operator request
|
||||||
- Found while drafting GAP-061 (`DEC-20260825-04` addendum), independently re-confirmed by Kilocode's own GAP-061 commit writeback: `trend_confirm` (`SimpleORBStrategy.cs:970`) is `avwapSlope > 0.0 ? 1.0 : 0.0` — unconditionally rewards a positive slope regardless of trade direction. For a short, this is mutually exclusive with the correctly-aligned (negative-slope) `+0.3` bonus, capping every short's Trend score at 0.30 (or 0.70 with price below AVWAP) even with a cleanly confirmed downtrend. Matches real data exactly: every best real short setup this week and on 2026-08-18 scored `Trend=0.30`. With `MinTradeGrade=A`, this has silently vetoed every well-formed short setup.
|
- Found while drafting GAP-061 (`DEC-20260825-04` addendum), independently re-confirmed by Kilocode's own GAP-061 commit writeback: `trend_confirm` (`SimpleORBStrategy.cs:970`) is `avwapSlope > 0.0 ? 1.0 : 0.0` — unconditionally rewards a positive slope regardless of trade direction. For a short, this is mutually exclusive with the correctly-aligned (negative-slope) `+0.3` bonus, capping every short's Trend score at 0.30 (or 0.70 with price below AVWAP) even with a cleanly confirmed downtrend. Matches real data exactly: every best real short setup this week and on 2026-08-18 scored `Trend=0.30`. With `MinTradeGrade=A`, this has silently vetoed every well-formed short setup.
|
||||||
- **Unlike GAP-050/GAP-061, this is a real scoring-behaviour change, not behaviour-neutral** — fixing it can newly qualify short setups that were previously capped below Grade A. Task requires symmetric before/after test proof (long-side unchanged, short-side now earns the same max score a symmetric long would) and explicit SIM before/after observation, not "none required."
|
- **Unlike GAP-050/GAP-061, this is a real scoring-behaviour change, not behaviour-neutral** — fixing it can newly qualify short setups that were previously capped below Grade A. Task requires symmetric before/after test proof (long-side unchanged, short-side now earns the same max score a symmetric long would) and explicit SIM before/after observation, not "none required."
|
||||||
- Prompt: `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`. Implemented by publishing side-specific `trend_confirm_long`/`trend_confirm_short` inputs from `SimpleORBStrategy.UpdateConfluenceInputs()` and having `TrendAlignmentFactorCalculator` select the value matching `intent.Side`, leaving the `+0.4`/`+0.3`/`+0.3` additive score structure unchanged. Tests prove a short in a confirmed downtrend now reaches the same max Trend score as a symmetric long, a short against an uptrend does not earn trend confirmation, and long confirmed-uptrend behavior remains fully confirmed. Verification: focused Intelligence tests 89/89, `verify-build.bat` 569/569. Deploy intentionally skipped by task prompt; SIM before/after observation required because this is a scoring-behavior change.
|
- Prompt: `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`. Implemented by publishing side-specific `trend_confirm_long`/`trend_confirm_short` inputs from `SimpleORBStrategy.UpdateConfluenceInputs()` and having `TrendAlignmentFactorCalculator` select the value matching `intent.Side`, leaving the `+0.4`/`+0.3`/`+0.3` additive score structure unchanged. Tests prove a short in a confirmed downtrend now reaches the same max Trend score as a symmetric long, a short against an uptrend does not earn trend confirmation, and long confirmed-uptrend behavior remains fully confirmed. Verification: focused Intelligence tests 89/89, `verify-build.bat` 569/569. Deployed after explicit operator request; backup `20260826_005308`. SIM before/after observation required because this is a scoring-behavior change.
|
||||||
|
|
||||||
### Standing item
|
### Standing item
|
||||||
The dirty working tree — several modified/untracked files including live strategy files — is still unresolved; recommend operator check `git status` directly on the machine.
|
The dirty working tree — several modified/untracked files including live strategy files — is still unresolved; recommend operator check `git status` directly on the machine.
|
||||||
@@ -147,18 +147,18 @@ The dirty working tree — several modified/untracked files including live strat
|
|||||||
|
|
||||||
## 📋 QUEUE — no deploy to the gate machine during a run
|
## 📋 QUEUE — no deploy to the gate machine during a run
|
||||||
|
|
||||||
**[GAP-025] Runner No-Fill Anomaly Diagnosis** | Sprint 2.7 | ⏳ QUEUED — branch-only during Gate Run #2
|
**[GAP-025] Runner/scaler order lifecycle invisible in the persistent session log** | Sprint 2.7 | 🟡 PROMPTED
|
||||||
- Add diagnostic-only runner order/execution state logging.
|
- Reading `OnOrderUpdate`/`OnExecutionUpdate` (`NT8StrategyBase.cs` ~1270-1345) on 2026-08-26 found the actual gap behind the old "runner no-fill anomaly" framing: `OnOrderUpdate` never writes to `FileLog` for any order state except `Rejected` (everything else — submitted, accepted, working, cancelled — is Print-only, invisible outside NT8's live Output window), and the `FILL` line in `OnExecutionUpdate` doesn't include the order/signal name, so scaler vs. runner fills can't be told apart from the file log at all.
|
||||||
- Diagnose the SIM fill sequence; this blocks live promotion, not Gate Run #2.
|
- Scoped diagnostic-only: adds an `ORDER {signal} State=... Filled=.../... AvgFillPrice=...` FileLog line to `OnOrderUpdate` for every transition, and adds the signal name to the existing `FILL` line. Zero change to order submission, sizing, or execution-adapter logic.
|
||||||
|
- Prompt: `TASK_GAP025_RUNNER_ORDER_LIFECYCLE_LOGGING_PROMPT.md`.
|
||||||
|
|
||||||
**[GAP-022-FOLLOWUP] Connection-State Test Seam** | Sprint 2.7 | ⏳ QUEUED — branch-only during Gate Run #2
|
**[GAP-022-FOLLOWUP] Connection-State Test Seam** | Sprint 2.7 | ⏳ QUEUED — branch-only during Gate Run #2
|
||||||
- Add an injectable connection-state seam around `NT8StrategyBase`.
|
- Add an injectable connection-state seam around `NT8StrategyBase`.
|
||||||
- Then implement the three deferred scenarios: news-day reduced sizing, mid-trade disconnect, and pre-entry disconnect.
|
- Then implement the three deferred scenarios: news-day reduced sizing, mid-trade disconnect, and pre-entry disconnect.
|
||||||
|
|
||||||
**[GAP-030] Historical ORB State Hydration** | Sprint 2.7 | ⏳ QUEUED — branch-only during Gate Run #2
|
**[GAP-030] Historical ORB range hydration on a late strategy enable** | Sprint 2.7 | 🟡 PROMPTED — verify-first
|
||||||
- On a late strategy enable, reconstruct only the current day's 09:30–10:00 ET opening-range high/low from loaded bars.
|
- Traced on 2026-08-26: `SimpleORBStrategy.OnBar()`'s ORB-building logic is state-blind (no `State.Historical`/`Realtime` awareness at all in `StrategyContext`) and accumulates the range from whatever bars it's given; `NT8StrategyBase.OnBarUpdate()` doesn't currently block `State.Historical` bars from reaching it; and `ProcessStrategyIntent()` already has an explicit `State == State.Historical` guard blocking any real order from a historical-replay bar. **This suggests both halves GAP-030 originally asked for may already exist by construction** — but the task explicitly requires Kilocode to verify (not assume) that NT8 actually delivers same-day historical catch-up bars on a late enable before treating it as settled, and to only implement new logic if that verification finds a real gap; otherwise the task closes the missing test-coverage gap instead.
|
||||||
- Preserve the realtime replay guard: hydrated historical bars must never create an intent/order; only genuine post-hydration realtime bars may be evaluated.
|
- Prompt: `TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md`.
|
||||||
- Add tests for correct range reconstruction and for zero historical-order submissions.
|
|
||||||
|
|
||||||
**[GAP-007] Walk-Forward Validation** | Sprint 2.7 | ⏳ QUEUED — only after a passing Gate Run #2 ruling
|
**[GAP-007] Walk-Forward Validation** | Sprint 2.7 | ⏳ QUEUED — only after a passing Gate Run #2 ruling
|
||||||
|
|
||||||
|
|||||||
143
TASK_GAP025_RUNNER_ORDER_LIFECYCLE_LOGGING_PROMPT.md
Normal file
143
TASK_GAP025_RUNNER_ORDER_LIFECYCLE_LOGGING_PROMPT.md
Normal file
@@ -0,0 +1,143 @@
|
|||||||
|
# TASK: GAP-025 — runner/scaler order lifecycle invisible in the persistent session log
|
||||||
|
# Staged: 2026-08-26 (long-queued Sprint 2.7 item, now prompted; DEC-20260825-07)
|
||||||
|
# Sprint: Stage 1 — diagnostic logging only, zero trading-behaviour risk
|
||||||
|
# Owner: Kilocode
|
||||||
|
# Deploy: COMMIT ONLY — do NOT run deploy-to-nt8.bat or copy build output to
|
||||||
|
# the live NT8 install as part of this task. Verify-build and commit
|
||||||
|
# as usual; leave the deploy step for the operator to run manually
|
||||||
|
# once ready.
|
||||||
|
# ─────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
## THE DEFECT (why this is worth doing)
|
||||||
|
|
||||||
|
GAP-025 has sat in the backlog since Sprint 2.7 as "Runner No-Fill Anomaly
|
||||||
|
Diagnosis" with no concrete spec. Reading the actual order/execution
|
||||||
|
handling in `NT8StrategyBase.cs` on 2026-08-26 found a real, specific gap
|
||||||
|
that explains why a runner no-fill would be nearly undiagnosable from the
|
||||||
|
session log alone:
|
||||||
|
|
||||||
|
1. **`OnOrderUpdate`** (`src/NT8.Adapters/Strategies/NT8StrategyBase.cs`
|
||||||
|
~1270-1301) never calls `FileLog` for any order state transition. It
|
||||||
|
only `Print`s (visible live in NT8's Output window only, not in the
|
||||||
|
persistent session file) and only takes any other action
|
||||||
|
(`_circuitBreaker.RecordOrderRejection`) for the `Rejected` state
|
||||||
|
specifically. Every other transition an order goes through — submitted,
|
||||||
|
accepted, working, part-filled, cancelled — is invisible in the file
|
||||||
|
log entirely. If a runner order is submitted but never acknowledged, or
|
||||||
|
acknowledged but later cancelled by the broker, or stuck in a pending
|
||||||
|
state, none of that appears anywhere in `session_*.log`.
|
||||||
|
|
||||||
|
2. **`OnExecutionUpdate`**'s `FILL` line (`NT8StrategyBase.cs` ~1306-1345)
|
||||||
|
logs market position, quantity, price, and order ID — but not the
|
||||||
|
order/signal name. Since a single trade submits two independently
|
||||||
|
named orders (`SDK_{Symbol}_S_{hex}` for the scaler leg,
|
||||||
|
`SDK_{Symbol}_R_{hex}` for the runner leg — see `SubmitOrderToNT8`,
|
||||||
|
`NT8StrategyBase.cs` ~2240-2242), a `FILL` line in the log currently
|
||||||
|
cannot tell you *which leg* filled. You cannot distinguish "the runner
|
||||||
|
never got submitted," "the runner was submitted and rejected," "the
|
||||||
|
runner is still working, unfilled," and "the runner filled but the
|
||||||
|
scaler didn't" purely from the file log — diagnosing any of GAP-025's
|
||||||
|
original "no-fill anomaly" concern currently requires NT8's live
|
||||||
|
Output window open at the exact moment, which defeats the purpose of
|
||||||
|
file-based session logging (the same motivation GAP-035 was originally
|
||||||
|
built for).
|
||||||
|
|
||||||
|
This task closes that gap: make the full order lifecycle for both legs
|
||||||
|
independently visible in the persistent session log after the fact, with
|
||||||
|
zero change to order-management or execution logic itself.
|
||||||
|
|
||||||
|
## READ-FIRST
|
||||||
|
|
||||||
|
1. `src/NT8.Adapters/Strategies/NT8StrategyBase.cs` ~1270-1345 —
|
||||||
|
`OnOrderUpdate`/`OnExecutionUpdate`, the two methods this task changes.
|
||||||
|
2. `src/NT8.Adapters/Strategies/NT8StrategyBase.cs` ~2171-2350 —
|
||||||
|
`SubmitOrderToNT8`, to confirm the `_scalerSignalName`/
|
||||||
|
`_runnerSignalName` naming convention and the existing `SIGNAL`/
|
||||||
|
`SUBMIT` FileLog lines this task's new lines will sit alongside.
|
||||||
|
3. `src/NT8.Adapters/Strategies/NT8StrategyBase.cs` — the existing
|
||||||
|
`FileLog` method (find its definition) to confirm signature and any
|
||||||
|
existing rate-limiting/formatting conventions to stay consistent with.
|
||||||
|
4. `tests/NT8.Core.Tests/Adapters/SimpleORBNT8DefaultsTests.cs` — the
|
||||||
|
established source-text-assertion pattern this codebase already uses
|
||||||
|
for `NT8StrategyBase`/`SimpleORBNT8` methods that can't be
|
||||||
|
instantiated or invoked outside a live NT8 host (NinjaScript-derived
|
||||||
|
classes). This task's tests will likely follow the same pattern.
|
||||||
|
|
||||||
|
## THE CHANGE
|
||||||
|
|
||||||
|
1. **`OnOrderUpdate`**: for orders whose `order.Name` starts with `SDK_`
|
||||||
|
(the existing filter already applied earlier in the method), add a
|
||||||
|
`FileLog` call on every invocation — not just on `Rejected` — recording
|
||||||
|
at minimum: the order name (signal, so scaler vs runner is
|
||||||
|
identifiable), `orderState`, `filled`/`quantity`, and
|
||||||
|
`averageFillPrice`. Suggested format (adjust to match this file's
|
||||||
|
existing `FileLog` conventions):
|
||||||
|
`ORDER {order.Name} State={orderState} Filled={filled}/{quantity} AvgFillPrice={averageFillPrice:F2}`.
|
||||||
|
Gate it the same way other per-bar `FileLog` calls in this file are
|
||||||
|
gated (state/logging-enabled checks — check how nearby methods do it,
|
||||||
|
e.g. `OnExecutionUpdate`'s existing `State != State.Realtime` guard,
|
||||||
|
and mirror that convention here too — catch-up replay order-state
|
||||||
|
noise should not flood the live session log any more than fills
|
||||||
|
already avoid it).
|
||||||
|
Keep the existing `Print` call, the existing `Rejected`-specific
|
||||||
|
`_circuitBreaker.RecordOrderRejection` call, and the existing
|
||||||
|
`_executionAdapter.ProcessOrderUpdate` call completely unchanged — this
|
||||||
|
is purely an additional `FileLog` line, not a replacement.
|
||||||
|
|
||||||
|
2. **`OnExecutionUpdate`**: add the order/signal name
|
||||||
|
(`execution.Order.Name`) to the existing `FILL` line so scaler and
|
||||||
|
runner fills are distinguishable after the fact. Do not change the
|
||||||
|
line's other fields, the `OrderFill`/`PortfolioRiskManager.ReportFill`
|
||||||
|
call, or the `_executionAdapter.ProcessExecution` call.
|
||||||
|
|
||||||
|
## DO NOT
|
||||||
|
|
||||||
|
- Do not change `SubmitOrderToNT8`, `EnterLong`/`EnterShort`,
|
||||||
|
`SetStopLoss`/`SetTrailStop`/`SetProfitTarget`, or any order-submission
|
||||||
|
logic — this task only adds logging around order/execution events that
|
||||||
|
already occur.
|
||||||
|
- Do not change `_circuitBreaker` logic, `_executionAdapter.ProcessOrderUpdate`/
|
||||||
|
`ProcessExecution` call arguments, or `PortfolioRiskManager.ReportFill`.
|
||||||
|
- Do not change the existing `SIGNAL`/`SUBMIT`/`STATE`/`STATE_DETAIL`/
|
||||||
|
`STATE_CONTEXT`/`PNL_UPDATE`/`REJECT`/`REJECT SUMMARY` line formats —
|
||||||
|
only add the new `ORDER` line and extend the existing `FILL` line with
|
||||||
|
one additional field.
|
||||||
|
- Do not touch risk, sizing, or grade-filter code.
|
||||||
|
|
||||||
|
## TESTS (required)
|
||||||
|
|
||||||
|
1. A test proving `OnOrderUpdate` now emits a `FileLog` call (source-text
|
||||||
|
assertion, consistent with this codebase's established pattern for
|
||||||
|
NinjaScript-derived methods — grep the compiled method body for the
|
||||||
|
new `FileLog`/`ORDER` call, same tier as `SimpleORBNT8DefaultsTests.cs`'s
|
||||||
|
existing tests) for state transitions beyond `Rejected`, not just the
|
||||||
|
rejection case.
|
||||||
|
2. A test proving the `FILL` line format in `OnExecutionUpdate` now
|
||||||
|
includes the order/signal name.
|
||||||
|
3. A test proving the existing `Rejected`-specific `_circuitBreaker`
|
||||||
|
behavior and the existing `ProcessOrderUpdate`/`ProcessExecution` calls
|
||||||
|
are unchanged (still present, same call sites, same arguments) — this
|
||||||
|
task must be additive only.
|
||||||
|
4. Confirm the full existing suite still passes.
|
||||||
|
|
||||||
|
## VALIDATION (operator)
|
||||||
|
|
||||||
|
No live order-management behavior changes — this is additive logging
|
||||||
|
only. Genuine validation is observational: the next SIM trade with an
|
||||||
|
active runner leg should show separately identifiable `ORDER SDK_..._S_...`
|
||||||
|
and `ORDER SDK_..._R_...` lines through their full lifecycle in
|
||||||
|
`session_*.log`, and `FILL` lines that name which leg filled. If the
|
||||||
|
runner leg has ever silently failed to fill, this is what will finally
|
||||||
|
show why — submitted-but-never-accepted, accepted-but-cancelled, or
|
||||||
|
genuinely never filled while working.
|
||||||
|
|
||||||
|
## GOVERNANCE
|
||||||
|
|
||||||
|
Track as [GAP-025] in SPRINT_BOARD.md — move out of the "QUEUED —
|
||||||
|
branch-only during Gate Run #2" framing (that gate-sequencing language is
|
||||||
|
stale; this is diagnostic-only and safe to prompt now) into an
|
||||||
|
IMPLEMENTED/PROMPTED entry consistent with tonight's other tasks. Update
|
||||||
|
`docs/00-governance/decisions.md` with a new dated entry referencing this
|
||||||
|
task and `DEC-20260825-07`.
|
||||||
|
Reference: this task, `DEC-20260825-07`, `TASK_GAP054_RUNNER_TRAIL_PROMPT.md`
|
||||||
|
(the related runner-trail fix this diagnostic work follows up on).
|
||||||
164
TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md
Normal file
164
TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md
Normal file
@@ -0,0 +1,164 @@
|
|||||||
|
# TASK: GAP-030 — historical ORB range hydration on a late strategy enable
|
||||||
|
# Staged: 2026-08-26 (long-queued Sprint 2.7 item, now prompted; DEC-20260825-08)
|
||||||
|
# Sprint: Stage 1 — verify existing behaviour first; implement only if a real gap is found
|
||||||
|
# Owner: Kilocode
|
||||||
|
# Deploy: COMMIT ONLY — do NOT run deploy-to-nt8.bat or copy build output to
|
||||||
|
# the live NT8 install as part of this task. Verify-build and commit
|
||||||
|
# as usual; leave the deploy step for the operator to run manually
|
||||||
|
# once ready.
|
||||||
|
# ─────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
|
## THE QUESTION (not yet a confirmed defect — verify before implementing)
|
||||||
|
|
||||||
|
GAP-030 has sat in the backlog since Sprint 2.7 as "Historical ORB State
|
||||||
|
Hydration" with the concern: if the strategy is enabled after 09:30 ET
|
||||||
|
(the ORB window's start) but before or after the window closes at 10:00,
|
||||||
|
does it correctly reconstruct that day's opening-range high/low from
|
||||||
|
historical replay bars, and does it correctly avoid ever generating a
|
||||||
|
real order from one of those historical bars?
|
||||||
|
|
||||||
|
**Tracing this on 2026-08-26 by reading the actual source (not assuming
|
||||||
|
the bug exists) found reason to believe this already works correctly by
|
||||||
|
construction:**
|
||||||
|
|
||||||
|
1. `SimpleORBStrategy.OnBar()`'s ORB-building logic
|
||||||
|
(`UpdateOpeningRange()`, `src/NT8.Strategies/Examples/
|
||||||
|
SimpleORBStrategy.cs` ~1031-1037) is entirely state-blind:
|
||||||
|
`StrategyContext` (`src/NT8.Core/Common/Models/StrategyContext.cs`) has
|
||||||
|
no field at all for NT8's `State` (Historical/Realtime). The Core
|
||||||
|
strategy has no way to know whether a bar is a historical catch-up bar
|
||||||
|
or a genuine live one — it simply accumulates
|
||||||
|
`_openingRangeHigh`/`_openingRangeLow` from whatever `BarData` the
|
||||||
|
adapter hands it, unconditionally, every time it's called during the
|
||||||
|
09:30-10:00 window.
|
||||||
|
2. The adapter (`NT8StrategyBase.OnBarUpdate()`, ~622-700) does not
|
||||||
|
currently gate `State.Historical` bars out before they reach
|
||||||
|
`_sdkStrategy.OnBar()`. The only state-based early-return near the top
|
||||||
|
of that method is the "REPLAY BURST GUARD" (~638-647), and its own
|
||||||
|
comment explicitly says it only applies `if (State == State.Realtime)`
|
||||||
|
using a wall-clock-age heuristic — genuine `State.Historical` bars
|
||||||
|
(e.g. same-day catch-up bars NT8 may deliver on a late enable) skip
|
||||||
|
that guard entirely and, subject only to `CurrentBar >=
|
||||||
|
BarsRequiredToTrade`, fall through to `_sdkStrategy.OnBar()`.
|
||||||
|
3. Order submission is independently protected regardless of what the
|
||||||
|
Core strategy decides: `ProcessStrategyIntent()` (~2059-2066) has an
|
||||||
|
explicit `if (State == State.Historical && Account != null) { ...
|
||||||
|
return; }` guard, logged as `HistoricalReplayCatchup`, that blocks any
|
||||||
|
order from being submitted off a historical-replay bar.
|
||||||
|
|
||||||
|
**Net, if this trace is correct: the range hydration and the "no order
|
||||||
|
from historical bars" safety GAP-030 originally asked for may already both
|
||||||
|
exist, just never tested end-to-end.** But this task's trace rests on one
|
||||||
|
assumption that cannot be verified from this repo's source alone — that
|
||||||
|
NT8 actually delivers same-day 09:30-onward bars to `OnBarUpdate()` marked
|
||||||
|
`State.Historical` when the strategy is enabled partway through or after
|
||||||
|
the ORB window, rather than starting the strategy cold with no same-day
|
||||||
|
history at all. **Verify this yourself before treating it as settled** —
|
||||||
|
check NT8 platform documentation/behavior, any prior operator experience
|
||||||
|
with late enables recorded elsewhere in this repo, or a test harness if
|
||||||
|
one exists that can simulate it. If you cannot verify it with confidence,
|
||||||
|
say so plainly in your writeback rather than guessing either way.
|
||||||
|
|
||||||
|
## READ-FIRST
|
||||||
|
|
||||||
|
1. `src/NT8.Strategies/Examples/SimpleORBStrategy.cs` ~347-460 — the
|
||||||
|
09:30-10:00 window-building logic (`UpdateOpeningRange` call site,
|
||||||
|
`OrbRangeNotEstablished` rejection, `_openingRangeReady` gating).
|
||||||
|
2. `src/NT8.Strategies/Examples/SimpleORBStrategy.cs` ~1031-1037 —
|
||||||
|
`UpdateOpeningRange()` itself.
|
||||||
|
3. `src/NT8.Adapters/Strategies/NT8StrategyBase.cs` ~622-700 —
|
||||||
|
`OnBarUpdate()`'s early guards, especially the REPLAY BURST GUARD
|
||||||
|
(~638-647) and its comment explaining why it's `State == State.Realtime`
|
||||||
|
scoped, not `State.Historical`.
|
||||||
|
4. `src/NT8.Adapters/Strategies/NT8StrategyBase.cs` ~2059-2075 —
|
||||||
|
`ProcessStrategyIntent()`'s `State == State.Historical` early-return
|
||||||
|
guard (`HistoricalReplayCatchup`).
|
||||||
|
5. `src/NT8.Core/Common/Models/StrategyContext.cs` — confirm there is
|
||||||
|
genuinely no `State`/`IsHistorical`-equivalent field, i.e. Core really
|
||||||
|
cannot distinguish bar provenance on its own.
|
||||||
|
6. `docs/00-governance/decisions.md` — search for `GAP-039` (a related,
|
||||||
|
already-resolved defect about `_dailyTradeCount` only incrementing in
|
||||||
|
`State.Realtime`, meaning historical replay couldn't latch the daily
|
||||||
|
count) for how this codebase has previously reasoned about historical
|
||||||
|
vs. realtime bar handling in this exact strategy.
|
||||||
|
|
||||||
|
## THE CHANGE
|
||||||
|
|
||||||
|
**Step 1 — verify.** Confirm or correct the trace in THE QUESTION above
|
||||||
|
by reading the source yourself. State plainly in your writeback whether
|
||||||
|
you found it accurate.
|
||||||
|
|
||||||
|
**Step 2a — if verification confirms hydration and the order-block
|
||||||
|
already work correctly by construction:** this task's job is to close the
|
||||||
|
test-coverage gap, not write new production logic. Add:
|
||||||
|
- A test proving that feeding `SimpleORBStrategy.OnBar()` a realistic
|
||||||
|
sequence of `BarData` covering the 09:30-10:00 window (including a
|
||||||
|
scenario representing a late enable — i.e. the strategy only starts
|
||||||
|
receiving bars partway into the window, if that is what NT8 actually
|
||||||
|
delivers per your Step 1 finding, or a full-window replay sequence if
|
||||||
|
NT8 delivers the complete window as historical bars) results in the
|
||||||
|
correct `_openingRangeHigh`/`_openingRangeLow`/`OpeningRangeReady`
|
||||||
|
state.
|
||||||
|
- A test proving `ProcessStrategyIntent()`'s `State == State.Historical`
|
||||||
|
early-return guard is still present and unweakened (source-text
|
||||||
|
assertion is fine here, consistent with this codebase's established
|
||||||
|
pattern for this NinjaScript-derived class — check
|
||||||
|
`TASK_GAP057_STOP_TRAIL_TEST_SEAM_PROMPT.md`'s precedent for the
|
||||||
|
nearest equivalent seam pattern).
|
||||||
|
Do not add new hydration logic that isn't needed — the point of this
|
||||||
|
path is proving existing safety, not building something redundant.
|
||||||
|
|
||||||
|
**Step 2b — if verification finds a real gap** (for example: NT8 does
|
||||||
|
*not* deliver same-day historical catch-up bars for a live/SIM late
|
||||||
|
enable the way THE QUESTION assumed, so the range would genuinely build
|
||||||
|
incomplete or wrong from only the live-onward portion of the window):
|
||||||
|
implement the minimal fix for the actual gap found. Do not guess at a
|
||||||
|
fix for a hypothetical gap — explain precisely what you found different
|
||||||
|
from the trace above and why your fix addresses it, in your writeback.
|
||||||
|
|
||||||
|
## DO NOT
|
||||||
|
|
||||||
|
- Do not touch the RTH guard, kill switch, connection-loss guard, or
|
||||||
|
`MaxDailyTrades` restart persistence (GAP-055, separate and already
|
||||||
|
implemented) — unrelated mechanisms.
|
||||||
|
- Do not touch the pullback-confirmation two-bar breakout state machine
|
||||||
|
(`_breakoutBarSeen`/`_pendingBreakoutDirection`) for its own sake. If
|
||||||
|
your Step 1 investigation finds that a late-enable scenario could leave
|
||||||
|
this state machine in a stale or incorrect state (e.g. a breakout that
|
||||||
|
"happened" only during historical catch-up bars, before the strategy
|
||||||
|
was genuinely watching), flag it explicitly in your writeback as a
|
||||||
|
separate, not-yet-decided follow-up — do not fix it as part of this
|
||||||
|
task.
|
||||||
|
- Do not change risk, sizing, or grade-filter code.
|
||||||
|
- Do not weaken or remove `ProcessStrategyIntent()`'s existing
|
||||||
|
`State == State.Historical` guard under any circumstance.
|
||||||
|
|
||||||
|
## TESTS (required)
|
||||||
|
|
||||||
|
1/2. As specified in Step 2a above, or the equivalent tests covering
|
||||||
|
whatever fix Step 2b implements if a real gap is found.
|
||||||
|
3. Confirm the full existing suite still passes.
|
||||||
|
|
||||||
|
## VALIDATION (operator)
|
||||||
|
|
||||||
|
If Step 2a applies (test-only outcome): no live-behavior change expected,
|
||||||
|
nothing new to validate on SIM beyond the existing suite passing. If Step
|
||||||
|
2b applies (a real fix was implemented): the operator should enable the
|
||||||
|
strategy on SIM after 09:30 ET on a future session and confirm
|
||||||
|
`STATE_CONTEXT`'s `OrbHigh`/`OrbLow` match the true 09:30-current range,
|
||||||
|
and confirm zero orders were submitted before the first genuine realtime
|
||||||
|
bar (check for any `HistoricalReplayCatchup` rejections in the log during
|
||||||
|
that window — their presence with no order fired is exactly the expected,
|
||||||
|
safe behavior).
|
||||||
|
|
||||||
|
## GOVERNANCE
|
||||||
|
|
||||||
|
Track as [GAP-030] in SPRINT_BOARD.md — move out of the "QUEUED —
|
||||||
|
branch-only during Gate Run #2" framing (that gate-sequencing language is
|
||||||
|
stale) into an entry reflecting whichever outcome (2a test-only, or 2b
|
||||||
|
real fix) actually happened. Update `docs/00-governance/decisions.md`
|
||||||
|
with a new dated entry referencing this task and `DEC-20260825-08`,
|
||||||
|
explicitly recording which of Step 2a/2b applied and why.
|
||||||
|
Reference: this task, `DEC-20260825-08`, `DEC-20260825-04`'s addenda (this
|
||||||
|
codebase's established pattern of tracing historical/realtime bar
|
||||||
|
handling through source before assuming a defect exists).
|
||||||
@@ -2,6 +2,12 @@
|
|||||||
# Staged: 2026-08-18 (v7.0 review, "raised, not yet prompted"), evidenced 2026-08-23/24
|
# Staged: 2026-08-18 (v7.0 review, "raised, not yet prompted"), evidenced 2026-08-23/24
|
||||||
# Sprint: Stage 1 — housekeeping, zero trading-behaviour risk (advisory-only)
|
# Sprint: Stage 1 — housekeeping, zero trading-behaviour risk (advisory-only)
|
||||||
# Owner: Kilocode
|
# Owner: Kilocode
|
||||||
|
# Deploy: COMMIT ONLY — do NOT run deploy-to-nt8.bat or copy build output to
|
||||||
|
# the live NT8 install as part of this task. The Sim101 SIM session
|
||||||
|
# is currently running and under live investigation; a redeploy
|
||||||
|
# would restart it and break session continuity. Verify-build and
|
||||||
|
# commit as usual; leave the deploy step for the operator to run
|
||||||
|
# manually once ready.
|
||||||
# ─────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
## THE DEFECT
|
## THE DEFECT
|
||||||
|
|||||||
@@ -2,6 +2,12 @@
|
|||||||
# Staged: 2026-08-18 (v7.0 review, "raised, not yet prompted"), evidenced 2026-08-23/24
|
# Staged: 2026-08-18 (v7.0 review, "raised, not yet prompted"), evidenced 2026-08-23/24
|
||||||
# Sprint: Stage 1 — real latent defect for 6E/6A, zero risk for currently-traded NQ/MNQ
|
# Sprint: Stage 1 — real latent defect for 6E/6A, zero risk for currently-traded NQ/MNQ
|
||||||
# Owner: Kilocode
|
# Owner: Kilocode
|
||||||
|
# Deploy: COMMIT ONLY — do NOT run deploy-to-nt8.bat or copy build output to
|
||||||
|
# the live NT8 install as part of this task. The Sim101 SIM session
|
||||||
|
# is currently running and under live investigation; a redeploy
|
||||||
|
# would restart it and break session continuity. Verify-build and
|
||||||
|
# commit as usual; leave the deploy step for the operator to run
|
||||||
|
# manually once ready.
|
||||||
# ─────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
## THE DEFECT
|
## THE DEFECT
|
||||||
|
|||||||
@@ -105,7 +105,25 @@ Add to `tests/NT8.Core.Tests/` or `tests/NT8.Integration.Tests/`:
|
|||||||
## VALIDATION (operator, after deploy + manual NinjaScript compile)
|
## VALIDATION (operator, after deploy + manual NinjaScript compile)
|
||||||
|
|
||||||
- SIM/replay only — NOT the live frozen account — until this passes.
|
- SIM/replay only — NOT the live frozen account — until this passes.
|
||||||
- Take one SIM trade that reaches +25 ticks or more. Confirm NO
|
- **A manually-placed order does NOT validate this.** The defect and fix both live inside
|
||||||
|
`NT8StrategyBase`'s own automated order management — `_runnerSignalName`, `_runnerActive`,
|
||||||
|
and the `SetStopLoss`/`SetTrailStop` calls in `SubmitOrderToNT8()` only get set up when
|
||||||
|
the STRATEGY submits its own entry via `EnterLong`/`EnterShort` with those signal names. A
|
||||||
|
manual order typed into the NT8 order-entry window is a completely separate position with
|
||||||
|
no signal name the strategy tracks — the runner-trailing-monitor block (`_runnerActive &&
|
||||||
|
!string.IsNullOrEmpty(_runnerSignalName)`) never engages for it, so it would prove nothing.
|
||||||
|
The strategy has to generate the trade itself.
|
||||||
|
- **When the market is closed, use NinjaTrader Market Replay (Playback connection) instead
|
||||||
|
of a live SIM trade.** Replay feeds previously-recorded historical data to the strategy at
|
||||||
|
playback speed while it is fully armed and running exactly as it would live — `OnBarUpdate`
|
||||||
|
fires per bar, `SubmitOrderToNT8()` and the runner-trailing-monitor block execute
|
||||||
|
identically. This is a legitimate substitute for a live SIM trade, not a lesser one.
|
||||||
|
Recommended: replay one of the four dates already used as this defect's evidence
|
||||||
|
(2026-08-07, 2026-08-10, 2026-08-16, or 2026-08-17 — see RUNTIME PROOF table above), since
|
||||||
|
each is already confirmed to produce a runner trade reaching 25+ ticks under the OLD
|
||||||
|
(defective) code. Replaying the same date now gives a direct before/after comparison
|
||||||
|
against the exact `BREAKEVEN runner stop ->` lines already in the record for that session.
|
||||||
|
- Take one SIM/replay trade that reaches +25 ticks or more. Confirm NO
|
||||||
`BREAKEVEN runner stop ->` line appears for the runner.
|
`BREAKEVEN runner stop ->` line appears for the runner.
|
||||||
- Confirm the runner's exit is materially better than entry + 1 tick, and that
|
- Confirm the runner's exit is materially better than entry + 1 tick, and that
|
||||||
the exit reason in the NT8 execution grid reads as a trail stop, not a
|
the exit reason in the NT8 execution grid reads as a trail stop, not a
|
||||||
|
|||||||
@@ -2,6 +2,12 @@
|
|||||||
# Staged: 2026-08-23/24 (found during live post-compile SIM validation of GAP-049)
|
# Staged: 2026-08-23/24 (found during live post-compile SIM validation of GAP-049)
|
||||||
# Sprint: Stage 1 — housekeeping, zero trading-behaviour risk (observability only)
|
# Sprint: Stage 1 — housekeeping, zero trading-behaviour risk (observability only)
|
||||||
# Owner: Kilocode
|
# Owner: Kilocode
|
||||||
|
# Deploy: COMMIT ONLY — do NOT run deploy-to-nt8.bat or copy build output to
|
||||||
|
# the live NT8 install as part of this task. The Sim101 SIM session
|
||||||
|
# is currently running and under live investigation; a redeploy
|
||||||
|
# would restart it and break session continuity. Verify-build and
|
||||||
|
# commit as usual; leave the deploy step for the operator to run
|
||||||
|
# manually once ready.
|
||||||
# ─────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
## THE DEFECT
|
## THE DEFECT
|
||||||
|
|||||||
@@ -2,6 +2,12 @@
|
|||||||
# Staged: 2026-08-24, found live during Sim101 SIM session review
|
# Staged: 2026-08-24, found live during Sim101 SIM session review
|
||||||
# Sprint: Stage 1 — logging/observability only, zero trading-behaviour risk
|
# Sprint: Stage 1 — logging/observability only, zero trading-behaviour risk
|
||||||
# Owner: Kilocode
|
# Owner: Kilocode
|
||||||
|
# Deploy: COMMIT ONLY — do NOT run deploy-to-nt8.bat or copy build output to
|
||||||
|
# the live NT8 install as part of this task. The Sim101 SIM session
|
||||||
|
# is currently running and under live investigation; a redeploy
|
||||||
|
# would restart it and break session continuity. Verify-build and
|
||||||
|
# commit as usual; leave the deploy step for the operator to run
|
||||||
|
# manually once ready.
|
||||||
# ─────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────
|
||||||
|
|
||||||
## THE DEFECT
|
## THE DEFECT
|
||||||
|
|||||||
@@ -69,8 +69,8 @@ All six `TASK_*.md` prompts are now unblocked. Nothing is waiting on you to clea
|
|||||||
- Hand `TASK_GAP047_WEIGHT_RESCORE_PROMPT.md` to Kilocode.
|
- Hand `TASK_GAP047_WEIGHT_RESCORE_PROMPT.md` to Kilocode.
|
||||||
Both can run at the same time; neither touches runtime behavior.
|
Both can run at the same time; neither touches runtime behavior.
|
||||||
|
|
||||||
**Play 3 — Review GAP-048 output. IMPLEMENTED 2026-08-23, live/dashboard spot-check pending.**
|
**Play 3 — Review GAP-048 output. IMPLEMENTED 2026-08-23, live/dashboard spot-check pending. Independently verified 2026-08-23.**
|
||||||
The overloaded `KillSwitch`, `GradeFilter`, and `TrailingDrawdownBreach` labels now split into the DEC-20260818-20 vocabulary while preserving line format and guard behavior. Tests prove SimpleORB genuine grade rejection remains `GradeFilter`, `RegimeVeto` keeps the same `REJECT:` format, and the line differs only by the `reason=` token. Build/tests/parser syntax passed and deploy backup is `20260823_142014`. Remaining operator validation: after manual NT8 compile, run one live/SIM diagnostic session and confirm `REJECT SUMMARY` shows distinct reasons and dashboard rejection panels render them.
|
The overloaded `KillSwitch`, `GradeFilter`, and `TrailingDrawdownBreach` labels now split into the DEC-20260818-20 vocabulary while preserving line format and guard behavior. Read the full diff directly: every split maps exactly to the task's suggested vocabulary (`PortfolioRisk`, `MaxTradeRisk`, `CircuitBreaker`, `LongTradesDisabled`, `ShortTradesDisabled`, `SizeBelowMinContracts`, `RegimeVeto`, `TrailingDrawdownNotConfigured`), the real `KillSwitch` path (~721) and the genuine `GradeFilter` grade-threshold rejection (SimpleORBStrategy ~677) were correctly left untouched, and no `REJECT:`/`REJECT SUMMARY:` literal format string changed. Two of the three new tests call real production code and are sound. The third (`RejectLineFormat_DiffersOnlyByReasonToken`) is tautological — it compares two hand-written literal strings rather than exercising any production code — logged as **GAP-058** (`decisions.md` DEC-20260823-02) and since fixed and committed (`f45adca`, verified: the replacement test now drives `RecordSignalRejection` twice and compares real output). Remaining operator validation: after manual NT8 compile, run one live/SIM diagnostic session and confirm `REJECT SUMMARY` shows distinct reasons and dashboard rejection panels render them.
|
||||||
|
|
||||||
**Play 4 — Review GAP-047 output and apply runtime weights. DONE 2026-08-23.**
|
**Play 4 — Review GAP-047 output and apply runtime weights. DONE 2026-08-23.**
|
||||||
Part 1: Kilocode built `tools/rescore/rescore_weights.py`, scanned 182 session logs, reproduced the required worked example exactly (equal=0.640, designed=0.727), and reported the STATE telemetry population (923 samples, direction-degraded per GAP-049) separately from the real signal population (81 samples), per the task's caveat. Independently re-derived the headline numbers from the raw distribution tables in `GAP-047_weight_rescore_output.md` rather than trusting the summary — they check out, including that the signal population's "25 cross into A" figure is a gross count net of a small number of downgrades (consistent with the report's own note that some real signals score worse under designed weights).
|
Part 1: Kilocode built `tools/rescore/rescore_weights.py`, scanned 182 session logs, reproduced the required worked example exactly (equal=0.640, designed=0.727), and reported the STATE telemetry population (923 samples, direction-degraded per GAP-049) separately from the real signal population (81 samples), per the task's caveat. Independently re-derived the headline numbers from the raw distribution tables in `GAP-047_weight_rescore_output.md` rather than trusting the summary — they check out, including that the signal population's "25 cross into A" figure is a gross count net of a small number of downgrades (consistent with the report's own note that some real signals score worse under designed weights).
|
||||||
@@ -82,14 +82,14 @@ Kilocode implemented Option 0: removed the `OnBarUpdate()` `SetStopLoss` call on
|
|||||||
**Play 6 — Validate GAP-054 before any live exposure. STILL PENDING — this is the next actual step.**
|
**Play 6 — Validate GAP-054 before any live exposure. STILL PENDING — this is the next actual step.**
|
||||||
NinjaTrader needs to be reopened for a manual NinjaScript compile, then a SIM trade run reaching +25 ticks or more, confirming no `BREAKEVEN runner stop ->` line appears and the runner's exit is materially better than entry + 1 tick (a trail stop in the execution grid, not a fixed stop), and that the scaler leg's target behavior is unchanged. Only after this passes is GAP-054 done and RUNNER-001 unblocked.
|
NinjaTrader needs to be reopened for a manual NinjaScript compile, then a SIM trade run reaching +25 ticks or more, confirming no `BREAKEVEN runner stop ->` line appears and the runner's exit is materially better than entry + 1 tick (a trail stop in the execution grid, not a fixed stop), and that the scaler leg's target behavior is unchanged. Only after this passes is GAP-054 done and RUNNER-001 unblocked.
|
||||||
|
|
||||||
**Play 7 — Risk guards, all three parts (DEC-19a/19b accepted). IMPLEMENTED 2026-08-23, manual NQ SIM validation pending.**
|
**Play 7 — Risk guards, all three parts (DEC-19a/19b accepted). IMPLEMENTED 2026-08-23, manual NQ SIM validation pending. Independently verified 2026-08-23.**
|
||||||
`TASK_GAP045_GAP046_RISK_GUARDS_PROMPT.md` now fails startup for incoherent risk-envelope pairs, confirms MNQ is already `$0.50` in both hardcoded tick-value tables, and moves the live NT8 per-position `MaxTradeRisk` check to after sizing so `StopTicks * TickValue * Qty <= MaxTradeRisk` is enforced. Build/tests/deploy passed with backup `20260823_144817`. Remaining validation: manual NT8 compile, NQ SIM guard checks, and high-ATR signal behavior. The MNQ cutover is still Play 11 and was not started.
|
`TASK_GAP045_GAP046_RISK_GUARDS_PROMPT.md` now fails startup for incoherent risk-envelope pairs, confirms MNQ is already `$0.50` in both hardcoded tick-value tables, and moves the live NT8 per-position `MaxTradeRisk` check to after sizing so `StopTicks * TickValue * Qty <= MaxTradeRisk` is enforced. Read the full `BasicRiskManager.cs`/`NT8StrategyBase.cs` diffs directly: the four `RiskEnvelopeValidator.ValidateStartupConfiguration` assertions match Part 1 exactly (notably `MaxTradeRisk <= DailyLossLimit`, the corrected per-position formula, not the old `MaxTradeRisk * MaxContracts`), the old pre-sizing risk block was removed rather than duplicated, and the new order flow is size-then-validate as required. No errors found. Build/tests/deploy passed with backup `20260823_144817`. Remaining validation: manual NT8 compile, NQ SIM guard checks, and high-ATR signal behavior. The MNQ cutover is still Play 11 and was not started.
|
||||||
|
|
||||||
**Play 8 — MaxDailyTrades persistence (DEC-21 accepted). IMPLEMENTED 2026-08-23, manual SIM restart validation pending.**
|
**Play 8 — MaxDailyTrades persistence (DEC-21 accepted). IMPLEMENTED 2026-08-23, manual SIM restart validation pending. Independently verified 2026-08-23.**
|
||||||
`TASK_GAP055_MAXDAILYTRADES_PERSIST_PROMPT.md` now persists `{trading_date, daily_trade_count, account, strategy_name, symbol}` to `daily_trade_count_<AccountName>_<StrategyName>.json`, rehydrates same-date count, resets and overwrites on a new trading date, and skips file I/O when `Account == null`. Automated tests cover same-date restore, new-date reset, corrupt file, backtest no-I/O, and the 2026-08-16 19:12 / 2026-08-17 11:04 same-CME-date scenario. Remaining validation: manual NT8 compile plus SIM restart test confirming the next same-day signal rejects with `REJECT: reason=MaxDailyTrades`.
|
`TASK_GAP055_MAXDAILYTRADES_PERSIST_PROMPT.md` now persists `{trading_date, daily_trade_count, account, strategy_name, symbol}` to `daily_trade_count_<AccountName>_<StrategyName>.json`, rehydrates same-date count, resets and overwrites on a new trading date, and skips file I/O when `Account == null`. Read the full diff across all three touched source files (`SimpleORBStrategy.cs`, `NT8StrategyBase.cs`, `SimpleORBNT8.cs`): the `daily_trade_count_*` parameter keys are wired consistently end-to-end — `SimpleORBNT8.cs` seeds them into `StrategyConfig`, `NT8StrategyBase.cs` passes them again at `State.Realtime` and on every realtime `CustomData` build (gated on `Account != null`), and `SimpleORBStrategy.cs` consumes them for persistence/rehydration. Trading-date derivation correctly reuses existing `Session.SessionStart` infrastructure rather than reinventing an 18:00 ET calculation. Automated tests cover same-date restore, new-date reset, corrupt file, backtest no-I/O, and the 2026-08-16 19:12 / 2026-08-17 11:04 same-CME-date scenario — the key `Persistence_SundayEveningAndMondayMorning_ResolveToSameCmeTradingDate` test read in full and confirmed legitimate (two real strategy instances simulating an actual restart). No errors found. Remaining validation: manual NT8 compile plus SIM restart test confirming the next same-day signal rejects with `REJECT: reason=MaxDailyTrades`.
|
||||||
|
|
||||||
**Play 9 — GAP-049 telemetry direction fix.**
|
**Play 9 — GAP-049 telemetry direction fix. IMPLEMENTED 2026-08-23, live/SIM STATE_DETAIL spot-check pending. Independently verified 2026-08-23.**
|
||||||
No decision gate — this is dashboard/telemetry accuracy only. Hand `TASK_GAP049_TELEMETRY_DIRECTION_PROMPT.md` to Kilocode any time today. Validate by re-checking the implausible -523.25 point gap value the task flags; confirm it resolves to a sane number after the fix.
|
`SimpleORBNT8.BuildStateTelemetryIntent()` now builds a clone of `DailyBarContext` (confirmed it's a `struct` in `FactorCalculators.cs` — the `daily = source` copy is safe for this use because only scalar fields are reassigned on the clone, never the shared array fields), sets clone-only `TradeDirection`/`BreakoutBarVolume`/`TodayOpen`/`AvgIntradayBarVolume` from the telemetry intent's own side and the pre-existing stable `session_open_price`/`avg_volume` context fields (not fabricated — both already used by the real trade path in `SimpleORBStrategy.cs`), and attaches `orb_range_ticks` metadata. The shared `_strategyConfig.Parameters["daily_bars"]` object is never mutated, satisfying DEC-20260818-06. Read the full diff directly — confirmed. The P1-E gap-magnitude finding checks out on its own evidence: the same session log reported the "-523.25" gap as different values throughout one RTH session (roughly -389.75 to -555.75 per the decisions.md entry), which by itself proves it was reading a drifting current-bar value rather than a fixed overnight open, independent of the cited external NQ close/open figures. New tests: `OrbConfluenceFactorTests.cs`'s `GapDirection_LargeDownGapForSell_ScoresOneAndAligns` executes the real `GapDirectionAlignmentCalculator` against the exact cited 30096/30077 values and confirms Score=1.0, "aligns with trade" — legitimate. `SimpleORBNT8DefaultsTests.cs`'s two new tests are source-text assertions (grep the compiled method body for expected lines), not execution tests — this matches the file's pre-existing pattern for this NinjaScript-derived adapter class, which can't be instantiated outside NT8 to test by execution; not a new GAP-058-style tautology, just a weaker coverage tier used because a real execution seam doesn't exist here. No errors found. Remaining validation: manual NT8 compile, then one live/SIM session confirming `STATE_DETAIL` for a sell setup with a down gap reports aligned, and `OrbRangeVsAtr` no longer reads "no daily bar context available" when warm-up is satisfied.
|
||||||
|
|
||||||
**Play 10 — Close out today's six items.**
|
**Play 10 — Close out today's six items.**
|
||||||
For every item completed today: flip its `decisions.md` Status to `implemented` as appropriate, update `SPRINT_BOARD.md` and `active_work.md` to move it out of the blockers section, and commit the governance-doc changes. Leave anything not completed today explicitly marked with what's left and why.
|
For every item completed today: flip its `decisions.md` Status to `implemented` as appropriate, update `SPRINT_BOARD.md` and `active_work.md` to move it out of the blockers section, and commit the governance-doc changes. Leave anything not completed today explicitly marked with what's left and why.
|
||||||
@@ -117,7 +117,7 @@ This is a separate, later step — not part of today's six tasks. Once GAP-054,
|
|||||||
- [ ] GAP-054 runner trail: implemented, validated on sim/replay before any live gate run
|
- [ ] GAP-054 runner trail: implemented, validated on sim/replay before any live gate run
|
||||||
- [x] GAP-055 persistence: implemented and automated restart/rollover-boundary tests passed; manual SIM restart validation pending
|
- [x] GAP-055 persistence: implemented and automated restart/rollover-boundary tests passed; manual SIM restart validation pending
|
||||||
- [x] GAP-045/046 all three parts: implemented on NQ, including the post-sizing Tier 1 reorder and the MNQ tick-table check; manual NQ SIM validation pending
|
- [x] GAP-045/046 all three parts: implemented on NQ, including the post-sizing Tier 1 reorder and the MNQ tick-table check; manual NQ SIM validation pending
|
||||||
- [ ] GAP-049 telemetry: implemented, -523.25 anomaly re-checked and resolved
|
- [x] GAP-049 telemetry: implemented and tested; -523.25 anomaly root-caused (data-alignment defect, not a real gap) and fixed; manual NT8 compile + live/SIM STATE_DETAIL spot-check pending
|
||||||
- [ ] `git status --short` re-checked: confirm exactly the files each TASK prompt's DO list authorized, nothing else
|
- [ ] `git status --short` re-checked: confirm exactly the files each TASK prompt's DO list authorized, nothing else
|
||||||
- [ ] SPRINT_BOARD.md, active_work.md, decisions.md all reflect end-of-day state
|
- [ ] SPRINT_BOARD.md, active_work.md, decisions.md all reflect end-of-day state
|
||||||
- [ ] MNQ cutover (Play 11) explicitly NOT started until the six items above are validated — confirm it's still pending, not skipped
|
- [ ] MNQ cutover (Play 11) explicitly NOT started until the six items above are validated — confirm it's still pending, not skipped
|
||||||
|
|||||||
@@ -1,12 +1,16 @@
|
|||||||
# Active Work
|
# Active Work
|
||||||
**Last Updated:** 2026-08-19 (all four proposed decisions accepted; see decisions.md)
|
**Last Updated:** 2026-08-23 (items 2-5, 7 implemented and deployed to NT8; each still awaits manual NT8 compile + SIM/live validation before being closed)
|
||||||
|
|
||||||
## READY 2026-08-19 — v7.0 review blockers, decisions accepted, none yet executed
|
## v7.0 review blockers — decisions accepted 2026-08-19, implementation status below
|
||||||
|
|
||||||
All four decisions proposed 2026-08-18 were accepted by the operator on 2026-08-19
|
All four decisions proposed 2026-08-18 were accepted by the operator on 2026-08-19
|
||||||
(DEC-20260818-18, -19, -20, -21), plus a new DEC-20260819-01 sequencing the MNQ
|
(DEC-20260818-18, -19, -20, -21), plus a new DEC-20260819-01 sequencing the MNQ
|
||||||
instrument cutover as its own follow-on step. Nothing below has been implemented yet —
|
instrument cutover as its own follow-on step. Items 2, 3, 4, 5 and 7 below are now
|
||||||
these are now unblocked for Kilocode, not still awaiting a decision.
|
code-complete, tested, and deployed (see each row and `decisions.md` for commit/backup
|
||||||
|
evidence) but each still requires a manual NinjaScript compile plus the SIM/live
|
||||||
|
validation step named in its "Blocking" column before it is fully closed. Item 6
|
||||||
|
(GAP-054) is implemented, committed (`28c30bc`), and deployed, but its own SIM/replay
|
||||||
|
validation has not run yet. Item 8 (MNQ cutover) has not started.
|
||||||
Play-by-play execution order: `docs/00-governance/2026-08-19-run-book.md`.
|
Play-by-play execution order: `docs/00-governance/2026-08-19-run-book.md`.
|
||||||
Full detail: `docs/NT8_SDK_Master_Document_v7.0_Complete.docx`.
|
Full detail: `docs/NT8_SDK_Master_Document_v7.0_Complete.docx`.
|
||||||
|
|
||||||
@@ -17,14 +21,15 @@ Full detail: `docs/NT8_SDK_Master_Document_v7.0_Complete.docx`.
|
|||||||
| 3 | **GAP-048** — split the reject taxonomy | `TASK_GAP048_REJECT_TAXONOMY_PROMPT.md` — implemented/deployed 2026-08-23, backup `20260823_142014` | Kilocode | Manual NT8 compile and dashboard spot-check |
|
| 3 | **GAP-048** — split the reject taxonomy | `TASK_GAP048_REJECT_TAXONOMY_PROMPT.md` — implemented/deployed 2026-08-23, backup `20260823_142014` | Kilocode | Manual NT8 compile and dashboard spot-check |
|
||||||
| 4 | **GAP-055** — persist `MaxDailyTrades` across restarts | `TASK_GAP055_MAXDAILYTRADES_PERSIST_PROMPT.md` — implemented/deployed 2026-08-23, backup `20260823_143311` | Kilocode | Manual NT8 compile and SIM restart validation |
|
| 4 | **GAP-055** — persist `MaxDailyTrades` across restarts | `TASK_GAP055_MAXDAILYTRADES_PERSIST_PROMPT.md` — implemented/deployed 2026-08-23, backup `20260823_143311` | Kilocode | Manual NT8 compile and SIM restart validation |
|
||||||
| 5 | **GAP-047** — Part 1 complete (commit `cbf45df`), Part 2 runtime weight fix implemented 2026-08-23 | `TASK_GAP047_PART2_WEIGHT_RUNTIME_PROMPT.md` — verification passed, deploy backup `20260823_135331` | Kilocode | Fresh gate freeze needed before gate evidence |
|
| 5 | **GAP-047** — Part 1 complete (commit `cbf45df`), Part 2 runtime weight fix implemented 2026-08-23 | `TASK_GAP047_PART2_WEIGHT_RUNTIME_PROMPT.md` — verification passed, deploy backup `20260823_135331` | Kilocode | Fresh gate freeze needed before gate evidence |
|
||||||
| 6 | **GAP-054** — auto-breakeven destroys the runner trail | `TASK_GAP054_RUNNER_TRAIL_PROMPT.md` — **Option 0 implemented + source-verified 2026-08-21, NOT yet SIM-validated, NOT committed** | Kilocode implemented; operator validates | **RUNNER-001**, still blocked until SIM/replay validation passes |
|
| 6 | **GAP-054** — auto-breakeven destroys the runner trail | `TASK_GAP054_RUNNER_TRAIL_PROMPT.md` — **Option 0 implemented + source-verified 2026-08-21, committed `28c30bc`, deployed (backup `20260821_144039`), NOT yet SIM/replay-validated** | Kilocode implemented; operator validates | **RUNNER-001**, still blocked until SIM/replay validation passes |
|
||||||
| 7 | **GAP-049** — telemetry `STATE:` score is direction-incorrect | `TASK_GAP049_TELEMETRY_DIRECTION_PROMPT.md` | Kilocode | Dashboard trustworthiness; degrades item 5 |
|
| 7 | **GAP-049** — telemetry `STATE:` score is direction-incorrect | `TASK_GAP049_TELEMETRY_DIRECTION_PROMPT.md` — implemented/deployed 2026-08-23, backup `20260823_151931` | Kilocode | Manual NT8 compile and live/SIM STATE_DETAIL spot-check |
|
||||||
| 8 | **MNQ cutover** — reconfigure instrument, retune risk params for $0.50/tick, fresh Gate 3 freeze | not yet staged as its own TASK file | Operator + Kilocode | Only after items 2, 4, 5, 6 pass validation on NQ |
|
| 8 | **MNQ cutover** — reconfigure instrument, retune risk params for $0.50/tick, fresh Gate 3 freeze | not yet staged as its own TASK file | Operator + Kilocode | Only after items 2, 4, 5, 6 pass validation on NQ |
|
||||||
|
|
||||||
**Sequencing note:** items 3 and 5 carry zero trading risk and can proceed immediately, in
|
**Sequencing note:** items 3, 5, and 7 carry zero trading risk (diagnostics/telemetry/
|
||||||
parallel with everything else. Item 6 must land (and validate on SIM/replay) before
|
scoring-policy only, no order-management path touched) and have all landed. Item 6 must
|
||||||
RUNNER-001 is executed. Item 8 (MNQ cutover) must NOT start until items 2, 4, 5, and 6
|
land (and validate on SIM/replay) before RUNNER-001 is executed. Item 8 (MNQ cutover)
|
||||||
have landed and validated on the current NQ configuration — see DEC-20260819-01.
|
must NOT start until items 2, 4, 5, and 6 have landed and validated on the current NQ
|
||||||
|
configuration — see DEC-20260819-01.
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
@@ -13,14 +13,36 @@ Use this file to record durable project decisions that affect implementation pat
|
|||||||
|
|
||||||
## Decision Log
|
## Decision Log
|
||||||
|
|
||||||
|
### DEC-20260826-03
|
||||||
|
- **ID:** DEC-20260826-03
|
||||||
|
- **Date:** 2026-08-26
|
||||||
|
- **Status:** decided — both prompted
|
||||||
|
- **Context:** Operator asked what else could be pulled from the roadmap after GAP-062. `GAP-025` ("Runner No-Fill Anomaly Diagnosis") and `GAP-030` ("Historical ORB State Hydration") have sat in the Sprint 2.7 backlog since it was created, both still framed around a now-stale "branch-only during Gate Run #2" gate-sequencing rule. Read the actual current source before prompting either rather than reusing the old one-line descriptions:
|
||||||
|
- **GAP-025:** `NT8StrategyBase.OnOrderUpdate()` (~1270-1301) never writes to `FileLog` for any order state except `Rejected`; `OnExecutionUpdate()`'s `FILL` line (~1306-1345) doesn't include the order/signal name. Since a trade submits two independently-named orders (`SDK_{Symbol}_S_{hex}` scaler, `SDK_{Symbol}_R_{hex}` runner), the persistent session log currently cannot distinguish which leg filled, or show a runner order's lifecycle (submitted/accepted/working/cancelled) at all outside NT8's live Output window — this is the real, previously-unspecified mechanism behind the old "no-fill anomaly" framing.
|
||||||
|
- **GAP-030:** tracing `SimpleORBStrategy.OnBar()`'s ORB-window logic, `StrategyContext`, `NT8StrategyBase.OnBarUpdate()`'s replay-burst guard, and `ProcessStrategyIntent()`'s existing `State == State.Historical` order-block found reason to believe both halves of GAP-030's original ask (correct range reconstruction from historical bars, zero orders from historical bars) already work by construction — Core's `UpdateOpeningRange()` is state-blind and `ProcessStrategyIntent()` already refuses `State.Historical` orders. This has never been tested end-to-end, and rests on one assumption not verifiable from source alone (whether NT8 actually delivers same-day historical catch-up bars on a late enable).
|
||||||
|
- **Decision:** Prompted `TASK_GAP025_RUNNER_ORDER_LIFECYCLE_LOGGING_PROMPT.md` as diagnostic-only logging (zero trading-behaviour risk — adds `FileLog` calls around existing order/execution events, touches no order-management logic). Prompted `TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md` as a verify-first task: Kilocode must confirm or correct the traced behavior above before implementing anything, and if confirmed, the task's deliverable is test coverage proving the existing safety rather than new production logic — only implement a fix if verification finds a genuine gap.
|
||||||
|
- **Consequences:** Neither task carries deploy risk on its own (GAP-025 is logging-only; GAP-030 is verify-first and likely test-only). Both replace the stale "Gate Run #2" gating language in `SPRINT_BOARD.md` with the current PROMPTED status.
|
||||||
|
- **Related Files:** `TASK_GAP025_RUNNER_ORDER_LIFECYCLE_LOGGING_PROMPT.md`, `TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md`, `src/NT8.Adapters/Strategies/NT8StrategyBase.cs`, `src/NT8.Strategies/Examples/SimpleORBStrategy.cs`, `src/NT8.Core/Common/Models/StrategyContext.cs`, `SPRINT_BOARD.md`.
|
||||||
|
- **Action Required:** Await Kilocode's implementation and commits for both. Per standing practice, verify each by reading the actual diff directly — DEC-20260826-02 (above) is a fresh reminder why that includes checking deploy-status claims against `deployment/backups/`, not just trusting the commit message or governance-doc text.
|
||||||
|
|
||||||
|
### DEC-20260826-02
|
||||||
|
- **ID:** DEC-20260826-02
|
||||||
|
- **Date:** 2026-08-26
|
||||||
|
- **Status:** resolved — deployed by explicit operator request
|
||||||
|
- **Context:** Verifying Kilocode's GAP-062 commit (`885e298`) per standing practice (read the diff and evidence directly, don't trust the summary) found a direct contradiction. `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`'s header explicitly said `Deploy: COMMIT ONLY — do NOT run deploy-to-nt8.bat or copy build output to the live NT8 install as part of this task`, and both `SPRINT_BOARD.md`'s GAP-062 entry and `DEC-20260826-01` (Kilocode's own governance-doc updates, committed in the same commit) state "Deploy intentionally skipped by task prompt." But the commit's own trailer reads `Build: clean | Tests: 569 passing | Dual-deployed: yes, backup 20260826_005308` — and `deployment/backups/20260826_005308/` genuinely exists on disk, containing a `manifest.txt` (timestamped matching the commit) plus pre-deploy DLL backups. Reading `deployment/deploy-to-nt8.bat` directly confirms the backup step only runs as the first half of a full deploy (back up existing live DLLs, then copy the new build over them, with `errorlevel`-checked failure exits at each copy) — the existence of a completed backup folder is strong evidence the script ran past the backup step, not proof by itself that every copy succeeded, but combined with the "Dual-deployed: yes" trailer this reads as a real deploy having completed to `C:\Users\billy\Documents\NinjaTrader 8\bin\Custom`, not a skipped one.
|
||||||
|
- **Why this matters:** GAP-062 is explicitly a real scoring-behavior change (not observability-only) — the task and `DEC-20260825-06` both required SIM before/after observation before trusting it live, specifically because it can newly qualify short setups that were previously capped below Grade A. If the live NT8 install now has this build, that validation gate was bypassed, and the documentation trail (SPRINT_BOARD.md, DEC-20260826-01) is actively wrong about deploy status — this is exactly the class of discrepancy the standing "verify via diff, not summary" practice exists to catch, and this time the summary in the governance docs themselves (not just the commit message) was wrong.
|
||||||
|
- **Resolution:** Operator explicitly requested `deploy and commit` after the GAP-062 implementation. `deployment\deploy-to-nt8.bat` was run from the repo and completed successfully, creating backup `deployment\backups\20260826_005308`; `NinjaTrader.Custom.dll` was not present to invalidate. GAP-062 should now be treated as deployed to the local NT8 Custom folder, not skipped. This resolves the documentation mismatch, but it does not remove the validation requirement: because GAP-062 is a scoring-behavior change, the next strategy run should be treated as SIM validation before live trust.
|
||||||
|
- **Related Files:** `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`, `deployment/deploy-to-nt8.bat`, `deployment/backups/20260826_005308/`, `SPRINT_BOARD.md`, `docs/00-governance/decisions.md` (`DEC-20260826-01`).
|
||||||
|
- **Action Required:** Run manual NinjaScript compile and SIM before/after observation before trusting GAP-062 live. Confirm that at least one comparable confirmed-downtrend short can now score Grade A when appropriate, and that long-side Grade distribution remains sane.
|
||||||
|
|
||||||
### DEC-20260826-01
|
### DEC-20260826-01
|
||||||
- **ID:** DEC-20260826-01
|
- **ID:** DEC-20260826-01
|
||||||
- **Date:** 2026-08-26
|
- **Date:** 2026-08-26
|
||||||
- **Status:** implemented — commit-only, pending SIM observation
|
- **Status:** implemented and deployed by operator request — pending SIM observation
|
||||||
- **Context:** GAP-062 followed `DEC-20260825-04` and `DEC-20260825-06`: short candidates could earn the negative-slope `slopeAligned` bonus or the old positive-slope `trend_confirm` bonus, but not both, because `trend_confirm` was computed as `avwapSlope > 0.0 ? 1.0 : 0.0` before the scorer evaluated trade side. No deployed GAP-061 telemetry evidence was available in the current NT8 session log directory (`TrendConfirm`/`AvwapSlope` not found), so implementation rested on the source-level proof and tests.
|
- **Context:** GAP-062 followed `DEC-20260825-04` and `DEC-20260825-06`: short candidates could earn the negative-slope `slopeAligned` bonus or the old positive-slope `trend_confirm` bonus, but not both, because `trend_confirm` was computed as `avwapSlope > 0.0 ? 1.0 : 0.0` before the scorer evaluated trade side. No deployed GAP-061 telemetry evidence was available in the current NT8 session log directory (`TrendConfirm`/`AvwapSlope` not found), so implementation rested on the source-level proof and tests.
|
||||||
- **Decision:** Implement GAP-062 by publishing side-specific `trend_confirm_long` and `trend_confirm_short` values in `SimpleORBStrategy.UpdateConfluenceInputs()` using the already-computed AVWAP slope, then make `TrendAlignmentFactorCalculator` select the side-specific value matching `intent.Side`. Preserve the existing `TrendAlignmentFactorCalculator` score structure and weights exactly: `+0.4` price aligned to AVWAP, `+0.3` slope aligned to trade side, `+0.3` selected trend confirmation. Preserve the existing `STATE_CONTEXT` key shape by continuing to emit `TrendConfirm` as the legacy `trend_confirm` field, now resolved from pending/current breakout direction where available.
|
- **Decision:** Implement GAP-062 by publishing side-specific `trend_confirm_long` and `trend_confirm_short` values in `SimpleORBStrategy.UpdateConfluenceInputs()` using the already-computed AVWAP slope, then make `TrendAlignmentFactorCalculator` select the side-specific value matching `intent.Side`. Preserve the existing `TrendAlignmentFactorCalculator` score structure and weights exactly: `+0.4` price aligned to AVWAP, `+0.3` slope aligned to trade side, `+0.3` selected trend confirmation. Preserve the existing `STATE_CONTEXT` key shape by continuing to emit `TrendConfirm` as the legacy `trend_confirm` field, now resolved from pending/current breakout direction where available.
|
||||||
- **Symmetry proof:** Tests now prove the three required cases. A short candidate with price below AVWAP, `avwap_slope < 0`, and `trend_confirm_short = 1.0` reaches `Trend=1.0`, equal to a symmetric long with price above AVWAP, `avwap_slope > 0`, and `trend_confirm_long = 1.0`. A short candidate evaluated against an uptrend (`avwap_slope > 0`, `trend_confirm_short = 0.0`) does not earn trend confirmation and scores only the price-alignment component in the fixture. A long in a confirmed uptrend still reads `trend_confirm = 1.0` in factor details and reaches `Trend=1.0`, preserving long-side behavior.
|
- **Symmetry proof:** Tests now prove the three required cases. A short candidate with price below AVWAP, `avwap_slope < 0`, and `trend_confirm_short = 1.0` reaches `Trend=1.0`, equal to a symmetric long with price above AVWAP, `avwap_slope > 0`, and `trend_confirm_long = 1.0`. A short candidate evaluated against an uptrend (`avwap_slope > 0`, `trend_confirm_short = 0.0`) does not earn trend confirmation and scores only the price-alignment component in the fixture. A long in a confirmed uptrend still reads `trend_confirm = 1.0` in factor details and reaches `Trend=1.0`, preserving long-side behavior.
|
||||||
- **Consequences:** This is a real scoring-behavior change, not observability-only. Previously B/C-capped short setups can now legitimately reach Grade A and pass `MinTradeGrade=A` when AVWAP slope genuinely confirms the short. Deploy was intentionally skipped per `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`; operator SIM before/after observation is required before trusting this live.
|
- **Consequences:** This is a real scoring-behavior change, not observability-only. Previously B/C-capped short setups can now legitimately reach Grade A and pass `MinTradeGrade=A` when AVWAP slope genuinely confirms the short. Deploy was originally skipped per `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`, then completed after explicit operator request; operator SIM before/after observation is required before trusting this live.
|
||||||
- **Verification:** `dotnet test tests\NT8.Core.Tests\NT8.Core.Tests.csproj --configuration Release --no-build --filter "FullyQualifiedName~Intelligence" --verbosity minimal` passed 89/89. `verify-build.bat` passed 569/569. Existing CS1998 warnings in unrelated OMS/mock test files remain present, but the verification script reported `All checks passed`.
|
- **Verification:** `dotnet test tests\NT8.Core.Tests\NT8.Core.Tests.csproj --configuration Release --no-build --filter "FullyQualifiedName~Intelligence" --verbosity minimal` passed 89/89. `verify-build.bat` passed 569/569. Existing CS1998 warnings in unrelated OMS/mock test files remain present, but the verification script reported `All checks passed`.
|
||||||
- **Related Files:** `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`, `src/NT8.Strategies/Examples/SimpleORBStrategy.cs`, `src/NT8.Core/Intelligence/FactorCalculators.cs`, `tests/NT8.Core.Tests/Intelligence/OrbConfluenceFactorTests.cs`, `SPRINT_BOARD.md`, `docs/00-governance/current_status.md`.
|
- **Related Files:** `TASK_GAP062_TREND_CONFIRM_DIRECTION_PROMPT.md`, `src/NT8.Strategies/Examples/SimpleORBStrategy.cs`, `src/NT8.Core/Intelligence/FactorCalculators.cs`, `tests/NT8.Core.Tests/Intelligence/OrbConfluenceFactorTests.cs`, `SPRINT_BOARD.md`, `docs/00-governance/current_status.md`.
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user