workflow.run_max_leverage
Calculate the maximum safe leverage based on account size, max acceptable drawdown, and asset daily volatility. Use when user asks "what's the max leverage I should use on BTC?" or "how much leverage is safe given 3% daily volatility?". Returns: maxLeverage, marginAtRisk.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mmr | No | Maintenance margin rate, default 0.005 (0.5%) | |
| accountSize | Yes | Total account size in USDT | |
| volatilityPct | Yes | Expected daily price volatility as percentage, e.g. 3 for 3% | |
| maxDrawdownPct | Yes | Maximum acceptable drawdown as percentage, e.g. 10 for 10% |