An integrated framework for multi-commodity agricultural price forecasting and anomaly detection using attention-boosted models
Global agricultural systems are increasingly exposed to price instability driven by climate extremes, logistic disruptions, and market uncertainty. These conditions complicate efforts to monitor and manage price behaviours in essential commodity markets. Micro, small, and medium enterprises (MSMEs), which operate with constrained resources and limited access to data-driven tools, are particularly susceptible to sudden and irregular price shifts. Their ability to maintain stable operations depends on timely identification of market anomalies and reliable planning information. This underscores the importance of accurate price forecasting, yet deep learning models such as Bidirectional Long Short-Term Memory (LSTM) and the Gated Recurrent Unit often struggle to capture long-term dependencies and detect irregular price behaviors. To bridge the gap, this study proposes a deep learning framework that integrates transformer models for price prediction and an attention-boosted LSTM Variational Autoencoder (VAE) for anomaly detection. Using daily price data collected from the period of January 2020 to mid-June 2024, this study demonstrated that transformers outperformed traditional models while accurately capturing market trends and sudden fluctuations. Additionally, the attention-boosted anomaly detection model can outperform standard LSTM and artificial neural network-VAEs in identifying unexpected price changes. The proposed models outperformed baseline methods by achieving lower forecasting and anomaly detection errors. By addressing critical limitations in existing forecasting approaches, specifically their inability to capture abrupt anomalies, this study provides essential support for enhancing MSMEs’ resilience and improving decision-making under volatile market conditions. • We propose a framework for commodity price prediction and anomaly detection. • Our approach outperforms others in terms of price prediction and anomaly detection. • The proposed framework also provides early warnings of market disruptions. • It boosts resilience and supports stable growth in volatile agri-markets.
Authors
- Raymond Chiong (ORCID: https://orcid.org/0000-0002-8285-1903)
- Christian Arthur (ORCID: https://orcid.org/0009-0009-8145-1439)
- Intiyas Utami (ORCID: https://orcid.org/0000-0001-9206-8501)
- Kristoko Dwi Hartomo (ORCID: https://orcid.org/0000-0003-0237-851X)
- Ronny Prabowo (ORCID: https://orcid.org/0000-0003-0785-3156)
- Eko Sediyono (ORCID: https://orcid.org/0000-0001-6034-9659)
Institutions
- University of Technology Sydney (AU)
- Satya Wacana Christian University (ID)
- New South Wales Institute of Psychiatry (AU)
- University of Newcastle Australia (AU)
Publication Details
- Journal
- Journal of Agriculture and Food Research
- Published
- 2025-05-15
- DOI
- https://doi.org/10.1016/j.jafr.2025.102021
- Citations
- 5
- Primary Topic
- Market Dynamics and Volatility
- Type
- article
- Field-Weighted Citation Impact
- 15.66