Project Prana
Inspiration
Recently, the influence of twitter posts onto the market were hard to miss. In mere seconds, a stable market can turn around and turn extremely profitable, or can end in a catastrophic downfall. For a market maker, who lives from riding subtle waves of the market, getting caught in such an event can turn out disastrous.
What it does
By directly correlating twitter posts to their effect on the market, we can effectively predict changes of the market and act accordingly. To predict the influence of tweets, we use a sophisticated AI model, that predicts the effect of tweets on the market, based on their sentiment and other factors. We use this information for two different strategies that are neatly combined for a maximized profit. The first strategy is to only perform market making when the market is predicted to be stable to minimize the involved risk. The second strategy is to aggressively buy or sell in volatile phases, depending on whether our model predicts the market to go up or down. We combine both strategies by incorporating the stock surplus or deficit resulting from the second strategy into the market making to sell or rebuy it at a better, passively traded price. In addition, rigorous research revealed that by using both a prediction of the magnitude of influence that a tweet has with a weighted mean of the last values of the market, it can be determined when the influence of a tweet wears of. The weighted mean is also used to determine short-term fluctuations to better adjust market making accordingly.
How we built it
We built this complex system by first developing and optimizing the two strategies individually, then combining them and iteratively improving the combined strategies. For the tweet influence predictions, we developed and compared two models: a super lightweight, word-statistics based model and the trained AI model. Testing revealed that the higher accuracy of the AI model outweights the faster performance of the statistics based model. The AI model consists of two stages. The first stage performs Zero Shot classification on the tweet to detect the sentiment, which is then shared with the second stage, a regression based model, to predict how much it can affect the market. We further use the Moving Average to detect the end of volatile periods and improve market making profitability.
Challenges we ran into
As nobody of us had any previous experience in the field of finance or trading, understanding the concepts and jargon of the market took us some time. Thankfully, the Optiver team supported us, so that we gained basic understanding by the beginning of the second day.
Accomplishments that we're proud of
Making it into the positive! For a long time, we were fighting to make a profit on the market. At some point, our code was coming together, resulting in a profit that was way bigger than we would have imagined. Having improved even more by now, we are proud that we exceeded our own goals.
What we learned
How to trade on the market, and what to be aware of. We ran into many traps, e.g., sold when the market was going down which resulted in a loss, and learned from these traps.
What's next for Praan
We are excited to see how our algorithm will perform in the actual competition. We believe in you, Prana-bot!
Built With
- huggingface
- optibook
- python
Log in or sign up for Devpost to join the conversation.