Skip to content

feat(risk): apply_combined_scale_to_targets for live sizing - #611

Merged
Pigbibi merged 1 commit into
mainfrom
fix/qpk-envelope-target-scale-20260918
Sep 18, 2026
Merged

Pigbibi merged 1 commit into
mainfrom
fix/qpk-envelope-target-scale-20260918

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add apply_combined_scale_to_targets(targets, combined_scale) for platform live wiring.
  • Missing/invalid scale → omit (unchanged targets); valid scale → shrink-only.
  • Does not raise RRL or invent Kelly sizing.

Test plan

  • uv run --with pytest python -m pytest tests/test_capital_risk_envelope.py -q (25 passed)
  • CI green

Made with Cursor

Add a dict helper that omits when combined_scale is missing/invalid, and only
shrinks target values when a finite scale is present—distinct from research
apply_envelope_to_sized_weight fail-closed-to-zero semantics.

Co-authored-by: Cursor <cursoragent@cursor.com>
@Pigbibi
Pigbibi merged commit 015840b into main Sep 18, 2026
1 check passed
@Pigbibi
Pigbibi deleted the fix/qpk-envelope-target-scale-20260918 branch September 18, 2026 00:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant