Skip to content

Commit 144d02c

Browse files
luisleo526luisleo526claude
authored
docs: record the grading profiles and sweep limits (#732)
* docs: record the grading profiles and sweep limits Write down the declared limits of both grading profiles in scripts/verify_corpus.py (strict, and trail / production for strategies whose strategy.exit uses a trail_* parameter), how the 90th-percentile gates are computed, that an excellent grade needs exact trade-count parity, how each probe's profile is selected, and how many of the 7,989 sweep probes each profile applies to. Documentation only; no code or test change. Co-Authored-By: Claude Opus 5.5 <[email protected]> * docs: state the trail-profile probe count by strategies only Co-Authored-By: Claude Opus 5.5 <[email protected]> * docs: match the profile-selection and p90 wording to the verifier The production profile is selected by a trail_points, trail_offset or trail_price assignment in the strategy source (outside comments), and the entry gate is graded at the 90th percentile too. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: luisleo526 <[email protected]> Co-authored-by: Claude Opus 5.5 <[email protected]>
1 parent 91b6672 commit 144d02c

1 file changed

Lines changed: 32 additions & 3 deletions

File tree

‎docs/coverage.md‎

Lines changed: 32 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -992,11 +992,40 @@ this runtime delivers the surface listed above. Run
992992
against `libpineforge.a` and diff each probe's `engine_trades.csv`
993993
against the TradingView export shipped beside it;
994994
`python3 scripts/verify_corpus.py --all` grades the shipped trade lists by
995-
the canonical rubric. Its strict profile gates count + entry-price +
995+
the canonical rubric. Its strict profile declares limits for count + entry-price +
996996
exit-price + P&L within `1.0% / 0.01% / 0.01% / 1.0%`; a strategy whose
997-
`strategy.exit` uses a `trail_*` parameter gets the production profile, with
997+
source assigns `trail_points`, `trail_offset` or `trail_price` (outside
998+
comments) gets the production profile, with
998999
the same count and entry limits, exit within 0.02%, and P&L within 1%.
999-
The exit and P&L gates are graded per strategy at the 90th percentile, not every trade.
1000+
The entry, exit and P&L gates are graded per strategy at the 90th percentile, not every trade.
1001+
1002+
### Grading profiles and sweep limits
1003+
1004+
The declared profile limits in
1005+
[`scripts/verify_corpus.py`](../scripts/verify_corpus.py) are:
1006+
1007+
| Profile | Count delta (declared) | Entry-price p90 | Exit-price p90 | P&L p90 |
1008+
| ------- | ---------------------- | --------------- | -------------- | ------- |
1009+
| Strict | 1.0% | < 0.01% | < 0.01% | < 1.0% |
1010+
| Trail / production | 1.0% | < 0.01% | < 0.02% | < 1.0% |
1011+
1012+
For both profiles, an `excellent` grade requires exact gated trade-count
1013+
parity; the declared 1.0% count limit does not permit missing or extra
1014+
trades for that grade. The entry, exit and P&L gates require each strategy's
1015+
90th-percentile (p90) delta to be strictly below the corresponding limit.
1016+
The verifier computes p90 by sorting the deltas and linearly interpolating
1017+
at index `(n - 1) * 0.90`. Exit and P&L are per-strategy gates, not
1018+
requirements that every trade pass; P&L deltas include the verifier's
1019+
near-zero, rounding, quantity-normalization and exit-drift adjustments.
1020+
1021+
For the sweep, each probe's profile is selected automatically from its
1022+
strategy source by `detect_parity_profile`: after comments are removed,
1023+
a `trail_points`, `trail_offset` or `trail_price` assignment selects
1024+
production; otherwise it selects strict. The standalone verifier also
1025+
supports an explicit `parity_profile` override in `inputs.json`.
1026+
The sweep applies trail / production limits to 341 of its 7,989 probes
1027+
(58 distinct strategies) and strict limits to
1028+
the other 7,648 probes.
10001029
10011030
One probe, `corpus/validation/anomaly-equity-mirror-strategy-equity-01`,
10021031
declares `expected_tier: anomaly` in its `inputs.json`: it pins the 1× equity

0 commit comments

Comments
 (0)