Position size from risk
position_sizeCalculate the trade size that risks exactly a set percentage of an account when the stop is hit; returns units, notional, dollar risk, implied leverage, and side.
Instructions
How big a position is so that hitting the stop loses exactly risk_pct of the account. Returns size in units, notional, the dollar risk, the leverage it implies and the side (stop below entry = long). Fees and slippage not included. Offline.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"account": "<account>",
"risk_pct": "<risk_pct>",
"entry": "<entry>",
"stop": "<stop>"
},
"name": "position_size"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| stop | Yes | ||
| entry | Yes | ||
| account | Yes | Account size, USD. | |
| risk_pct | Yes | Risk per trade, % of account. |