Gold Consistency AI
- エキスパート
- Daniele Pio Candido
- バージョン: 1.0
- アクティベーション: 5
AI-Powered XAUUSD Trading Expert Advisor
Gold Consistency AI is a machine-learning based Expert Advisor designed specifically for XAUUSD trading.
The system combines multi-timeframe market structure, liquidity-based reversal logic, volatility analysis, and an embedded AI model trained outside MetaTrader and exported to ONNX for native MT5 execution.
The main objective of Gold Consistency AI is not to overtrade, scalp randomly, or follow every market movement.
Its goal is to identify higher-quality trading conditions where price structure, volatility, liquidity behavior, and machine learning probability align.
Gold Consistency AI is a hybrid system based on:
-
liquidity sweep reversal logic
-
trend continuation after pullback
-
higher-timeframe regime filtering
-
H1 closed-candle decision making
-
M15 and M5 microstructure confirmation
-
dynamic stop-loss and trailing protection
It is not a pure trend-following EA and it is not a simple reversal EA.
The core idea is:
detect local liquidity manipulation or pullback exhaustion, confirm the reaction on lower timeframes, then allow the AI model to decide whether the setup has enough statistical quality to be traded.
In practical terms, the EA looks for situations where price may sweep liquidity, reject a level, close back into structure, and continue in the most probable direction according to the trained model.
Trading LogicThe EA uses H1 as the main decision timeframe.
The signal is generated only after a fully closed H1 candle.
This is important because the EA does not use unfinished candles for the main decision.
The entry logic follows this principle:
-
H1 candle closes.
-
The EA evaluates the latest closed H1 structure.
-
M15 and M5 closed candles are used as microstructure confirmation.
-
H4 and D1 are used for broader regime context.
-
The embedded AI model evaluates the probability of the setup.
-
If the setup passes all filters, the EA enters at the next H1 open.
This structure is designed to reduce lookahead bias and make the MT5 execution logic closer to the original Python research pipeline.
Multi-Timeframe StructureGold Consistency AI uses several timeframes, each with a different role:
| Timeframe | Purpose |
|---|---|
| D1 | Macro regime and long-term structure |
| H4 | Higher-timeframe bias and regime |
| H1 | Main signal and trade decision |
| M15 | Microstructure confirmation |
| M5 | Short-term reaction and confirmation |
The EA does not randomly combine indicators.
Each timeframe has a specific role in the trading decision.
The AI model is based on ExtraTrees machine learning models trained in Python using scikit-learn.
The training pipeline uses:
-
ExtraTreesClassifier for probability filtering
-
ExtraTreesRegressor for expected R evaluation during research
-
SimpleImputer with median values
-
separate BUY and SELL model logic
-
ONNX export for native MetaTrader 5 inference
The final marketplace version embeds the ONNX models directly inside the EA, so the compiled EX5 contains the AI model internally.
Training MethodologyThe model was trained using a leakage-safe pipeline.
The training process was designed around strict rules:
-
H1 signal uses closed H1 candles only
-
M15 and M5 features use the last closed candles available at or before the H1 close
-
H4 and D1 features use the last closed higher-timeframe candles available at or before the H1 close
-
entries are simulated at the next H1 open
-
no future rolling calculations are used
-
no repainting logic is used
-
all features are designed to be portable to MT5
This is important because many strategies look good in historical testing but fail in live execution due to lookahead bias or non-replicable indicator logic.
Gold Consistency AI was designed from the beginning to keep the Python research logic and MT5 execution logic aligned.
Data Splits Used During ResearchThe research pipeline used time-based splits instead of random shuffling.
Example split structure:
-
Training period: up to April 2025
-
Calibration period: May 2025 to June 2025
-
Test period: July 2025 to December 2025
This approach is more realistic than randomly mixing past and future data because trading models must be validated forward in time.
Labeling LogicThe training labels were based on realistic H1 trade outcomes.
Each setup was labeled using:
-
entry at next H1 open
-
ATR-based take profit
-
ATR-based stop loss
-
maximum holding period
-
simulated execution cost buffer
Core labeling parameters used in the research pipeline:
-
ATR length: 14
-
TP: 1.20 ATR
-
SL: 0.80 ATR
-
maximum hold: 12 H1 candles
-
entry delay: 1 candle
-
entry cost buffer: 0.10 price units
A trade was considered good when its realized R outcome was positive under these rules.
Feature EngineeringThe model uses portable features that can be reproduced inside MT5.
The feature set includes:
Volatility Features
-
ATR
-
normalized ATR
-
candle range divided by ATR
-
candle body divided by ATR
-
wick size divided by ATR
Candle Structure
-
body size
-
upper wick
-
lower wick
-
close position inside the candle
-
bullish displacement
-
bearish displacement
Momentum Features
-
RSI 14
-
EMA distance
-
short-term returns
-
medium-term returns
-
price acceleration
Liquidity Features
-
sweep of previous highs
-
sweep of previous lows
-
close back below previous high
-
close back above previous low
Market Structure Features
-
rolling highs
-
rolling lows
-
position inside recent range
-
distance from recent highs
-
distance from recent lows
Regime Features
-
H4 bullish or bearish regime
-
D1 bullish or bearish regime
-
H4/D1 RSI alignment
-
H4/D1 EMA positioning
The strategy creates BUY and SELL candidate setups separately.
A BUY setup can occur when price shows conditions such as:
-
sweep of previous lows
-
close back above liquidity
-
bullish recovery
-
lower wick rejection
-
supportive H4/D1 regime
-
M15/M5 confirmation
A SELL setup can occur when price shows conditions such as:
-
sweep of previous highs
-
close back below liquidity
-
bearish rejection
-
upper wick rejection
-
supportive H4/D1 regime
-
M15/M5 confirmation
After a setup exists, the AI model decides whether the setup quality is strong enough to trade.
What the AI Actually DoesThe AI model does not simply predict “BUY” or “SELL” from a chart.
Instead, it evaluates whether a valid structural setup has enough probability and quality.
The model acts as a filter.
This means the EA first looks for a market structure condition, then the AI decides whether that condition is worth trading.
This helps reduce random entries and avoids trading every possible signal.
Reversal or Trend Following?Gold Consistency AI is best described as a liquidity-based reversal and continuation hybrid.
It is not pure trend following.
It is also not pure counter-trend reversal.
The EA often looks for a local reversal after a liquidity sweep or pullback, but it also uses higher-timeframe structure to avoid low-quality counter-trend trades.
In simple terms:
The EA searches for local reversal opportunities inside a broader structural context.
This allows the system to enter after manipulation or pullback exhaustion while still respecting the larger market regime.
Risk ManagementGold Consistency AI includes several risk-control mechanisms:
-
fixed lot or percentage risk
-
maximum trades per day
-
cooldown between trades
-
one-position-at-a-time option
-
spread/ATR filter
-
execution hour filter
-
daily circuit breaker
-
equity peak protection
-
maximum holding time
The EA is designed to avoid excessive trading frequency and to reduce exposure during poor conditions.
Protection ModesThe EA includes simplified protection modes:
NORMAL
A smoother protection profile designed to reduce excessive stop modifications.
PROP
A more protective mode designed for stricter risk control and drawdown management.
CUSTOM
Allows the user to adjust the trailing/protection strength with a single parameter.
This makes the EA easier to configure without exposing too many technical trailing inputs.
Dynamic Stop ManagementGold Consistency AI includes dynamic trade protection logic.
The stop management system may react to:
-
ATR volatility
-
floating profit
-
price retracement
-
M5/M15 reversal behavior
-
structural protection levels
-
trade progress in R
The goal is to reduce the impact of fast reversals and protect accumulated floating profit when the market starts moving against the position.
What Gold Consistency AI Does Not UseGold Consistency AI does not use:
-
martingale
-
grid averaging
-
hedge recovery systems
-
dangerous lot multiplication
-
unlimited averaging
-
fake AI logic
The strategy is based on structured entries, machine learning filtering, and controlled risk.
Recommended MarketGold Consistency AI is designed for:
-
XAUUSD
-
low-spread ECN-style brokers
-
London and New York active sessions
-
accounts where stable risk management is important
-
traders looking for selective AI-filtered entries
Broker conditions matter.
Different brokers may show different results because of spreads, tick data, server time, commission, and historical data quality.
Gold Consistency AI is a trading tool, not a guaranteed profit system.
Past performance, backtests, or optimization results do not guarantee future results.
Market conditions can change, and machine learning models can underperform during unseen regimes.
Before using the EA on a live account, users should:
-
test it in the Strategy Tester
-
run it on demo first
-
use conservative risk
-
verify broker conditions
-
understand the input settings
Trading XAUUSD involves high risk and may not be suitable for all traders.
Suggested Short Product SummaryGold Consistency AI is an advanced XAUUSD Expert Advisor powered by an embedded ONNX machine learning model.
It combines H1 closed-candle decision logic, M15/M5 microstructure, H4/D1 regime analysis, liquidity sweep detection, ATR-based risk logic, and dynamic trade protection.
The strategy is designed to identify high-quality gold setups after liquidity manipulation, pullback exhaustion, or structural rejection, while using AI probability filtering to avoid low-quality trades.
No martingale.
No grid.
No dangerous recovery logic.
Just structured AI-filtered trading with risk control.
