Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/api/enhanced_strategy_recommender.py
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,10 @@ def _create_covered_call(self, symbol: str, current_price: float,
},
'current_price': current_price,
'days_to_expiration': self._days_to_expiration(expiration),
'profit_risk_ratio': round(max_profit / 1000, 2) # Simplified ratio for covered calls
# Reward-to-risk ratio, consistent with the spread strategies above.
# (Previously max_profit / 1000, a fabricated constant that ranked by
# raw dollar profit rather than risk-adjusted return.)
'profit_risk_ratio': round(max_profit / max_loss, 2) if max_loss > 0 else 0
}

# Helper methods
Expand Down