Core Tools
Position sizing, risk validation, performance evaluation, and pricing.
The 4 core tools are the foundation of System R. They cover position sizing, risk validation, and performance evaluation.
calculate_position_size
Cost: $0.003 | Calculate optimal position size using the G-formula (geometric growth optimization).
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
equity | string | Yes | Account equity in USD (e.g. "100000"). |
entry_price | string | Yes | Planned entry price (e.g. "185.50"). |
stop_price | string | Yes | Stop loss price (e.g. "180.00"). |
direction | string | Yes | "long" or "short". |
risk_percent | string | No | Risk as decimal (e.g. "0.02" for 2%). Defaults to 2%. |
Example
Response
| Field | Type | Description |
|---|---|---|
shares | int | Number of shares to trade. |
risk_amount | string | Dollar amount at risk (equity * risk_percent). |
risk_percent | string | Actual risk fraction applied. |
notional | string | Total position value (shares * entry_price). |
one_r_dollars | string | Dollar value of one R-unit (risk per share * shares). |
direction | string | Trade direction. |
check_trade_risk
Cost: $0.004 | Validate a proposed trade against Iron Fist risk rules.
Checks: single position risk, portfolio-level risk, daily loss limits, and position count constraints.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
symbol | string | Yes | Instrument symbol (e.g. "AAPL"). |
direction | string | Yes | "long" or "short". |
entry_price | string | Yes | Entry price. |
stop_price | string | Yes | Stop loss price. |
quantity | string | Yes | Number of shares/contracts. |
equity | string | Yes | Account equity in USD. |
daily_pnl | string | No | Daily P&L so far. Defaults to "0". |
Example
Response
| Field | Type | Description |
|---|---|---|
approved | bool | true if the trade passes all risk rules. |
score | int | Risk score from 0 (worst) to 100 (best). |
errors | string[] | Blocking issues. Non-empty means trade rejected. |
warnings | string[] | Non-blocking concerns. Trade approved but review recommended. |
risk_amount | string | Dollar risk for this trade. |
risk_percent | string | Risk as a fraction of equity. |
evaluate_performance
Cost: $0.10 (basic), $0.50 (full), $1.00 (comprehensive) | Evaluate trading system performance using G-metric analysis.
Three evaluation tiers provide increasing depth of analysis.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
r_multiples | string[] | Yes | R-multiples from trade history (minimum 2). |
tier | string | No | "basic", "full", or "comprehensive". Defaults to "basic". |
window_size | int | No | Rolling window size. Defaults to 10. |
Basic tier ($0.10)
Full tier ($0.50)
Adds System R Score (0 to 100 composite grade) and rolling G trend analysis.
Comprehensive tier ($1.00)
Adds score component breakdown and next-trade G impact analysis.
get_pricing
Cost: Free | Get current pricing for all operations. No authentication required.
Example
Response
| Python SDK | pip install systemr |
| MCP Server | agents.systemr.ai/mcp/sse |
| OpenAPI Spec | agents.systemr.ai/openapi.json |
| Machine Docs | agents.systemr.ai/llms.txt |
| GitHub | System-R-AI |
| X | @Systemrai |
| YouTube | @systemr_ai |
| hello@systemr.ai | |
| Phone | 628 333 6693 |
| Address | 7901 4TH ST N, STE 28529, ST PETERSBURG, FL 33702 |
| Terms | Terms of Service |
| Privacy | Privacy Policy |
| Security | Security Policy |