I was looking at the thread attached (hopefully this is coming soon) and I was wondering if it would be possible to implement neural nets into the genetic evolution process itself in addition to using NN as described in the thread. From what I understand the NN that is currently being worked on is meant for the selection of different blocks. Can a NN also be used for the combination of different strategies in each generation of the genetic evolution process? From what I understand, genetic evolution splices params between the most effective strategies with each successive generation. While this can help strategies improve, I have found in SQ3 that this tends to narrow down the current generation to only a few unique strategies after multiple generations. However, if we are logging the performance of different combinations of blocks, it should be theoretically possible to let a NN take care of using that data in order to splice params instead of the current form of genetic evolution that only splices the top performing params. This should also in theory lead to a diverse set of strategies after multiple generations instead of having multiple versions of the same strategy after multiple generations. The NN should be able to edit/add different user selected blocks to each strategy in the databank based on a log of previous successful combinations.
This is all based on a very basic understanding of these underlying mechanisms so if I am totally off base or this reflects the current plan for implementation, feel free to let me know.
By default, I think it should be manual storing in order to use less memory but an automated version of this would essentially be to store strategies that passed x tests/filters etc. Essentially this would become a copy of a databank that a NN could learn from in order to create new strategies and combine blocks in different ways when splicing a learned outcome with randomly generated code. The result should be new code that the NN thinks should produce a profitable result.
The editing process should be pretty simple and straightforward:
The second NN (that Mark mentioned was for the training) would then take that strategy and treat it like any other randomly generated strategy that it would train on the given data set. The difference here is that you had a NN putting the first strategy together based on learned patterns in order to start off with a better result. The larger the dataset, the better the NN would be at putting strategies together because it can learn from more patterns, however, the NN would have to be able to deal with the time complexity of a potentially large data set in order not to significantly slow down genetic evolution. If this was made fast and efficient, the resulting strategies at the end of genetic evolution should be much more effective in theory.
Assignee changed from Mark Fric to Mark Fric
Description changed:
I was looking at the thread attached (hopefully this is coming soon) and I was wondering if it would be possible to implement neural nets into the genetic evolution process itself in addition to using NN as described in the thread. From what I understand the NN that is currently being worked on is meant for the selection of different blocks. Can a NN also be used for the combination of different strategies in each generation of the genetic evolution process? From what I understand, genetic evolution splices params between the most effective strategies with each successive generation. While this can help strategies improve, I have found in SQ3 that this tends to narrow down the current generation to only a few unique strategies after multiple generations. However, if we are logging the performance of different combinations of blocks, it should be theoretically possible to let a NN take care of using that data in order to splice params instead of the current form of genetic evolution that only splices the top performing params. This should also in theory lead to a diverse set of strategies after multiple generations instead of having multiple versions of the same strategy after multiple generations. The NN should be able to edit/add different user selected blocks to each strategy in the databank based on a log of previous successful combinations.
This is all based on a very basic understanding of these underlying mechanisms so if I am totally off base or this reflects the current plan for implementation, feel free to let me know.
But how exactly? Should NN somehow recommend or rank the best block combinations? Do you have some more exact idea how it should work?
I dont have the exact map for the algorithm for the matching part down but the basic idea is that something like this should be doable:
The training algorithm would then take that in as any other strrategy in the databank and trains it on the data before the next evolution (if I understand the NN you're already working on.
I dont know if this is helpful or not. I have been studying computer science so I think this is a viable solution but I'll leave that up to the SQ team to determine :)
The full description of this addition is here: https://roadmap.strategyquant.com/tasks/sq4_4042
Hopefully, this catches on. Even though it will be a long term project, I believe the end result would be something that no one else could compete with because we'd all keep improving what we ultimately develop individually and collectively.
Update: Thanks to Mark and Geektrader, a base level version of what I wanted Neural Nets to accomplish is coming out in 118.
https://roadmap.strategyquant.com/tasks/sq4_3923
https://roadmap.strategyquant.com/tasks/sq4_3977
Adding Neural Networks would further expand the capability of this 'fresh blood' feature. Mark already said he's working on implementing a Neural Network for strategy training. What I am suggesting is that a second Neural Net is implemented for the strategy generation of "fresh blood' on each subsequent generation. This would allow for better strategies to be added into the databank out of the gate rather than having completely randomly generated strategies become fresh blood.
My suggestion for anyone considering implementing this in the future is using a Convolutional Neural Network for the training (reduces time complexity and outperforms other models on time series data), and for strategy selection, a Feed Forward Neural Network (for simplicity/ speed) or a Kohonen Neural Network (for better performing strategies) would probably work best.