Add martingale mode for risk-based percent sizing.
Enable in settings (default off): after N consecutive loss days, double the effective risk_loss_pct up to a configurable max; blocked when base pct > 3%. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -284,6 +284,9 @@ async def fleet_status(_tok: Annotated[str, Depends(require_fleet_token)]) -> di
|
||||
"risk_perp_unit": _pick("risk_perp_unit", 1.0),
|
||||
"risk_option_unit": _pick("risk_option_unit", 2.0),
|
||||
"risk_exit_unit": _pick("risk_exit_unit", 15.0),
|
||||
"martingale_enabled": st.get("martingale_enabled"),
|
||||
"martingale_doubles": st.get("martingale_doubles"),
|
||||
"risk_effective_loss_pct": st.get("risk_effective_loss_pct"),
|
||||
},
|
||||
"position": {
|
||||
"status": pos.get("status") or ("open" if pos.get("has_position") else "flat"),
|
||||
|
||||
Reference in New Issue
Block a user