# Sell/Reentry Algorithm Contract ## Decision Context - PortfolioId, AccountId, LotId, CycleId - AssetPolicyId, IPSVersion - AsOf, PublishedAtCutoff, TradableSession - EvidenceId, DatasetId, ModelVersion, ConfigVersion, CodeSha - CurrentLotQuantity, CurrentPortfolioWeight, StrategicCoreFloorWeight - Peak/Floor/Breach/Cooldown - Hard impairment evidence grade and approval - Risk reduction requirement, concentration excess, liquidity capacity - Expected utility component distribution and confidence lower bound ## Decision Output - Action: HOLD/PARTIAL_SELL/FULL_SELL - PolicyId/Priority/ReasonCode - SellRatioOfLot - ProposedQuantity - TargetPortfolioWeightAfter - ReentryEligibility - CounterEvidence - ValidUntil/NextReviewSession - DecisionHash ## Invariants 1. Hard impairment cannot be overridden. 2. Proposed quantity cannot exceed lot quantity. 3. Strategic core floor cannot be breached unless an approved higher-priority policy allows it. 4. Same input and Version Set produce the same decision hash. 5. A decision without immutable Evidence cannot be stored. 6. A reentry stage executes at most once. 7. Reentry creates a new CycleId. 8. Hard impairment cannot create an automatic ReentryWatch.