The story of Mudrex Mint

When we started out, we believed that if we selected enough good algos, we were going to be profitable. Keeping this in mind, we created a basic guideline for ourselves to help us determine what constitutes a good strategy. We looked at the performance scores, Sharpe ratios and the live performance to gauge if the strategy was good.

An algo is essentially a group of trading strategies clubbed together to their mutual benefit.

As the number of algos on our platform grew, the number of algos in our portfolio started growing. It reached a point where we had 29 algos in the month of June.

After a lot of observation and analysis, we realized that even though we had so many algos in the portfolio, we were still very susceptible to market swings, which was very concerning. After some deeper digging, we realized that a lot of the algos were correlated and that is why we were facing volatility in our portfolio. We were focussing on things at an algo level but that gave us no insight into how the portfolio would perform.

With this new idea of looking at things at a portfolio level, we started working on building a quantitative model for a portfolio. It was also in this month that our Optimizer was born.

Optimizer was built with one goal in mind, to make our lives easier.

It was in the month of June that we found ourselves stuck behind deadlines (read enemy lines), with Edul (read Raza) demanding that we build the portfolio (read Jericho missiles). We toiled hard, working night and day, building a device to help us escape this deadline. Our efforts in the month of June can be encapsulated as us building the rudimentary Iron Man to escape the deadline. We didn’t know the extent of what we had built, but it got the job done and we escaped Edul grasp. 

The goal of an optimizer is to optimize some quantity. We wanted an objective function that we were looking to maximize to yield a portfolio that had the characteristics we desired. We were new, so we just asked the optimizer to give us a portfolio that optimized returns divided by drawdown. This created a portfolio of 13 algos by analyzing over 3M portfolios and made 2.88% when BTC made 18.63%.

We were pretty excited about the performance of the portfolio that we generated in the month of June, but we saw a lot of inefficiencies and inaccuracies that we could remove and improve our allocation. Another aspect that we added to our optimizer was the ability to assign weights. We were itching to take it out for a spin. We also changed our objective function to reduce drawdowns. 

Our new objective function was returns divided by drawdown^2. This created a portfolio of 10 algos by analyzing over 20M portfolios and made 6.35% where BTC made 13%.

Drawdown is the lowest point in equity divided by a previous high point. It essentially measures the maximum loss a strategy has had historically.

Our approach till this point relied on randomly picking 10 algos, creating a portfolio, and comparing performance historically. The total possible portfolios of size 10 in a universe of size 300 are of the order of 10^18. We were barely scratching the surface of this and our next goal was to increase the number of portfolios that we analyze. This involved two major changes, improving the computation speed, and improving the portfolio generation (moving away from randomization to a definitive approach).

We upgraded our randomized approach to a constructive approach, where we start with a portfolio of 2 algos and keep adding more algos to this portfolio till it makes sense. If adding any strategy did not improve the portfolio, we would stop any further explorations down this path. We were effectively pruning the portfolios that we were looking at and this has greatly increased the number of portfolios that we analyze.

We also moved to a more comprehensive objective function, returns divided by the harmonic mean of drawdown^2 and volatility^2. This greatly improved our expected performance and we believed that we had achieved a milestone, our optimizer was generating portfolios that were not correlated to the market.

We still had a few more parts of the optimizer to improve, but Edul attacked us with deadlines (attacked Gulmeira) again and we saw it as a perfect opportunity to test out all the improvements and advancements that we had made. We generated a portfolio of 7 algos after analyzing over 800M portfolios (excluding the portfolios that we rejected while pruning) and made 6.11% where BTC lost 11.73%!

The next module on our target was the weight allocation module. Earlier, we used a brute-forced approach to weight allocation. This allowed only a few sets of states and while that was a good approximation, it had limitations in terms of the number of algos that we can have in our portfolio. We moved from a brute-force solution to a constructive approach here as well. This approach imagines a portfolio as a mixture of various drinks and tries to increase the proportion of one drink into this mixture till it improves performance.

Our portfolio for the month of October includes 5 algos, each at a weight of 20%.

During the month of September, we realized that strategy weight imbalance in bundles was creating a bias in our optimized portfolio. This came to our attention when one of the bundles for October was effectively trading 50% of holdings on one strategy that initially had only 12.5% allocation.

Mudrex’s current universe size is a hair raising 800,000 strategies. Out of these, only about 1% make it to the review stage and of that, about 20% make it to the marketplace. When we were dealing with bundles, our universe size was a meagre 500 algos, but now we are optimizing across our entire universe and our results have been amazing!

Tony Stark had Jarvis, we have our Optimizer!

We realized that our universe was wide enough to create multiple curated portfolios for people with different risk appetites. All we needed was a set of parameters to optimize over to create a curated portfolio. After a lot of discussions and debates, we came up with the following list of parameters for portfolios (in decreasing order of preference):

Low Risk: Drawdown, Volatility, Returns

Medium Risk: Drawdown, Returns

High Risk: Returns

We are extremely proud of the work we have done here and are excited to share this with our community!

Latest stories

You might also like...