Warrior_EA/Signals
Repository files (latest commit first)
Filename Latest commit message Latest commit date
AnimateDread 70cdec2717 fix(ai): drop the conv pooling stage - it reduced across filters, not time
FeedForwardConv emits POSITION-MAJOR output, matrix_o[out + window_out * i],
so one bar's window_out filter responses are contiguous and consecutive bars
sit window_out apart. Both pooling implementations (FeedForwardProof and
CPU_FeedForwardProof) slide FLAT over that buffer - pos = i * step, reducing
`window` CONSECUTIVE elements. On a position-major layout those neighbours
are different FILTERS of the same bar, never one filter across time.

At the shipped 3/2 the pool computed max(bar0_f0, bar0_f1, bar0_f2), then
max(bar0_f2, bar0_f3, bar0_f4), with every 8th window straddling a bar
boundary. So it collapsed unrelated feature detectors into whichever fired
hardest, passed gradient to that winner only, and halved the feature map
while doing it - all below every learnable layer, where nothing above can
recover it. The removed inputs' own labels ("3 Bars") show time-axis pooling
was the intent throughout.

Measured cost: CONV sat pinned at ~40% balanced accuracy for 510 eras with
Sell recall 0%, while plain MLPs on the same data reached 57-61%. HYBRID,
which also carried this stage, came second-worst of the batch-norm group.

Not fixable in the topology: pooling one filter across time needs a stride
of window_out BETWEEN samples within a window, which a consecutive-window
kernel cannot express at any window/step. That needs a stride-aware kernel
in Network.cl + WarriorCPU.cpp + WarriorDML.cpp and a DLL rebuild, and is
only worth doing if a conv front-end earns its place without downsampling
first - with 20 sliding positions there is little to gain by halving them.

ConvPoolWindow/ConvPoolStep and their enums are removed with it, along with
the |CP: fingerprint term added earlier today.

Both builds compile 0 errors, 0 warnings.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-29 19:28:44 -04:00
..
README.md feat(signals): add MACD/Ichimoku presets and Vote_Close disabled option 2026-07-26 18:33:12 -04:00
SignalCONV.mqh fix(ai): drop the conv pooling stage - it reduced across filters, not time 2026-07-29 19:28:44 -04:00
SignalHYBRID.mqh fix(ai): drop the conv pooling stage - it reduced across filters, not time 2026-07-29 19:28:44 -04:00
SignalIchimoku.mqh feat(signals): add MACD/Ichimoku presets and Vote_Close disabled option 2026-07-26 18:33:12 -04:00
SignalITF.mqh fix: add error logging for buffer failures and reject trades on invalid stop loss 2026-07-26 12:12:14 -04:00
SignalLSTM.mqh refactor: compose topologies from named stages; drop dead code 2026-07-29 00:38:05 -04:00
SignalMA.mqh feat: add unified MA type support to indicator tuner 2026-07-23 15:02:09 -04:00
SignalMACD.mqh feat(signals): add MACD/Ichimoku presets and Vote_Close disabled option 2026-07-26 18:33:12 -04:00
SignalMarketDepth.mqh feat: implement hybrid AI signal with CNN-LSTM architecture and add pooling parameters 2026-07-27 22:08:55 -04:00
SignalNewsFilter.mqh fix: add error logging for buffer failures and reject trades on invalid stop loss 2026-07-26 12:12:14 -04:00
SignalPAI.mqh feat: add max-pooling and convolution OpenCL kernels, clean up barrier and signal code 2026-07-13 03:23:39 -04:00
SignalRiskGuard.mqh fix: add error logging for buffer failures and reject trades on invalid stop loss 2026-07-26 12:12:14 -04:00
SignalRSI.mqh refactor(AI): clean up comments and add conditional compilation guards 2026-07-22 17:17:23 -04:00
Signals.mqh feat: implement hybrid AI signal with CNN-LSTM architecture and add pooling parameters 2026-07-27 22:08:55 -04:00
SignalSessionFilter.mqh fix: add error logging for buffer failures and reject trades on invalid stop loss 2026-07-26 12:12:14 -04:00

Signals Subsystem (Signals/)

Overview

The Signals/ directory contains all trade signal generation logic for the Warrior EA. It includes both traditional indicator-based signals and advanced AI/ML-driven signals. Each signal is encapsulated in its own class, supporting modularity and extensibility.

Key Components

