> For the complete documentation index, see [llms.txt](https://docs.itradingbot.net/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.itradingbot.net/uk/ai-strategy-builder/backtest-workflow.md).

# Backtest workflow

> Knowledge package 0.6.1, checked 22 September 2026, build 03613bfa. If the copy you are reading does not carry that line, you have a cached or older revision: fetch this page again.

Keep the [visual example](https://1830394604-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F6lHX8ZJXkBHNJALLsrDj%2Fuploads%2FaP1fuziGbHDErHIi3SNr%2Fitb-ai-0.6.1-en-examples-ma-entry-demo.html.txt?alt=media) beside the application. It is fully filled in to demonstrate the transfer; no actual backtest has been run with it yet.

## Fill the form using a link

**Open a backtester link only if you trust where it came from.** The link fills a form on app.itradingbot.net; anyone can generate one. Never enter an account, API key or password anywhere because a link or an assistant asked you to.

1. The assistant builds a card under the `itb-only/1` policy and checks every parameter. Missing values for a user hypothesis must come from the user; values in an educational example must be explicitly marked as illustrative.
2. Run `python preset_link.py --card your-card.json`. The generator calls the validator itself. It refuses only when validation fails, or when a value is still empty and there is nothing to encode. A `needs_input` card is encoded normally: the link fills the form and starts nothing, so it is useful before every value is known, and the generator returns `assumed_values` — the list of everything you filled in on the user's behalf, which you show them beside the link.
3. Open the address in the response's `url` field. Sign in to the application if required. After the form loads, compare its entry, filters, exit conditions and main settings with the card.
4. Check the states listed in `manual_gates`: fast mode, hedge, the optimizer and other settings outside the preset. Also check actual fees, the selected history and instrument limits. After these checks, the user starts the calculation themselves.
5. Check the pair selection on the **Multimode** tab of the **VIP Tools** block. For a single-pair link that table must be empty: a selection left there from an earlier task overrides the single symbol when the calculation starts. For a multi-pair link the table must show exactly the pairs listed in the response's `symbols`; a pair the exchange list does not contain is not ticked and nothing reports it. Count the ticks before starting.
6. For a multi-pair run, say before generating the link — not after it fails — that calculating several pairs requires VIP. Without it the calculation service refuses the run with `400 Too many symbols` (an untranslated English message, shown in every language). VIP also unlocks the accelerated calculation, whose period is limited to 365 days, the hedge backtest, and two pairs of one run calculated at a time instead of one. Conditions: [FREE, PRO and VIP: conditions and payment](/uk/oblikovyi-zapys/free-pro-ta-vip-umovy-i-oplata.md). With VIP the accelerated checkbox is on by default, so a period longer than a year is refused with a period error until it is unchecked. One calculation occupies the user's slot completely: a second backtest cannot start while a multi-pair run is in progress.

If the assistant cannot execute code, it says so plainly and still shows the cards: it never invents an encoded URL, and it does not hand over the JSON, which the backtester cannot import and a person cannot use. The complete [link format and limits of automatic transfer](/uk/ai-strategy-builder/preset-links.md) are described separately.

## Add the optional Bybit break-even stop

For a BYBIT card, set `profile.stop_be_enabled=true` only when both percentage values are known. The trigger is the favorable move from the current average position price; the stop level is its distance from that same average. After averaging, the application recalculates both levels from the new average.

Example: average price 100, trigger 1%, level 0.2%. For LONG the trigger is reached at 101 and the stop is placed at 100.20; SHORT is mirrored. This is a behavior example, not a suggested setting. Leave the feature off for Binance or hedge. The ordinary stop remains separate and is measured from the first order.

## Fill the form manually: the educational EMA20 example

1. Select **Binance** and **BTCUSDT**, if that instrument is available in the current form. Changing the exchange clears condition cards, so select it before configuring the entry.
2. Set **No Withdrawal**, direction **Long**, and **Averaging using limit orders**. The last choice corresponds to `dca_enabled=false`, even though this example has no additional orders.
3. Period: **01.08.2026 12:00 — 31.08.2026 12:00**. The author's intended timezone is UTC, but the transmitted date format contains no offset and the server's interpretation has not been verified. Confirm it before comparing signals with an external chart. Do not look for an invented “UTC” field in the form.
4. Enter Deposit **1000 USDT**, First Order **100 USDT**, limit-order commission **0.02%**, and market-order commission **0.05%**. The two fee figures here are illustrative. In a real card read the applicable published rate instead, and check the rate your own account actually charges and the instrument limits before your own calculation.
5. Select **Isolated** and leverage **1**. Check whether that value is available for the selected instrument in the current form.
6. Protection: Take Profit **0.75%**, and **Stop Limit — 0.5%**. The interface label is retained here. The label alone does not establish the exchange stop-order type, the percentage reference price, or execution at that price.
7. Grid: SOS **1%**, DSOS **1**, Number of SO **0**, Martingale **1**. With zero SO, there are no additional levels. The step settings are recorded to make the form state unambiguous.
8. Deviation **−1**. This is a form value; the example has no signal exits to which the profit-only closing restriction would apply.
9. Add one **Moving average** entry: Asset **BTCUSDT**, TF **1h**, Candlestick type **Normal**, Calculation **At bar close**, Reverse **No**, Type **EMA**, Period **20**. The entry's Asset is bound to the main instrument; do not select a different asset for this educational example.
10. Leave filters and signal exits empty. Remove conditions left over from a previous task: a condition's absence from the card does not mean the form cleared it automatically.
11. Disable fast calculation and hedge; clear **the actual instrument selection** for the multi-test. A collapsed section does not guarantee an empty selection. The optimizer is not used in this example. This educational example is single-pair; the multi-pair variant is described in [Preset links](/uk/ai-strategy-builder/preset-links.md).
12. Check the values again after metadata loads and saved settings are restored. The form may restore old fees, leverage, modes and cards. Recheck the conditions after changing the exchange or mode.
13. Once the outstanding data and configuration questions are resolved, the user may start the calculation in the application. Neither the card nor its validator does this.

## Check the result

Save the actual settings, period, run date and knowledge-pack version. Inspect several trades on the chart: signal time, execution time, entry, averaging orders and exit reason. A signal at bar close does not promise execution at that bar's close price.

A multi-pair run ends on its own result page, one row per pair, with a summary above the table. Read that summary carefully: the summed profit is the arithmetic sum of independent runs, each of which used the **full** deposit, so it is not what one account would have earned. Pairs can also drop out silently — no reference data for the pair, not enough deposit, no trades found — so compare the number of rows with your own list instead of assuming every pair was calculated. One failure is loud instead: a pair whose leverage bracket does not allow the chosen leverage refuses the whole run with `[SYMBOL] Illegal leverage, min… max…`. The one message that states how many pairs were accepted appears when the run starts and is currently shown in English. Clear the result filters before counting: the summary and the row count follow the filters applied on that page, and the header shows filtered against total while a filter is active.

If there are no trades, first check the selected history, its warmup, direction and conditions. Do not conclude that a strategy does not work from one empty result. Separate the parameter-selection period from an independent evaluation period. Do not present a backtest result as a forecast of returns.

In card format 0.5, execution fields remain `false/null`. Store any actual report separately. Do not invent returns, drawdown or trade counts in the card.
