IB Stop-Loss Manager Analyzes PMCC (diagonal call spread), naked LEAPS, and stock positions in the IB portfolio and manages conditional stop-loss orders. Default mode is dry-run — no orders are placed unless is in the request. Prerequisites TWS or IB Gateway running locally with API enabled: - Live trading: port 7496 - Paper trading: port 7497 Instructions Step 1: Run the script Dry-run (default — no orders placed): Execute (cancel orphan orders + place SL conditional orders): Execute forced (basis = current mid price, can lower existing stops): Step 2: Format the report Format JSON output as…