Documentation Index
Fetch the complete documentation index at: https://mintlify.com/hummingbot/hummingbot/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Hummingbot strategies are automated trading logic that execute buy and sell orders based on defined parameters. Hummingbot supports two strategy frameworks: V1 (Classic) strategies and V2 (Controller-based) strategies.Strategy Framework Comparison
V1 Strategies (Classic)
V1 strategies are the original Hummingbot strategy framework, implemented as monolithic strategy classes that inherit fromStrategyPyBase.
Architecture:
- Located in
hummingbot/strategy/ - Each strategy is a self-contained Cython module (
.pyxfiles) - Inherits from
StrategyPyBasewhich provides event-driven hooks - Direct integration with exchange connectors
pure_market_making- Market making on a single exchangecross_exchange_market_making- Arbitrage between two exchangesavellaneda_market_making- Advanced market making with inventory managementamm_arb- Arbitrage between AMM and order book exchangesliquidity_mining- Automated liquidity provisionspot_perpetual_arbitrage- Arbitrage between spot and perpetual marketsperpetual_market_making- Market making on perpetual futureshedge- Hedging strategy across marketscross_exchange_mining- Mining across multiple exchanges
hummingbot/strategy/ directory.
V2 Strategies (Controller-based)
V2 strategies use a modular, controller-based architecture that separates strategy logic into reusable components. Architecture:- Strategy scripts use configuration classes that inherit from
StrategyV2ConfigBase - Controllers implement specific trading logic (directional trading, market making, LP management)
- Executors handle position management and order execution
- Market data providers supply candles, order book, and trade data
Directional Trading
Controllers that take directional positions based on market signals
bollinger_v1- Bollinger Bands mean reversionbollinger_v2- Advanced Bollinger strategymacd_bb_v1- MACD + Bollinger Bandssupertrend_v1- SuperTrend indicator strategydman_v3- Dynamic risk managementbollingrid- Grid trading with Bollinger Bands
Market Making
Controllers that provide liquidity by placing orders on both sides
pmm_simple- Simple pure market makingpmm_dynamic- Dynamic spread adjustmentsdman_maker_v2- Advanced market making with risk management
controllers/directional_trading/ and controllers/market_making/.
Data Integration:
V2 strategies use MarketDataProvider to access market data:
controllers/directional_trading/bollinger_v1.py:14-65.
Choosing a Strategy Framework
Related Concepts
- Connectors - Exchange integration layer
- Order Types - Different order execution methods
- Market Data - Data structures for trading decisions