Version: 11.2 Author: Giles Platform: MetaTrader 5 (MQL5) Type: Automated Trading EA based on Smart Money Concepts (SMC) / ICT Theory
Table of Contents
Chapter 1: Product Overview & Architecture
1.1 Product Introduction
GilesExpertSMC is a feature-rich MetaTrader 5 automated trading EA (Expert Advisor) that deeply integrates Smart Money Concepts (SMC), ICT (Inner Circle Trader) theory, and classic technical analysis indicators, providing traders with a highly configurable automated trading framework.
The EA features 20 entry signals, 9 trailing stop methods, 6 money management modes, and supports multi-timeframe filtering, news filtering, Martingale strategy, partial take-profit/stop-loss, and more. By flexibly combining these modules, users can build trading strategies ranging from simple to complex — all without writing a single line of code.
1.2 Core Design Philosophy
The core logic of GilesExpertSMC can be summarized in one sentence:
Select 1 entry signal + enable 0 to N filter signals. The EA will only place an order when the entry signal and ALL enabled filter signals simultaneously confirm the same direction.
Specifically:
-
Entry Signal: Only one can be selected as the primary trigger condition. When it generates a bullish (buy) or bearish (sell) direction, and no filter signals are added, the EA will immediately place an order.
-
Filter Signals: Any number of filter signals can be enabled across multiple timeframes. When multiple filters are added, all filter signals must simultaneously produce a signal in the same direction as the entry signal before the EA executes a trade. If any filter signal is not satisfied, no order is placed.
-
Signal Expiration: Pay special attention to the Last Signal Expiration setting for each filter signal. Many signals only appear on specific bars; setting an expiration extends the signal's duration.
1.3 Overall Architecture
The EA execution flow is as follows:
┌─────────────────────────────────────────────────────────────┐ │ OnTick() Triggered │ ├─────────────────────────────────────────────────────────────┤ │ ① CAP Check → ② Refresh Market Data → ③ Processing() │ ├─────────────────────────────────────────────────────────────┤ │ Processing() Main Loop │ │ │ │ ┌─ Iterate Existing Positions ────────────────────────┐ │ │ │ • CheckClose() Check close conditions │ │ │ │ • CheckTrailingStop() Main trailing stop check │ │ │ │ • CheckTrailingStopForAddPos() Add-pos trailing │ │ │ └──────────────────────────────────────────────────────┘ │ │ │ │ ┌─ Iterate Pending Orders ────────────────────────────┐ │ │ │ • Check order deletion/expiration conditions │ │ │ └──────────────────────────────────────────────────────┘ │ │ │ │ ┌─ Open Position Logic ───────────────────────────────┐ │ │ │ Daily P&L limit → News filter → Hour/Day/Month │ │ │ │ → Spread check → Max orders → Direction allowed │ │ │ │ → Min position distance → Martin conditions │ │ │ │ → Entry signal direction + All filters confirmed │ │ │ │ → Money management lot calc → Execute open │ │ │ └──────────────────────────────────────────────────────┘ │ └─────────────────────────────────────────────────────────────┘
1.4 Module Overview
| Module Category | Count | Description |
|---|---|---|
| Entry Signals | 20 types | SMC/ICT/Classic indicators, select one |
| Filter Signals | 5 groups × 20 types | Current TF + TF1 + TF2 + SL filter + TP filter + Add-pos filter |
| Trailing Stops | 3 sets × 9 types | Main trailing + Add-pos trailing + Partial stop trailing |
| Money Management | 6 types | None / FixedLot / FixedMargin / FixedRisk / SizeOptimized / SmartRecovery |
| Risk Control | Multiple | Daily P&L limits, floating loss limits, spread limits, news filter, time filter |
| Advanced Strategies | Multiple | Martingale, CAP, Breakeven-when-loss, Partial TP/SL, Trend bias filter |
1.5 Embedded Custom Indicators
The EA embeds the following 16 custom indicators via #resource , requiring no separate installation:
| Indicator Name | Description |
|---|---|
| SMC_MarketStructure | Market structure analysis (BOS / CHOCH / Swing High/Low) |
| SMC_OrderBlock | Order Block identification |
| SMC_FVG | Fair Value Gap detection |
| SMC_BreakerBlock | Breaker Block identification |
| SMC_BSL_SSL | Buy/Sell Side Liquidity sweep detection |
| SMC_SwingHL | Swing High/Low identification |
| SMC_FiboRe | Fibonacci Retracement calculation |
| SMC_Killzone | Killzone / Trading Session identification |
| SMC_NWOG_NDOG | New York Week/Day Opening Gap detection |
| SMC_SD_OB | Supply/Demand zones + Order Block combo |
| SMC_StrongImbalance | Strong Imbalance detection |
| SMC_CandlesPatterns | Candlestick pattern recognition (Inside bar, Engulfing, Double top/bottom, etc.) |
| SMC_RangeDetector | Consolidation range detection |
| ICT_Bias | ICT Bias indicator |
| ICT_ATR | ICT Average Daily Range |
| Price_Channel | Price Channel indicator |
Chapter 2: EA Basic Settings
Parameter Group: ===========INPUTS FOR EXPERT===========
| Parameter | Default | Description |
|---|---|---|
| Expert_Title | "Giles_Expert_SMC" | EA Name. Displayed on the chart and used for persistent data file naming. |
| Expert_MagicNumber | 123456 | Magic Number. Unique identifier to distinguish different EA instances. Each instance must use a different Magic Number; otherwise, order management will be disrupted. |
| Expert_EveryTick | false | Every Tick Mode. false = checks once per minute bar formation; true = checks on every price tick. Most signals don't need tick-level processing; keep false . Set to true only when using signals marked (Tick Level). |
| Expert_slippage | 3 | Slippage Tolerance (adjusted points). Maximum allowed price deviation when placing orders. |
| Expert_spread_allowed | 0.0 | Maximum Allowed Spread (in points). Checked before each order; orders are blocked if spread exceeds this value. 0 = no limit. |
| Expert_account_time_offset | 3.0 | GMT Time Offset. Hours difference between broker server time and GMT. Used for news filtering and time-related calculations. Set according to your broker. |
| Expert_indicator_refresh_frequency | PERIOD_M1 | Indicator Refresh Frequency. Controls how often the EA's built-in indicators update. Default: every minute. |


