← Back to registry

TOOL · run_backtest

Execute a backtest for a specific trading bot using historical market data. Returns performance metrics including PnL, Sharpe ratio, and trade history.

Canonical Definition

{
  "description": "Execute a backtest for a specific trading bot using historical market data. Returns performance metrics including PnL, Sharpe ratio, and trade history.",
  "name": "run_backtest",
  "parameters": {
    "properties": {
      "bot_id": {
        "description": "The ID of the bot to backtest.",
        "type": "integer"
      },
      "initial_capital": {
        "description": "Starting capital for the simulation (default: 10000).",
        "type": "number"
      },
      "interval": {
        "description": "Candlestick interval (e.g., '1m', '5m', '1h', '1d').",
        "type": "string"
      },
      "range": {
        "description": "Time range for the backtest (e.g., '30d', '90d', '1y').",
        "type": "string"
      },
      "symbol": {
        "description": "The trading symbol (e.g., 'BTCUSD', 'AAPL', 'EURUSD').",
        "type": "string"
      }
    },
    "required": [
      "bot_id",
      "symbol",
      "interval",
      "range"
    ],
    "type": "object"
  }
}