Considering the dynamic nature of market conditions, this paper introduces a state-dependent futures hedging optimization model and methodology. This approach dynamically adjusts the traditional model-driven hedging strategy, effectively balancing the pursuit of returns with the imperative of risk mitigation. Empirical evidence shows that integrating Hidden Markov Model (HMM) with machine learning techniques, as demonstrated in this study, improves the accuracy of market state forecasts. Compared to the traditional model-driven hedging strategy, the innovative state-dependent hedging strategy ...