Status: in progress...
Background
I've been wanting to create something like this for a very long time, but did not know where to start. On top of that, whenever it came to planning this project, I would often get pushed away because of many uncertainties - I had no idea about software engineering principles, machine learning, trading and data analysis. Although I'm still lacking in some of those areas at the start of this project, I feel confident enough to start and learn where I need to in order to realize this project.
Even prior to planning it for the 3rd time now, I knew I would overestimate my abilities and underestimate the difficulty of some of the aspects of the bot. Regardless of the outcome, this project should still have a lot of learning value.
This blog post is special as it is being updated as I develop the bot. Instead of having multiple posts, all the material and events will instead go here with timestamps.
Planning
This section is dedicated to show the initial setup of some tools, APIs and approaches I intend on using. I explain my reasoning for each and label any changes if they occur in the future as I encounter obstacles during development.
In order to perform the simplest trade on the forex market without contacting foreign banks, one needs a broker. There are many popular big companies out there that offer a lot of features, integrations and even APIs. This project could benefit from an API, but most of them will force me into creating and processing my own market indicators. As I do not have a lot of knowledge on the matter, I decided to instead use a broker that can be contacted through a piece of software called Meta Trader.
Meta Trader is a very big software application used for trading stocks, bonds, foreign currency, etc. The catch with using it is that it does not provide an API service. To use Meta Trader 5, I need to write sophisticated software in MQL5 - their own programming language that's based on C.
Based on extensive documentation, it should be possible to write a script for Meta Trader 5 that monitors selected instruments, processes trade signals and fetches data for my bot. The unfortunate part is that I can't squish all of this into a single process. I have to use pipes to enable communication between the .NET and the MQL5 modules.
As far as the interface goes, it will be its own C# module with a simple 3-layer architecture: presentation, logic and data. Using windows forms should suffice for implementing a simple graphical interface where I can monitor performance and manually execute trade orders.
The AI model is written in Python so that I can utilize data manipulation libraries for training. The Python module is built at the same time as the interface and both of them sit in the same system process. To enable communication between these two, I have to split the modules and make them work on their individual threads with a pipe between them.