Hummingbot Directional Positions and Custom OHLCV Data
Summary
Hummingbot version 1.13.0 introduced an early Directional Framework for managing positions on perpetual exchanges. Its PositionExecutor accepts a position configuration and uses a triple barrier approach: a stop loss, a take profit, and a time limit. The strategy calls the component on each tick, with asynchronous operation described as a planned improvement. The release notes explain the framework but provide no performance evidence or evaluation of the risk controls.
The update also added Binance and Binance perpetual candle feeds that combine historical and live data to construct custom OHLCV series for technical indicators. It describes a factory for creating candles and points to sample RSI, Bollinger Band, and microprice scripts. The notes also cover Gateway becoming a standalone project and general software changes; these are release details, not evidence that the example strategies are profitable. The directional tooling is relevant to systematic traders, but the document does not specify validated signals or backtest results.
Key ideas
- The PositionExecutor manages a directional position with stop loss, take profit, and time limit barriers.
- The release describes support for directional positions on perpetual exchanges.
- Custom Binance candle feeds combine historical and live data to construct OHLCV series.
- The release includes example indicator scripts but reports no strategy performance results.
Tags
Full text
# Release Notes - Version 1.13.0
# Release Notes - Version 1.13.0
*Released on February 28, 2023*
We are very excited to ship the February 2023 release of Hummingbot (v1.13.0) today! This release introduces new standalone open source repositories for the `gateway` DEX connector module, the community-maintained `/brokers` multi-bot orchestration module, and a new `deploy-examples` repo.
**Hummingbot**
* Github: [`v1.13.0`](https://github.com/hummingbot/hummingbot/releases/tag/v1.13.0)
* DockerHub: [`version-1.13.0`](https://hub.docker.com/r/hummingbot/hummingbot/tags?name=version-1.13.0) | [`version-1.13.0-arm_beta`](https://hub.docker.com/r/hummingbot/hummingbot/tags?name=version-1.13.0-arm)
**Hummingbot Gateway**
* Github: [`v1.13.0`](https://github.com/hummingbot/gateway/releases/tag/v1.13.0)
* DockerHub: [`version-1.13.0`](https://hub.docker.com/r/hummingbot/gateway/tags?name=version-1.13.0)
**Deployment Repos**
- [`hummingbot/deploy-examples`](https://github.com/hummingbot/deploy-examples): Deploy Hummingbot in various configurations with Docker
- [`hummingbot/brokers`](https://github.com/hummingbot/brokers): Multi-bot orchestration
See below for what's new this month!
## Directional Framework
This release adds the first components of the Directional Framework mentioned in our [2023 Technical Roadmap](https://hummingbot.org/blog/posts/hummingbot-2023-technical-roadmap/):
> Execution bot: Bot that receives signals that based on local rules, create a new position and control three barriers: (1) stop loss, (2) take profit and (3) time limit. After execution, the bot can send trading status and history to other destinations.
[6026](https://github.com/hummingbot/hummingbot/pull/6026) added the `PositionExecutor` smart component. This component receives as input the strategy and the `PositionConfig`, which is a new data type that includes the information needed to start a directional position on a perpetuals exchange that utilizes the [triple barrier method](../strategies/v2-strategies/executors/positionexecutor.md#the-triple-barrier-method) popularized in [Advances in Financial Machine Learning](https://www.wiley.com/en-us/Advances+in+Financial+Machine+Learning-p-9781119482086) by Marcos López de Prado.
For now, the component is controlled by the strategy by calling the method control position every tick, but is going to be improved by creating an async task that is going to execute this process until the executor is done.
Watch our monthly [developer call](https://www.youtube.com/watch?v=X63rACPjtUE) for an explanation of the directional framework.
## Custom OHLCV Candles
Our 2023 technical roadmap post also mentioned a project to help users generate custom indicators using exchange data:
> Many of the traders and Hummingbot developers are interested in add indicators to their strategies.
> Currently, the only way to do this with Hummingbot right now is using trailing indicators (per-tick price data collected by the bot), but this solution is not suitable for candlestick indicators, since you have to get historical data to construct the OHLCs needed.
> That’s why one of the projects will be the OHLC Generator, that will allow users to initialize their strategies with multiple OHLCs (time or volume based). In addition, we plan to support third-party library like ta-lib so that users can compute and create various indicators.
[6046](https://github.com/hummingbot/hummingbot/pull/6046) added a candles data feed for [binance](../exchanges/binance/index.md) and [binance-perpetual](../exchanges/binance/index.md). This "signal factory" component allows users to generate custom OHLCV candles using both historical and live Websocket data, allowing traders to use technical indicators to code directional strategies.
A base class is provided to add more candle providers and a `CandlesFactory` is also included to simplify the creation of the candles. We encourage community members to add data feeds for other exchanges.
## New Gateway Standalone Repo and Docs
Gateway is now a standalone repository: <https://github.com/hummingbot/gateway>. It has a similar license, folder structure, and contribution process to Hummingbot. In addition, the Gateway DockerHub is located at: <https://hub.docker.com/repository/docker/hummingbot/gateway>.
In addition, we have significantly updated the Gateway installation process. Now, users can install Gateway from source or via Docker, similarly to Hummingbot. The newly updated [Gateway documentation](https://hummingbot.org/gateway/) show you how to install and use Gateway with Hummingbot.
In addition, the [`/deploy-examples`](https://github.com/hummingbot/deploy-examples) repo shows you how to set up Hummingbot and Gateway with Docker Compose.
- [6080](https://github.com/hummingbot/hummingbot/pull/6080) Removed Gateway from Hummingbot repo
- [6092](https://github.com/hummingbot/hummingbot/pull/6092) Removed the gateway `start`, `stop` and `create` commands since the new setup is different
- [6063](https://github.com/hummingbot/hummingbot/pull/6063) Simplified Gateway certs management
## New Script Examples
- [amm_price_example.py](https://github.com/hummingbot/hummingbot/blob/master/strategies/scripts/amm_price_example.py): Fetches price from a DEX connector using Gateway
- [amm_trade_example.py](https://github.com/hummingbot/hummingbot/blob/master/strategies/scripts/amm_trade_example.py): Executes a swap using a DEX connector using Gateway
- [candles_example.py](https://github.com/hummingbot/hummingbot/blob/master/strategies/scripts/candle_example.py): Build custom indicators using the Binance candles feed
- [simple_directional_script_example.py](https://github.com/hummingbot/hummingbot/blob/master/strategies/scripts/advanced_directional_strategy_example.py): Creates a simple directional strategy that uses RSI
- [advanced_directional_script_example.py](https://github.com/hummingbot/hummingbot/blob/master/strategies/scripts/simple_directional_strategy_example.py): Creates an advanced directional strategy that uses both RSI and Bollinger Bands
- [microprice_calculator.py](https://github.com/hummingbot/hummingbot/blob/master/strategies/scripts/microprice_calculator.py): Computes the [microprice](https://papers.ssrn.com/sol3/papers.cfm?abstract_id=2970694) price estimator using exchange data
See our [January developer call](https://www.youtube.com/watch?v=X63rACPjtUE) for an explanation of the two directional scripts above, as well as [this video](https://youtu.be/S7eig5VXFpY?t=2439) from Sasha Stoikov in which he discusses the microprice indicator and runs Hummingbot.
## New CEX Connector: `btc-markets`
Per [PRP-6052](https://snapshot.org/#/hbot.eth/proposal/0x3766f03b59e8484a80e0ba5a774aca43962a024ab46c9cc15b0a96656df1dc99), we are happy to welcome the `btc-markets` connector back to the Hummingbot codebase!
BTC Markets is a centralized cryptocurrency exchange established in Australia, and is available for local residents only. BTC Markets aims to provide clients with an efficient, secure, and reliable trading platform. Its services are available to individuals, organizations, and Self-Managed Super Funds. See the [btc-markets](../exchanges/btc-markets.md) connector documentation for more information.
**Thanks to [vdmerweandre](https://github.com/vdmerweandre) for this contribution! 🙏**
## Other Updates
### Hummingbot
- [5821](https://github.com/hummingbot/hummingbot/pull/5821) Fixed issue with `CoinGecko` rate oracle exceeding rate limit **Thanks to [MementoRC](https://github.com/MementoRC) for this fix! 🙏**
- [6061](https://github.com/hummingbot/hummingbot/pull/6061) Fixed incorrect websocket account position **Thanks to [yancong001](https://github.com/yancong001) for this fix! 🙏**
- [6066](https://github.com/hummingbot/hummingbot/pull/6066) Added the ability for Hummingbot to autostart scripts. Users can now pass the parameter `--config-file-name={script_name}.py` for the script to autostart.
- [6051](https://github.com/hummingbot/hummingbot/pull/6051) Added `pandas_ta` dependency
- [6064](https://github.com/hummingbot/hummingbot/pull/6064) Fixed issue with `PaperTrade` exchange where the maker order defaults to taker fee
- [6065](https://github.com/hummingbot/hummingbot/pull/6065) Removed the remaining strategies that failed to reach the quorum on last community poll. Recap of Epoch 3 polls [here](https://hummingbot.org/blog/posts/epoch-3-polls-recap/)
- [6090](https://github.com/hummingbot/hummingbot/pull/6090) Fixed issue with the `Docker` update script
- [6104](https://github.com/hummingbot/hummingbot/pull/6104) Fixed some minor cosmetic issues with the `directional script`
- [6067](https://github.com/hummingbot/hummingbot/pull/6067) Fixed issue where Gateway wouldn't start when passphrase is a number
### Gateway
- [0016](https://github.com/hummingbot/gateway/pull/0016) Refactored `Sushiswap` connector to support `Polygon` and `Mumbai` network **Thanks to [gzliudan](https://github.com/gzliudan) for this fix! 🙏**
- [0034](https://github.com/hummingbot/gateway/pull/0034) Refactored `OpenOcean` connector. **Thanks to [onjeffery](https://github.com/onjeffery) for the original fix! 🙏**Shown in full with attribution under the source's licence. Licence: Apache-2.0
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.