Review / audit trading bot code
check_bot_codeUse it when asked to review, audit, debug or sanity-check trading-bot source (Python ccxt/requests, Pine Script v5/v6, MQL5), together with your own reading: a fixed rule checker (not an AI, same answer every time) that returns each issue with its line number and exact fix lines for mistakes that are easy to miss when reading: order size not rounded to the venue lot step/min size (using sourced venue facts), no stop-loss or max-loss, look-ahead (unfinished candle or future data), ignoring fees, unhandled API errors/rate limits, hard-coded API keys (placeholder values such as 'your_key' or 'example' are skipped), unbounded order loops, testnet/live mix-ups. Known limit: look-ahead is traced inside one function; when the signal is computed in another function, check that by reading. A clean result does not prove a bot is safe or profitable. Code is checked in memory and not stored. 5 credits.
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": {
"code": "<code>"
},
"name": "check_bot_code"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| code | Yes | The full source of ONE bot file as plain text (up to 200 kB): Python (ccxt or REST/requests), Pine Script v5/v6, or MQL5/MQL4. Send the whole file, not a snippet, so order, stop and error-handling logic can be traced. Checked in memory, not stored. | |
| venue | No | Exchange or broker id, lowercase: binance (Binance), bitget (Bitget), bybit (Bybit), coinbase (Coinbase), gate (Gate), ibkr (Interactive Brokers), kraken (Kraken), kucoin (KuCoin), mt5 (MetaTrader 5 (broker patterns)), okx (OKX). Optional: the venue the bot trades on. When given, order sizes and prices in the code are also checked against that venue's verified tick size, lot step and minimum order. Call list_venues (free) to see what each one covers. | |
| filename | No | Optional file name with extension, e.g. bot.py, strategy.pine or expert.mq5. Helps pick the language; otherwise it is detected from the code. |