Skip to content

fix: rebase target qty on unfilled position top-ups#1

Open
Magic-Jia wants to merge 422 commits into
masterfrom
feat/s-tier-microstructure-integration-20260522160833
Open

fix: rebase target qty on unfilled position top-ups#1
Magic-Jia wants to merge 422 commits into
masterfrom
feat/s-tier-microstructure-integration-20260522160833

Conversation

@Magic-Jia
Copy link
Copy Markdown
Owner

Summary

  • Rebase target quantity calculations on the remaining unfilled/open position quantity during top-ups.
  • Prevent target-management sizing drift when repeated paper fills update an existing symbol position.
  • Preserve paper execution / position lifecycle consistency for S-tier microstructure integration evidence.

Verification

  • python scripts/verify.py --changed trading_system/app/portfolio/positions.py --changed trading_system/tests/test_target_management_state.py

    • 1089 passed in 2.86s
    • git diff --check HEAD clean
  • python scripts/verify.py --suite full

    • 6733 passed in 185.90s
    • git diff --check HEAD clean

Paper evidence

4h proof bundle:

  • /tmp/s-tier-four-hour-performance-proof-retry-I8jwk1/output/summary.json
  • /tmp/s-tier-four-hour-performance-proof-retry-I8jwk1/runtime/paper/microstructure-four-hour-performance-proof-retry/execution_log.jsonl
  • /tmp/s-tier-four-hour-performance-proof-retry-I8jwk1/runtime/paper/microstructure-four-hour-performance-proof-retry/paper_ledger.jsonl

Observed results:

  • 240 rounds
  • 360 candidates / allocations
  • 304 accepted allocations
  • 56 rejected allocations
  • 40 paper fills
  • 40 unique paper ledger fills
  • 6 final open positions
  • false-close count: 0
  • execution sample health: available
  • optimization health: ok
  • promotion decision: observe

Promotion status

This is not promoted yet. The current decision is observe, because there are no active recommendations to validate and the latest funnel is risk-off / blocked. This patch closes the top-up target quantity correctness gap and makes the paper evidence loop observable, but longer paper/live-sim evidence is still required before promotion.

Magic-Jia added 30 commits May 15, 2026 22:15
Magic-Jia added 30 commits May 21, 2026 07:34
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