]> Piment Noir Git Repositories - freqai-strategies.git/commit
fix(quickadapter): preserve calendar PnL continuity (#142)
authorJérôme Benoit <jerome.benoit@piment-noir.org>
Tue, 28 Jul 2026 13:56:27 +0000 (15:56 +0200)
committerGitHub <noreply@github.com>
Tue, 28 Jul 2026 13:56:27 +0000 (15:56 +0200)
commit864ed7e69e62a5cd788a1a9d3868ccdef86916d0
tree095db2d5467b451015aa0d743f0f8d10809f90b0
parent5b4c7f8cc24779747e1b9fc3271a550482ef0fb1
fix(quickadapter): preserve calendar PnL continuity (#142)

* fix(quickadapter): preserve calendar PnL continuity

* fix(quickadapter): drop epoch-anchored phase guard in PnL continuity

The (month-1) % n phase guard on the MS path assumed a fixed January
epoch, but pandas resample anchors calendar bins on the data origin, not
a fixed epoch, so it wrongly reset valid non-January-anchored multi-month
series (e.g. a Feb/May/Aug 3M grid). is_on_offset already rejects a
non-boundary stored date and stored + offset is the exact next candle for
any anchor phase, so the membership test alone is correct and symmetric
for MS and YS (resolving the MS/YS asymmetry). Also complete the
_TradeHistory key-mirror comment with the legacy timeframe-minutes key.

* style(quickadapter): tighten PnL continuity phase-guard rationale comment
quickadapter/user_data/strategies/QuickAdapterV3.py