@pineforge/backtest-mcp
Self-contained stdio MCP server: an AI agent writes PineScript v6, and the
bundled pineforge-release image transpiles it to C++ and backtests it against
an OHLCV CSV (your own, or one fetched from Binance's public API) — all in one
container, in-process. Fully local — the image bundles the
pineforge-codegen
transpiler, so Pine → C++ → backtest run with no host Docker daemon. No API
key. Your strategy source and CSVs never leave the machine; only the Binance
tools, and check_tradingview_parity when you pass no bars, make outbound requests
(public endpoints).

Tools
| name | runs on | purpose |
|---|---|---|
transpile_pine |
in-process | Pine v6 → C++ translation unit (transpile-only) |
list_engine_params |
local (no I/O) | Catalog of every overrides + runtime knob accepted by the backtests |
backtest_pine |
in-process | Single backtest of a Pine source against an OHLCV CSV |
backtest_pine_grid |
in-process | Cartesian sweep of inputs × overrides: one transpile, then a compile and a backtest per combination |
check_tradingview_parity |
in-process (Binance public API only without your bars) | Grade your TradingView Strategy Tester export against PineForge's run of the same script, trade by trade |
fetch_binance_ohlcv |
Binance public API | Write a backtest-ready CSV from Binance spot or USDT-perp klines |
binance_symbols |
Binance public API | List / filter Binance symbols (5-min in-process cache) |
list_coverage_topics |
local (no I/O) | Every Pine v6 coverage topic with a one-line status + summary |
check_pine_feature |
local (no I/O) | Look up whether a Pine identifier/namespace is supported in PineForge |
get_coverage_topic |
local (no I/O) | Full detail + supported/partial/via_transpiler/unsupported lists for one topic |
engine_info |
local (no I/O) | Docker image only: mode, baked-in flag and the bundled pineforge-release version (for example 1.0.0) |






