In this episode, we do a deep dive into the story of the brand new Hexabot! The goal of this project was to build an automated strategy that navigates all market conditions.
We believe you can design a bot to assess short-term and long-term market trends, proactively adapt to current market conditions, and enter the appropriate position type. With the amazing involvement of our entire community, we built the Hexabot.
This podcast is only a brief overview of the Hexabot. Click here for Kirk’s Community post to see a more detailed explanation and clone the bot.
Not an Option Alpha member? Start a free trial today to access the Hexabot and hundreds of other pre-built templates.
Origin & background
The Hexabot is the collective brainchild of the Option Alpha trading Community. There are so many unique ideas that we pulled out of other shared templates to create the Hexabot. We studied monitors and scanners from popular templates to find what we could add and optimize in the Hexabot.
It took a really long time. We deliberately went through a planning and research phase and an ideation phase. Then, we did more testing and research. Finally, we started building.
Of course, we'll continue refining this template and look for opportunities to improve it. We've already updated the version a few times, correcting and simplifying items based on members’ feedback.
We set this bot up to trade one ticker to let us more easily control things like position sizing and allocation. We approached the strategy holistically, considering how much to allocate to each ticker in our portfolio. You are always in full control of a bot’s position and allocation limits.
The standard position allocation is 10% of the bot’s net liquidity. We wanted the bot to trade actively, so we created laddered entries. You typically get smoother returns when you space out your entries over time.
Six different market environments
We identified six market environments and outlined how we wanted the bot to trade within each of those trends.
- Strong uptrend: Ticker is above long-term SMA, above short-term SMA, and short-term SMA is above long-term SMA
- Uptrend: Ticker is above long-term SMA, above short-term SMA, and short-term SMA is below long-term SMA
- Weak uptrend: Ticker is above long-term SMA but below short-term SMA
- Strong downtrend: Ticker is below long-term SMA, below short-term SMA, and short-term SMA is below long-term SMA
- Downtrend: Ticker is below long-term SMA, below short-term SMA, and short-term SMA is above long-term SMA
- Weak downtrend: Ticker is below long-term SMA but above short-term SMA
Each market condition yields a different position type:
- Strong uptrend + overbought technicals = Short call spread
- Strong uptrend + neutral technicals = Short put spread
- Uptrend + overbought technicals = Iron condor (with an option to skew)
- Uptrend + neutral technicals = Iron condor (balanced)
- Weak uptrend + oversold technicals = Short put spread
- Weak uptrend + neutral technicals = Iron condor (balanced)
- Strong downtrend + oversold technicals = Short put spread
- Strong downtrend + neutral technicals = Short call spread
- Downtrend + oversold technicals = Iron condor (with an option to skew)
- Downtrend + neutral technicals = Iron condor (balanced)
- Weak downtrend + overbought technicals = Short call spread
- Weak downtrend + neutral technicals = Iron condor (balanced)
The Hexabot is an excellent example of using notifications to communicate what the bot did throughout its automations.
We relied heavily on tagging. Not only because it's super powerful, but because it allows us to set how the bot could lead itself down different paths and make different decisions.
One scanner automation and one monitor automation
We chose to use a single scanner and monitor so that you could see all of the logic at each step within one screen.
Initially, we had multiple scanners and monitors for different timeframes in the expiration cycle. We eventually got it all into one scanner and one monitor, so it was easier to make changes, edit decisions, and track the bot’s activity.
Bot level inputs
The scanner automation checks multiple criteria before entering a position using bot-level inputs. The first decision checks to see if the scanner is enabled. This allows us, at the top of the automation, to immediately prevent the bot from going down a path that would enter a new position.
Then, we reset the tags every time the bot runs. This allows the bot to be the most accurate and current version that reflects the market and bot‘s combined conditions.
An important volatility check ensures the bot can open a new position that day. This way, the automation monitors market conditions, the state of your portfolio, and the state of your bots so that you can focus on other decisions.
Technical indicator checks
The first market check is whether the underlying ticker is above the long-term simple moving average with this recipe. Next, the bot looks at the short-term moving average.
With the heat check, you can swap between bullish credit spreads, bearish credit spreads, neutral iron condors, and skewed iron condors. We've made all this very customizable with custom inputs. You can plug in your technical indicator of choice and your preferred overbought or oversold.
The bot has to pass four detailed opportunity filters before sending an order to the broker:
- Bid-ask spread maximum
- Open interest minimum
- Rate of return threshold
- Probability of profit input
Accelerated and absolute profit targets
The bot uses multiple targets to exit positions based on certain profit levels.
Absolute profit target
If the bot reaches an absolute profit target, it exits the position immediately.
Quick accelerated profit target
The bot will check if a potion has reached a pre-defined profit target. This allows you to exit the position for a quick profit and open another position.
Second accelerated profit target
The second accelerated profit target check happens after another set of days with a slightly different profit level.
After we get past the decisions for evaluating the position’s strikes, if the stop-loss exit is turned on, it will determine whether that position has reached the stop-loss.
You already go through these decisions when trading manually; you just have to go through them yourself.
A short-term trend reversal trigger can help you evaluate whether the trend is changing. Also included here is a minimum rate of return threshold.
Reduced DTE profit targets
The monitor automation is set up to reduce the main profit target as positions near expiration.
Similar to how we were willing to accept early profits, we’re willing to accept smaller profits as time runs out. All you have to do is enable or disable a switch for intelligent expiration week management.
Bid-ask spread waterfalls
The bid-ask spread waterfall is a very clever but simple concept that repeats throughout the monitor automation. You'll see the same decisions and the same sets of criteria repeated throughout.
Essentially, you can adjust how SmartPricing works based on the spread width to avoid trying to execute orders when the bid-ask spread is wide.
- Level 1 B/A Spread = 0.15 bid/ask spread
- Level 1 Price = 100% of bid/ask spread
- Level 2 B/A Spread = 0.25 bid/ask spread
- Level 2 Price = 90% of bid/ask spread
- Level 3 B/A Spread = 0.50 bid/ask spread
- Level 3 Price = 70% of bid/ask spread
- Level 4 B/A Spread = 0.75 bid/ask spread
- Level 4 Price = 63% of bid/ask spread
- Level 5 B/A Spread = 1.00 bid/ask spread
- Level 5 Price = 60% of bid/ask spread
We truly hope you loved reading this summary and the Hexabot’s history. This Community is an incredibly special place and this template demonstrates the power of the wicked smart traders we have the pleasure of working with here at Option Alpha. This has been a really fun bot to build.
Enjoy the Hexabot!