Vasil Kirilov
Vasil Kirilov
  • 정보
2 년도
경험
0
제품
0
데모 버전
0
작업
0
거래 신호
0
구독자
Vasil Kirilov
Vasil Kirilov
From one sentence to a tested strategy: AI scripting, bar replay and a grid optimizer in the browser
Describe a strategy in English, get runnable code, replay it bar by bar, then sweep every input the way the Strategy Tester sweeps an input block. Three engineering notes from building it: keeping the AI from inventing functions, resolving same-bar stop/target ties from finer timeframes, and why the optimizer has no combination cap.
1. AI scripting
The demo is easy — chat column, English in, code out. The hard part is that a model asked for a small DSL confidently writes functions that don't exist; it has read a lot of Pine and MQL5 and none of your language.
Two things fixed it. The spec in the system prompt is generated from the engine, not hand-written, and a test asserts both directions — nothing documented the engine lacks, nothing the engine offers left undocumented. It states the closed world explicitly: "THERE ARE NO OTHER INDICATORS. No ta.vwap, no ta.supertrend." And the script is parse-checked on arrival, not on Run, with a FIX IT button that sends the error back. Plus an Undo, because a feature that silently replaces forty lines of your work is one people stop using.
2. The backtest
The engine has no indicator math of its own — ta.ema calls the same function the chart draws with, P&L calls the same routine manual trading uses. That's the MQL5 iMA() guarantee: chart and test can't disagree.
Look-ahead is proven, not promised: truncate 2,000 bars off the end and re-run — no trade that closed before the cut may move. Steal that test.
Unresolvable ties assume the stop filled first — biased against the trader — and the count is reported, because that assumption can manufacture an entire edge. Measured: 43.6% of trades hit an ambiguous candle, and 50.5% of them had actually reached the target first. Win rate 26.0% → 47.5%. Not a rounding difference — a different strategy.
3. The optimizer
Tick the inputs, give min/max/step, every combination runs and ranks. No combination cap, because we measured instead of guessing: 12,000 bars costs ~22 ms per combo, so 500 combos is ~11 seconds. The panel times two real runs of your script on your bars and shows the estimate.
Single thread, so it's time-sliced at 45 ms and yields through MessageChannel (nested setTimeout(0) gets clamped to 4 ms and would cap a light sweep at ~200 combos/sec). One combo is the granularity and slicing can't change that — a worker would fix it, but the engine binds to the chart's own functions on the main thread, and that binding is the no-drift guarantee.
MT5 wins here and it's worth saying: local agents, cloud network, genetic algorithm. We enumerate a full grid on one thread.
Reporting rules: zero-trade rows shown dimmed, never hidden ("this range never fires" is the answer people came for); a combo that throws becomes an error row and the sweep continues; APPLY BEST takes the top of the current sort, not the default score. And the standing note — a wide grid always has a best row, and it may be luck.
Try it out: https://fxbacktest.app/
Vasil Kirilov
Vasil Kirilov
FxBacktest: A Simple Manual Forex Backtesting Tool for Traders

If you are learning forex trading or trying to improve an existing strategy, one of the most important habits is backtesting. Not just looking at charts and guessing, but actually stepping through historical price action, placing trades, tracking risk, and reviewing the results.

That is why I built FxBacktest.

FxBacktest is a browser-based manual forex backtesting tool designed for traders who want to practice entries, exits, risk management, and trade review in a clean environment. You can load historical OHLC price data, move through the market candle by candle, place Buy or Sell trades, drag TP and SL levels, and review your performance after the session.

The goal is simple: make backtesting feel closer to real decision-making.

Instead of instantly seeing the future chart, you move forward bar by bar. This helps you train patience, entry timing, stop-loss placement, and trade management. You can test your strategy the way you would actually trade it.

Main features:

Manual candle-by-candle backtesting
Buy and Sell trade placement
Drag-and-adjust Take Profit and Stop Loss levels
Automatic lot sizing based on risk
Risk by percentage of balance or fixed dollar amount
Spread and commission cost support
Performance statistics after the session
Trade history and report review
Works directly in the browser
FxBacktest is especially useful for traders who want to practice discretionary strategies, price action, supply and demand, liquidity sweeps, session-based setups, or any manual trading system that cannot be fully tested by an EA.

The risk system is built around practical trading logic. You choose your risk, set your stop loss, and the tool calculates lot size from the SL distance. This makes it easier to train consistent risk management instead of guessing position size every trade.

FxBacktest is not meant to replace MetaTrader, EAs, or professional quantitative testing tools. It is built for manual practice and strategy review. If you want to improve your chart reading, build confidence in your setup, and collect backtesting results in a structured way, this tool is made for that.

Website: https://fxbacktest.app

I would appreciate feedback from the MQL5 community, especially from traders who manually backtest forex strategies or train new systems before going live.
Vasil Kirilov
Range reversal EA for MT5 작업에 대한 피드백을 개발자에 남김
Vasil Kirilov
Modify existing Expert Advisor 작업에 대한 피드백을 개발자에 남김
Vasil Kirilov
Modify existing EA 작업에 대한 피드백을 개발자에 남김
Vasil Kirilov
Opening range breakout EA 작업에 대한 피드백을 개발자에 남김
Vasil Kirilov
Convert a Trading view Trendline indicator to MQL5 expert advisor 작업에 대한 피드백을 개발자에 남김
Vasil Kirilov
Convert pine script indicator to MQ5 expert advisor 작업에 대한 피드백을 개발자에 남김
Vasil Kirilov
MQL5.커뮤니티에 등록됨