Discussing the article: "Neural Networks in Trading: Effective Feature Extraction for Accurate Classification (Final Part)"

 

Check out the new article: Neural Networks in Trading: Effective Feature Extraction for Accurate Classification (Final Part).

The Mantis framework transforms complex time series into informative tokens and serves as a reliable foundation for an intelligent trading agent capable of operating in real time.

The first stage is contrastive training of the Encoder. It is performed on historical data for the past five years for the EURUSD currency pair on the M1 timeframe. This volume and level of detail in the data enable the Encoder to develop high-quality, informative latent representations of the market state, which serve as the foundation for the further operation of the entire system.

Next comes the second stage — offline training of the key components of the system: the Actor, the Director, and the Critic. To do this, a training dataset collected from 2024 data is used, while retaining all the parameters specified earlier. The process uses the concept of a near-perfect trajectory, allowing the models to learn from the most reliable examples of actions and assessments. This stage is important for reinforcing basic strategies and decision-making criteria.

The third stage is online fine-tuning of the models, which is carried out directly in the Strategy Tester on the same historical interval. This makes it possible to adapt the models to changing market conditions and fine-tune the parameters as accurately as possible.

Once all training stages are complete, the model is tested using data from January through March 2025. At the same time, all parameters used during the training phases remain unchanged. This approach ensures a fair and objective evaluation of the model's performance on a new, previously unused dataset. The test results are presented below.


Author: Dmitriy Gizlyk

[Deleted]  
It’s odd that it only trades in one direction. How are the signals for closing trades generated?