OPEN-SOURCE SCRIPT
AI MES Asian Session Strategy

How this script works:
The first 30 minutes after 6pm ET (orange shading) builds the opening range. Once locked in, two setups compete — whichever fires first wins and blocks the other for the session.
Breakout fires when price closes outside the range with above-average volume and RSI momentum confirming direction. Stop goes back inside the range, target is 1.5R.
Mean reversion fade fires when price tags a range extreme, RSI is overbought/oversold, and the close reversal bar closes back inside the range. Stop goes just beyond the extreme, target is the range midpoint. Volume threshold is lower here (0.8× average) because fades naturally happen on lighter volume.
Key things to tune in the backtest:
Max Range Size (default 20pts) — filters out nights where a news event blows the range wide open, making fades dangerous
RSI Overbought/Oversold thresholds — tighten these (e.g. 65/35) for fewer but higher quality fade signals
The small faded circles on the chart show when a fade condition was met but couldn't fire (trade limit reached or position already open) — useful for eyeballing missed setups
Run this on the 5-minute timeframe — the Asian session moves slowly enough that 3-minute adds noise without improving entry timing.
The first 30 minutes after 6pm ET (orange shading) builds the opening range. Once locked in, two setups compete — whichever fires first wins and blocks the other for the session.
Breakout fires when price closes outside the range with above-average volume and RSI momentum confirming direction. Stop goes back inside the range, target is 1.5R.
Mean reversion fade fires when price tags a range extreme, RSI is overbought/oversold, and the close reversal bar closes back inside the range. Stop goes just beyond the extreme, target is the range midpoint. Volume threshold is lower here (0.8× average) because fades naturally happen on lighter volume.
Key things to tune in the backtest:
Max Range Size (default 20pts) — filters out nights where a news event blows the range wide open, making fades dangerous
RSI Overbought/Oversold thresholds — tighten these (e.g. 65/35) for fewer but higher quality fade signals
The small faded circles on the chart show when a fade condition was met but couldn't fire (trade limit reached or position already open) — useful for eyeballing missed setups
Run this on the 5-minute timeframe — the Asian session moves slowly enough that 3-minute adds noise without improving entry timing.
Skrip sumber terbuka
Dalam semangat TradingView sebenar, pencipta skrip ini telah menjadikannya sumber terbuka, jadi pedagang boleh menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupuan anda boleh menggunakan secara percuma, ingat bahawa penerbitan semula kod ini tertakluk kepada Peraturan Dalaman.
Penafian
Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.
Skrip sumber terbuka
Dalam semangat TradingView sebenar, pencipta skrip ini telah menjadikannya sumber terbuka, jadi pedagang boleh menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupuan anda boleh menggunakan secara percuma, ingat bahawa penerbitan semula kod ini tertakluk kepada Peraturan Dalaman.
Penafian
Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.