Machine learning-based pharmaceutical inventory management for demand forecasting and expiry risk reduction
Abstract
Pharmaceutical inventory management is challenging because medicines have limited shelf lives and uncertain demand, which can lead to stockouts as well as inventory wastage. This study presents a machine learning-based decision-support framework that combines demand forecasting with batch-level expiry analysis to identify pharmaceutical inventory at risk of wastage and recommend suitable inventory actions. An experimental dataset containing 17,520 demand records was used for model development and evaluation. A 7-day moving average was used as a baseline forecasting method and compared with an XGBoost-based forecasting model. The experimental results show that the XGBoost model achieved a Mean Absolute Error (MAE) of 3.12, compared with 4.20 for the moving-average baseline, representing an improvement of approximately 25.7%. The forecasting output was further integrated with batch-level information such as quantity received, expiry date, shelf life, and expected leftover quantity to estimate potential waste exposure. Among 142 active batches analyzed, 111 were assigned FEFO priority, 16 were identified as return candidates, 9 were recommended for transfer to high-demand locations, and 6 were marked for discount-based action. The results indicate that combining demand forecasting with expiry-aware batch analysis can provide more actionable inventory decisions than relying on expiry information alone. The proposed framework can support pharmaceutical inventory managers in prioritizing stock rotation, returns, transfers, and discount actions.
Keywords:
Pharmaceutical Inventory Management, Demand Forecasting, Machine Learning, XGBoost, Expiry Risk, FEFO, Inventory Decision Support.Published
Abstract Display: 2
PDF Downloads: 0 Issue
Section
Copyright (c) 2026 SCIENXT CENTER OF EXCELLENCE(P) LTD.

This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.