Skip to main content

Check a Pine Script written by an AI

A Pine script from ChatGPT, Claude or another AI can compile and still prove nothing. Paste it here: the Lab engine, running in your browser, replays it on real BTCUSDT candles and returns a verdict on a sealed period, or refuses with the exact reason. Free, no account, and your script is not sent.

  1. Paste the Pine v5 strategy your AI wrote.
  2. Choose the data: BTCUSDT, in 1 d (full history), 4 h (3 years) or 1 h (1 year).
  3. Read what holds, what is missing and the next step. If the judge cannot read the script, it shows the line at fault and the simplest fix.
  4. Copy the prepared request and paste it into your AI, with the verdict or the refusal, so it can correct the script.

Use my candles (CSV file)

Your candles (CSV file: time, open, high, low, close, volume), from the source of your choice, whose data you have the right to use for your own backtest. The file is read in your browser and never sent. Without a file, the judge uses BTCUSDT.

You are responsible for your rights to the data you load. Example of a source whose terms allow personal backtesting: Binance Vision (data.binance.vision).

or drop it here

To write or edit a Pine, you need TradingView. New accounts only: free account, and $15 off a first subscription through this link. TradingView →

What this check adds to your AI

Measured on 2 November 2026: of 10 ordinary scripts written by Claude, on 1D, the judge accepted 6 and refused 4 (long/short reversal, ATR stop, Bollinger, SuperTrend). That is one small test with one AI, not a score for AIs in general.

Real example: what holds and what is missing in an EMA 9/21 crossover

Here is what the judge answers to this page’s example script, on BTCUSDT daily candles, with 0.10% fees per fill. Computed on 4 November 2026 by the same engine that runs in your browser. Data: Binance, up to 2026-10-16.

No evidence of an edge yet: 3 of 4 steps passed. (technical verdict code: inconclusive)

What holds: 16 trades on the period it never saw; +2.9% while holding BTC made −23.2% (it stayed out of part of the fall); a training result that stays solid once trials are counted (deflated Sharpe 99.98%).

What is missing: out of 100 random markets, 35 do as well; it would take 5 at most. With 16 trades, its lead cannot be told apart from chance.

Next step: the same rule in 4h or 1h (more independent trades), or on another market with your own candles; or keep it as it is and judge it again when new candles are in.

What this verdict spared you: taking a lead of 26.1 points over holding for an edge, when 35 random markets out of 100 do as well. What fees take: about 3.3 points out of 6.2.

Steps passed: activity ✓, gain vs holding ✓, trials counted ✓, chance ✗, other market —, forward period — (not measured by the online judge).

1. The history cut in two

BTCUSDT daily closes, sealed period shaded, sealed trades in green or redtraining (80%)sealed period (20%)

The judge replays the script on the first 80% of the history, then assesses it on the last 20%, from 2024-12-17 to 2026-10-16, which it never saw. On this sealed period it made 16 trades, green when they win and red when they lose.

2. What it earns per year, before and after the cut

Yearly return: training, sealed period, holdingTraining+67.2%Sealed period+1.6%Holding BTC−13.4%

On training, +67.2% per year. On the period it never saw, +1.6% per year. This is the typical gap of overfitting: a simple rule looks brilliant on the past used to pick it, much less afterwards.

3. The sealed period, day after day

Capital of the script and of holding BTC on the sealed periodHolding BTCThe script

The script stays almost flat while BTC falls: it avoids part of the drop, which explains its lead over holding.

4. What fees take

Return before and after fees on the sealed periodBefore fees+6.2%After fees+2.9%

Before fees, about +6.2%; after fees, +2.9%. Estimate from the 16 sealed trades.

5. Against chance

35 random markets out of 100 do as well as the scriptthreshold to rule out chance: 5 out of 100

The judge replayed the market at random 1,000 times, keeping its shape. 348 times out of 1,000, a strategy with no edge does as well as this script against holding. To rule out chance, it would take 5 times out of 100 at most.

The four measured steps (“holds” takes all four)

Definitions of the terms
Sealed period
The last 20% of the history, kept apart: the script never saw them.
Overfitting
A strategy tuned so closely to the past that it learned its noise.
Holding
Buying at the start and waiting. Any strategy has to do better.
Test against chance (SPA)
The market is replayed at random, keeping its shape; we count how often a strategy with no edge does as well. Hansen’s SPA test, 2005.
Deflated Sharpe
The Sharpe ratio corrected for the number of scripts tried. Bailey and López de Prado, 2014.

Research on past data, not advice. Data: Binance, CC BY-NC-SA 4.0 licence.

Which test gives a verdict?

ToolWhere it runsCostWhat it answersVariant search
Online judge (this page)Your browserFreeA verdict on a sealed periodNo, the script as it is
Quick CheckThe siteFreePine compatibility only, no verdictNo
Strategy Arena LabYour PC, Windows or LinuxFreeA verdict on a sealed periodYes, every variant is counted
Survival AuditThe server9.90 EUR, onceBounded stress tests in a private reportNo, the exact code is fixed before payment

Limits

FAQ

Does it tell me which AI writes the best strategies?

No. It judges one script as it is. A verdict says nothing about the model that wrote it, and nothing about the future.

Is my script sent to Strategy Arena or to an AI?

No. The calculation runs in your browser. The script leaves it only if you choose to make it public on a card, or paste the prepared request into your AI yourself.

My script was refused. Is it bad?

Not necessarily. A refusal means the judge cannot replay it exactly. It says nothing about its quality. The page shows the reason and prepares a request for your AI.

Is the check free?

Yes. The page, the calculation in your browser and the verdict card are free, with no account.

Can my AI drive the tests itself?

Yes, with the desktop Lab for Windows and Linux, which an AI can drive over MCP. It searches variants and counts every trial.

Go further: testing a Pine script out of sample, tools compared · what the judge answered to old rules · check a Pine written by an AI

Data: Binance, CC BY-NC-SA 4.0 licence. Research on past data, not advice. manifest