Signals.mqh

  • Main orchestration file for signal modules.
  • Includes both traditional and AI/ML signal classes.
  • Facilitates integration of filters (news, session, etc.) and advanced signals.

AI/ML-Driven Signals

  • SignalLSTM.mqh: Implements an LSTM-based neural network signal generator. Integrates with the AI subsystem, supports model training, loading, and inference. Designed for advanced, data-driven strategies.
  • SignalPAI.mqh: Implements a Perceptron AI-based signal generator. Inherits from CExpertSignalAIBase. Provides methods for initializing, training, and using a perceptron neural network for trade signal generation. Supports dynamic configuration, indicator integration, and modular AI/ML pipeline features. Designed for advanced, data-driven strategies and easy integration into the EA's AI subsystem.

Traditional Indicator-Based Signals

  • SignalMA.mqh: Moving Average signal generator.
  • SignalMACD.mqh: MACD oscillator signal generator.
  • SignalRSI.mqh: Relative Strength Index signal generator.
  • SignalStoch.mqh: Stochastic oscillator signal generator.
  • SignalPB.mqh: Pin Bar pattern signal generator.
  • SignalNewsFilter.mqh: News event filter for signals, configurable by impact and lookback period.
  • SignalSessionFilter.mqh: Session-based filter (London, New York, Tokyo sessions).

Individual Signal Modules

Below is a comprehensive list of all signal modules in the Signals/ directory, with a brief description of each:

  • SignalAC.mqh: (Removed)
  • SignalAO.mqh: (Removed)
  • SignalCCI.mqh: (Removed)
  • SignalCONV.mqh: Convolutional AI signal. Uses a neural network for advanced pattern recognition.
  • SignalDTDB.mqh: (Removed)
  • SignalEB.mqh: (Removed)
  • SignalIB.mqh: (Removed)
  • SignalIchimoku.mqh: Ichimoku Kinko Hyo classic vote, written from scratch (no standard-library module exists). 12 patterns numbered weakest-to-strongest, covering the full repertoire: price/cloud bias, projected cloud colour and full Chikou Span confirmation (models 0-2, all at the standard-library floor weight of 10 since each is a standing state rather than a trigger); the TK cross graded weak/neutral/strong by cloud position (3/5/10, weights 10/40/90); Kumo twist (4); Kijun-sen cross and bounce (6/7); Kumo breakout and thin-cloud breakout (8/9); and Sanyaku Kōten/Gyakuten at 100 (11). Its class comment documents MT5's draw-shift-only buffer convention and the resulting lookahead hazard.
  • SignalITF.mqh: Intraday Time Filter. Filters signals based on time-of-day and day-of-week.
  • SignalLSTM.mqh: LSTM AI signal. Uses a recurrent neural network for sequence-based prediction.
  • SignalMA.mqh: Moving Average classic vote (unified ADMovingAverage custom indicator; 4 patterns).
  • SignalMACD.mqh: MACD oscillator classic vote, ported from the MQL5 standard library. 6 patterns including single and double price/oscillator divergence — the only divergence model in the classic set.
  • SignalNewsFilter.mqh: (Filters trading signals based on economic news events and impact levels. Configurable lookback window and impact threshold.)
  • SignalPAI.mqh: Implements a Perceptron AI-based signal generator. Inherits from CExpertSignalAIBase. Provides methods for initializing, training, and using a perceptron neural network for trade signal generation. Supports dynamic configuration, indicator integration, and modular AI/ML pipeline features. Designed for advanced, data-driven strategies and easy integration into the EA's AI subsystem.
  • SignalPB.mqh: (Removed)
  • SignalRSI.mqh: RSI classic vote (4 patterns).
  • SignalRVI.mqh: (Removed)
  • Signals.mqh: Main orchestration file for all signals.
  • SignalSAR.mqh: (Removed)
  • SignalSessionFilter.mqh: (Removed)
  • SignalStoch.mqh: (Removed)
  • SignalWPR.mqh: (Removed)

Integration Notes

  • All signals derive from a common base (typically CExpertSignalCustom or CExpertSignalAIBase).
  • Modular design allows for easy addition/removal of signals and filters.
  • Migration to a fully AI/ML-driven pipeline is recommended for future-proofing and improved performance.
  • Some files (e.g., SignalPAI.mqh) may require conversion or external review due to non-text format.

Documented April 2026. For AI/ML migration and modernization, see AI_NETWORK.md and project roadmap.