Documentation panel
Inputs, technical analysis, plots, strategy, math and strings, collections, and utilities, plus a guide to MCP access.
Products Code editor
The editor checks your script against the Pine Script that TrainBard supports, keeps the reference one click away, and turns every input into a field you can sweep.
No credit card. Paste your own supported strategy, or start from a built-in example.
Strategy Parameters · on the Test tab, detected from your inputs
A simplified copy of the editor. Labels, lint messages, examples, and the parameter count follow the app; the full editor adds autocomplete, folding, and a lint gutter.
Diagnostics appear as you type: a marker on the line, the message, a syntax hint where one helps, and a button to the matching docs. The Test tab repeats the count beside Run, so nothing surprises you after you press it.
Error
Unknown function 'ta.smaa'. Did you mean 'ta.sma'?
Error
Unknown named argument 'stop' for 'strategy.entry'; supported parameters: id, direction, qty, limit
Unsupported
Pine function '…' is known but unsupported in TrainBard.
Autocomplete suggests supported functions with their signatures and inserts them with fields you can tab through. Hover any function for its summary, or open the searchable Documentation panel without leaving the editor.
Inputs, technical analysis, plots, strategy, math and strings, collections, and utilities, plus a guide to MCP access.
The same compatibility guide is online at /learn/docs/, with a Markdown copy for coding agents.
Every input.int, input.float, and other supported input appears as a field on the Test tab, ready for exact values or a range.
The Strategy Browser holds ten example strategies, from simple trend following to a stochastic pullback. Each explains its purpose and how to use it, and copies with one click.
AI Help copies a ready-made prompt: a generic starter, one with your current script, or one with your script and its diagnostics. It also links the AI compatibility guide. Review the prompt before you copy it. TrainBard does not send your script anywhere.
Running a backtest does not save your strategy. Save it to your private Library when you want to keep it, and add immutable versions as the idea develops.
Line numbers, folding, wrapping, and find and replace, with the shortcuts you expect.
| Autocomplete | Ctrl Space |
|---|---|
| Next snippet field | Tab |
| Find / replace | Ctrl/⌘ F |
| Next match | F3 or Ctrl/⌘ G |
| Undo / redo | Ctrl/⌘ Z · Ctrl Y or ⇧⌘ Z |
| Switch app tabs | Alt 1–6 |
Open the editor, pick an example, and run it across a range of settings.