Open Access
ARTICLE
Hybrid Deep Learning Approach for Coupled Demand Forecasting and Supply Chain Optimization
1 Department of Information Technology, Washington University of Science and Technology, Alexandria, VA, USA
2 Department of Information Technology, University of the Potomac, Washington, DC, USA
3 Department of Computer Science, Campbellsville University, Louisville, KY, USA
4 Center for Advanced Analytics (CAA), COE for Artificial Intelligence, Faculty of Engineering & Technology (FET), Multimedia University, Melaka, Malaysia
5 Department of Computer Science and Engineering, American International University-Bangladesh (AIUB), Dhaka, Bangladesh
* Corresponding Author: Md Jakir Hossen. Email:
Computers, Materials & Continua 2026, 88(3), 21 https://doi.org/10.32604/cmc.2026.074236
Received 06 October 2025; Accepted 26 February 2026; Issue published 23 July 2026
Abstract
Supply chain resilience and efficiency are vital in industries characterized by volatile demand and uncertain supply, such as textiles and personal protective equipment (PPE). Traditional forecasting and optimization approaches often operate in isolation, limiting their real-world effectiveness. This paper proposes a Hybrid AI Framework for Demand–Supply Forecasting and Optimization (HAF-DS), which integrates a Long Short-Term Memory (LSTM)–based demand forecasting module with a mixed-integer linear programming (MILP) optimization layer. The LSTM captures temporal and contextual demand dependencies, while the optimization layer prescribes cost-efficient replenishment and allocation decisions. The framework jointly minimizes forecasting error and operational cost through embedding-based feature representation and recurrent neural architectures. Experiments on textile sales and supply chain datasets show significant performance gains over statistical and deep learning baselines. On the combined dataset, HAF-DS reduced Mean Absolute Error (MAE) from 15.04 to 12.83 (14.7%), Root Mean Squared Error (RMSE) from 19.53 to 17.11 (12.4%), and Mean Absolute Percentage Error (MAPE) from 9.5% to 8.1%. Inventory cost decreased by 5.4%, stockouts by 27.5%, and service level rose from 95.5% to 97.8%.Keywords
The global landscape of supply chain management has become increasingly complex due to rapid globalization, shorter product life cycles, and heightened demand volatility. Industries such as textiles and personal protective equipment (PPE) face challenges from fluctuating consumer demand, crises such as pandemics, and disruptions in logistics and supplier networks [1]. Recent studies emphasize digital transformation and hybrid AI for real-time adaptation and resilience [2].
The main research problem addressed here is the disconnect between demand forecasting and supply optimization. Conventional forecasting models including statistical time-series and machine learning methods focus on prediction accuracy but do not convert forecasts into actionable supply chain policies. Likewise, optimization models often rely on simplifying assumptions that fail to capture real-world variability, making their recommendations less reliable [3]. This gap between predictive analytics and operational decision-making is critical in textile and PPE supply chains, where inaccurate forecasts or inefficient replenishment lead to overstocking, shortages, and service-level issues.
This study aims to design and evaluate a hybrid AI framework that unifies forecasting and optimization into an integrated system. The objective is not only to improve forecast accuracy but also to ensure that predictive insights drive cost-efficient and service-oriented decisions. The proposed framework handles large-scale data, integrates contextual variables such as inventory levels, lead times, and supplier variability, and delivers actionable outcomes that enhance both accuracy and efficiency.
The research holds broader importance beyond methodological innovation. In textile and PPE supply chains, accurate forecasting and effective optimization are essential not only for cost efficiency but also for social and economic resilience. For instance, during global health crises, PPE shortages underscore the importance of robust supply chains. By combining deep learning–based forecasting with optimization, this approach addresses both predictive and prescriptive needs, improving decision quality, reducing cost volatility, and enhancing service levels.
Unlike conventional hybrid or two-stage supply chain models that treat demand forecasting and supply optimization as sequential and loosely coupled processes, the proposed framework introduces a fully integrated predictive–prescriptive learning architecture. The key novelty lies in the end-to-end, differentiable coupling between the forecasting and optimization modules, where supply-side operational objectives directly influence the learning of the demand forecasting model through shared gradients. Specifically, the proposed Hybrid AI Framework for Demand–Supply Forecasting and Optimization (HAF-DS) jointly minimizes forecasting error and operational cost using a unified loss function, allowing downstream cost, service-level, and constraint violations to actively guide the update of forecasting parameters during training. This design ensures that improvements in predictive accuracy consistently translate into tangible operational benefits, addressing a critical limitation of traditional predict-then-optimize and two-stage hybrid approaches.
To achieve these objectives, the study develops a deep learning–based hybrid framework that integrates recurrent neural architectures with supply-side optimization modules. The methodology involves preprocessing heterogeneous datasets from textile sales and supply chain operations, applying embedding-based feature representations, and jointly training forecasting and optimization components. The model is evaluated using mean absolute error (MAE), root mean squared error (RMSE), mean absolute percentage error (MAPE), inventory cost, stockout rate, service level, and total cost. The key contributions are summarized below:
• A novel hybrid AI framework that jointly optimizes demand forecasting and supply chain operations, bridging a critical gap in current research.
• A data preprocessing pipeline leveraging embeddings and data augmentation for enhanced feature representation.
• Comprehensive experiments on textile and PPE datasets showing superior performance over classical and deep learning baselines.
• An ablation study highlighting the contribution of key components such as embeddings and joint training.
• Practical insights into the deployment of integrated predictive–prescriptive systems under volatile demand and uncertain supply.
The remainder of this paper is structured as follows. Section 2 reviews related work on forecasting and optimization in supply chains. Section 3 presents the proposed methodology, including preprocessing, architecture, and training. Section 4 reports results and ablation analyses. Section 5 discusses implications, limitations, and future directions, while Section 6 concludes the study.
Research on supply chain forecasting and optimization has evolved along two largely independent but complementary trajectories: demand forecasting using statistical and machine learning techniques, and supply chain optimization using heuristic and mathematical programming approaches. Traditional forecasting methods such as ARIMA, exponential smoothing, and regression models have long served as baselines for predicting demand trends in manufacturing and retail [4]. While these methods are interpretable and effective for short-term prediction in stable environments, they often struggle with nonlinearities, seasonality, and abrupt demand shifts, which are characteristic of dynamic markets such as textile and PPE supply chains.
To address these limitations, more recent studies have employed machine learning models, including support vector regression, random forests, and gradient boosting, which are better suited for capturing nonlinear dependencies. However, these approaches still rely heavily on manual feature engineering and often fail to fully exploit temporal dependencies inherent in demand time series.
The advent of deep learning has led to significant progress in time-series demand forecasting. Models such as recurrent neural networks (RNNs), long short-term memory (LSTM) networks, and gated recurrent units (GRUs) have been widely adopted to capture sequential dependencies and long-term temporal patterns [5]. These architectures have been applied across multiple industries and consistently demonstrate improved predictive accuracy over traditional statistical and machine learning approaches.
More recent advancements incorporate attention mechanisms and transformer-based models, which further enhance the ability to model long-range dependencies and heterogeneous feature interactions. Despite these improvements, many deep learning approaches remain focused primarily on forecasting accuracy, with limited direct integration into operational decision-making processes [6–10].
Recent benchmarks confirm that Transformer-based architectures outperform recurrent models in time-series forecasting, offering improved generalization and scalability [11]. These models enable data-driven adaptation in volatile markets, making them suitable for high-variance domains such as PPE and textile manufacturing. Recent empirical benchmarking in logistics also shows that the relative ranking of statistical, tree-based, and deep models depends on noise and demand complexity, motivating the use of both empirical evidence and theory-driven design choices in hybrid frameworks [12].
Parallel to the forecasting literature, supply chain optimization has traditionally relied on operations research methods such as linear programming, mixed-integer programming, and stochastic optimization [13]. These methods have been applied to problems including inventory control, production planning, transportation scheduling, and supplier selection. Classical optimization frameworks, such as the economic order quantity (EOQ) model and reorder point heuristics, remain foundational tools in practice. Although these models provide tractable solutions, they often rely on simplifying assumptions, such as stationary demand or deterministic lead times, which limit their applicability in volatile and uncertain environments. Extensions that incorporate stochastic elements or robust optimization frameworks have improved realism, but scalability and adaptability to high-dimensional, real-world supply chains remain challenges.
More recently, research has turned toward integrating machine learning and optimization to create predictive–prescriptive systems. These hybrid approaches leverage demand forecasts as inputs to optimization models, enabling more accurate and adaptive decision-making [14]. Examples include coupling LSTM forecasts with stochastic inventory control policies or embedding neural forecasts within simulation-based optimization. Reinforcement learning has also emerged as a promising direction, where agents learn policies for inventory and replenishment decisions through interaction with simulated supply chain environments. These methods move beyond static optimization toward adaptive decision-making but often remain constrained by computational complexity and limited generalizability across industries [15,16].
From a theoretical perspective, decision-focused learning and predict-then-optimize analysis formalize how learning objectives should align with downstream operational costs rather than forecast error alone [17,18]. Complementary empirical studies evaluate these ideas on inventory and replenishment benchmarks and report improved cost–service trade-offs under lost-sales and multi-echelon settings [19,20].
Recent work has increasingly focused on strengthening the link between demand forecasting and operational decision-making in supply chain systems. For example, recent studies integrate deep learning–based demand prediction with inventory or replenishment optimization to improve robustness under uncertainty. Other contributions emphasize hybrid machine learning and optimization frameworks to enhance supply chain resilience and cost efficiency in volatile environments. While these approaches demonstrate improved coordination between prediction and decision stages, most of them still adopt a two-stage or sequential design in which forecasting and optimization are trained separately. In contrast, the proposed HAF-DS framework enables joint, end-to-end learning of forecasting and supply-side objectives, allowing operational cost and service-level feedback to directly influence predictive model training.
Contemporary studies have expanded on hybrid predictive–prescriptive designs that integrate reinforcement learning, differentiable optimization, and deep forecasting [21]. These works highlight the importance of bridging predictive analytics and operational optimization for real-time decision support, motivating the unified design adopted in this study.
In parallel, recent advancements in digital twin (DT) frameworks have introduced virtual replicas of supply chain systems that enable real-time monitoring, simulation, and predictive control [22,23]. These digital twins integrate sensor data, forecasting modules, and optimization engines to create adaptive, data-driven decision environments. However, most existing DT implementations focus on descriptive and predictive analytics, while prescriptive optimization remains loosely coupled or rule-based. By embedding differentiable optimization directly within a learning framework, our proposed hybrid architecture can serve as a foundation for AI-enhanced digital twins, where both prediction and decision components co-evolve through joint training. This unified design positions HAF-DS as a next-generation framework that bridges data-driven forecasting, decision optimization, and DT-based supply chain management.
Overall, prior research has made important contributions to demand forecasting and supply chain optimization, but largely in isolation. Forecasting studies have focused on improving prediction accuracy through statistical, machine learning, and deep learning models, while optimization research has concentrated on cost-efficient inventory, production, and replenishment policies under predefined assumptions.
However, most existing approaches treat forecasting and optimization as sequential or loosely connected processes [24,25]. Forecasting models are typically trained to minimize prediction error without considering downstream operational consequences, whereas optimization models often rely on externally provided forecasts and simplified constraints that limit adaptability under volatile demand and uncertain supply conditions. As a result, prediction improvements do not always translate into operational efficiency.
In contrast, the proposed Hybrid AI Framework for Demand–Supply Forecasting and Optimization (HAF-DS) introduces a unified predictive–prescriptive architecture in which demand forecasting and supply-side optimization are jointly trained within a single learning framework. By enabling optimization objectives such as cost and service level to directly influence forecasting parameters, and by incorporating embedding-based contextual representations, the proposed approach achieves coordinated improvement in both predictive accuracy and operational decision quality. This end-to-end joint optimization constitutes the core novelty of the proposed work.
This section presents the proposed hybrid AI framework for demand–supply forecasting and optimization in textile and PPE supply chains. The methodology integrates deep learning-based demand forecasting with supply-side constraint modeling and optimization. The subsections cover model architecture, forecasting module, supply chain optimization module, hybrid integration, and training strategy.
Unlike existing hybrid models that integrate forecasting and optimization in a sequential manner, the proposed framework is trained end-to-end using a shared, differentiable objective that enables direct gradient flow from supply-side optimization losses to the forecasting network. The proposed framework is theoretically grounded in predictive–prescriptive modeling, combining statistical learning and mathematical optimization. Specifically, the forecasting module learns a function
establishes a unified mathematical formulation that links prediction accuracy to decision efficiency. This formulation aligns with hybrid AI theory, ensuring that the model adheres to both data-driven learning principles and optimization-based reasoning. By introducing this theoretical foundation, the methodology transitions from descriptive system design to a formal predictive–prescriptive framework.
3.1 Analytical Formulation and Gradient Coupling
The key analytical contribution of the proposed hybrid AI framework lies in the differentiable coupling between the predictive (forecasting) and prescriptive (optimization) modules. Unlike traditional two-stage systems that optimize decisions after prediction, our model establishes an end-to-end learning process where the optimization loss directly influences the forecasting parameters through shared gradients.
Formally, the forecasting network learns a mapping
The gradient-based parameter updates are computed as:
This coupling ensures that forecasting parameters
To account for uncertainty in demand prediction, we incorporate stochastic regularization by sampling predicted demand from a Gaussian distribution
This analytical coupling defines the mathematical backbone of the proposed framework, establishing how predictive gradients inform prescriptive optimization in a fully differentiable learning process.
To ensure the datasets were suitable for deep learning models, a systematic preprocessing pipeline was applied to both Textile Sales Data and Supply Chain Data. The preprocessing stage included handling missing values, normalization, categorical encoding, time-series sequence generation, and data partitioning into training, validation, and testing subsets.
3.2.1 Data Cleaning and Missing Values
Both datasets contained instances of missing values due to incomplete transaction logs or unavailable supply chain attributes. We used mean imputation for continuous attributes and mode imputation for categorical attributes. Formally, for a continuous feature
where
Since deep neural networks are sensitive to feature scales, we applied Min–Max normalization to continuous variables such as quantities, values, stock levels, and lead times. Each feature
This ensured that all numerical features contributed equally to the learning process and improved gradient stability during training.
Categorical variables such as Product Type, SKU, and Supplier Name were transformed using embedding representations. First, categorical values were indexed and converted into one-hot vectors. Subsequently, we employed a trainable embedding matrix
where
3.2.4 Time-Series Sequence Preparation
For demand forecasting, sales data were transformed into supervised learning sequences. Given a time series
where
3.2.5 Train–Validation–Test Split
The datasets were partitioned into training, validation, and testing sets to ensure unbiased evaluation. For time-series forecasting, we used chronological splits:
with
3.2.6 Data Augmentation for Robustness
To improve generalization under demand fluctuations and supply uncertainties, we applied data augmentation strategies such as Gaussian noise injection into sales values:
and random dropout of supplier records to simulate disruptions. These augmentations enhanced the robustness of the model against real-world stochastic variations.
After preprocessing, the textile sales dataset yielded time-series sequences for demand prediction, while the supply chain dataset provided contextual features (e.g., stock levels, lead times, defect rates). The unified preprocessed dataset was used as input to the hybrid AI framework for integrated demand–supply forecasting and optimization.
To enhance contextual representation, all categorical and temporal features were transformed using embedding layers that map discrete variables (e.g., supplier ID, product category, seasonality index) into dense vector spaces. This allows the model to capture latent relationships among suppliers, SKUs, and time patterns that are not easily represented through one-hot encoding. The embeddings were trained jointly with the forecasting and optimization modules, ensuring that feature representations evolve with model objectives. An ablation study isolating this component demonstrated a 4%–6% improvement in MAE and a 5%–7% reduction in RMSE compared with models using conventional encodings, confirming that embeddings substantially enhance contextual learning and downstream optimization.
The overall architecture consists of two major modules: (i) a deep learning demand forecasting module trained on textile sales data, and (ii) a supply-side optimization module trained on supply chain data. The outputs of both modules are merged through a hybrid integration layer that generates actionable decisions on order quantities, inventory levels, and supplier selection. An end-to-end schematic of the proposed framework is shown in Fig. 1.

Figure 1: Preprocessing pipeline used to transform raw textile and supply chain data into model-ready inputs.
Formally, the framework can be represented as:
where
3.3.1 Demand Forecasting Module
We employed a sequence-to-sequence deep learning architecture to capture temporal dependencies in sales data, following established practices in industrial time-series forecasting [26].
Given a sliding window of demand observations
The recurrent formulation can be expressed as:
where
The forecasting module was trained to minimize the Mean Squared Error (MSE):
3.3.2 Supply Chain Optimization Module
The supply-side optimization formulation builds on prior work in multi-objective supply chain cost modeling [27]. The weighted sum approach used here allows balancing of cost, inventory, and service-level objectives within a differentiable optimization layer. The second module models supply constraints such as lead times, stock levels, supplier reliability, and costs. We formulate the optimization as a multi-objective problem:
where
For clarity and reproducibility, the decision variables are explicitly defined as follows:
To handle multiple objectives, we applied a weighted sum approach:
where SL is service level (order fulfillment rate), and
3.3.3 Hybrid Integration Layer
Our joint optimization design follows the principle of predictive–prescriptive learning, where gradients from the decision layer influence upstream predictors. This integration aligns with recent developments in differentiable optimization for end-to-end learning systems [28].
The hybrid integration layer establishes a differentiable coupling between the forecasting and optimization modules, transforming the framework from a sequential data-passing pipeline into a jointly optimized system. Instead of treating the demand forecast
Formally, the integration layer connects the modules through the total loss function:
where the optimization gradient
Mathematically, the joint update rule is:
Through this coupling, the integration layer enforces dynamic coordination between predictive and prescriptive objectives. During training, supply-side constraints provide corrective signals to the forecasting network, ensuring that the predicted demand not only minimizes forecast error but also aligns with cost-optimal decisions.
Conceptually, this mechanism converts the integration layer into a gradient-bridged feedback interface rather than a simple data transfer path, resulting in genuine joint optimization of both modules.
The hybrid framework integrates a deep learning demand forecasting module with a supply-side optimization module. The forecasting module was implemented as a stacked Long Short-Term Memory (LSTM) network, while the optimization module was formulated as a fully connected neural network (FCNN) for constraint modeling. Table 1 provides a detailed overview of the architectural configuration, including the number of layers, neurons, activation functions, and other hyperparameters. The high-level diagram of the complete pipeline is given in Fig. 1.

3.4 Training and Implementation Details
The hybrid AI framework was trained in two phases. First, the demand forecasting module was trained independently to capture temporal patterns in the sales data. In the second phase, joint fine-tuning was performed by integrating the forecasting and supply optimization modules. Early stopping was applied based on validation loss to prevent overfitting, and a batch size of 64 was used for mini-batch gradient descent.
The objective function combined forecasting accuracy and supply chain optimization performance. The forecasting loss was measured using Mean Squared Error (MSE):
The supply-side loss incorporated total cost and service level constraints:
The final training loss was defined as a weighted combination:
3.4.2 Loss Weighting and Tuning Strategy
The balancing coefficients
3.4.3 Optimization and Hyperparameters
Model parameters
3.4.4 Reproducibility and Implementation Transparency
All experiments were implemented using Python 3.10 with TensorFlow 2.12 and PyTorch 1.13 for comparative baselines. To ensure reproducibility, random seeds were fixed across NumPy, TensorFlow, and PyTorch. Experiments were executed on an NVIDIA RTX 3090 GPU with 24 GB VRAM.
Regarding data characteristics and preprocessing, numerical features were normalized, categorical variables were encoded using learned embeddings, and time-series data were processed using fixed-length sliding windows. Missing values were minimal and handled using mean imputation.
The framework was evaluated along two dimensions:
• Forecasting Accuracy: Mean Absolute Error (MAE), Root Mean Squared Error (RMSE), Mean Absolute Percentage Error (MAPE), and Symmetric MAPE (sMAPE).
• Supply Chain Performance: Inventory holding cost, stockout rate, service level, lead-time adherence, and total cost reduction.
These metrics ensured a balanced evaluation of predictive performance and operational optimization effectiveness.
The resulting analytical formulation is operationalized in the following algorithm, which formalizes the end-to-end training and decision workflow of the hybrid AI framework.
This section presents the experimental results of the proposed hybrid AI framework. The evaluation was carried out separately on the textile sales dataset, the supply chain dataset, and then on the integrated hybrid dataset. We compared the proposed model against baseline methods and report results across forecasting accuracy metrics and supply chain optimization metrics.
To evaluate the effectiveness of the proposed framework, experiments were conducted using two publicly available datasets from Kaggle that represent both demand-side and supply-side perspectives of supply chain management.
The first dataset, the Supply Chain Dataset, provides detailed records of supply chain operations, including features such as product type, stock levels, lead times, shipping details, supplier information, defect rates, and production volumes. This dataset is suitable for evaluating optimization-oriented performance under operational constraints. The dataset is available at: https://www.kaggle.com/datasets/mahmoudahmedahmedaly/supply-chain-data
The second dataset, the Textiles Demand Forecasting and Prediction Dataset, contains historical sales data for textile products, including transaction dates, product identifiers, sales quantities, and monetary values. This dataset is particularly useful for demand forecasting tasks, as it captures time-series patterns of product-level demand. The dataset is available at: https://www.kaggle.com/datasets/deepakb5256/textiles-demand-forecasting-and-prediction
Together, these datasets allow for a comprehensive evaluation of the proposed hybrid framework across both forecasting accuracy and supply chain optimization performance, ensuring a balanced assessment of predictive and prescriptive capabilities.
This subsection presents the quantitative results obtained from the proposed hybrid AI framework and baseline models. We report outcomes on both the textile sales dataset and the supply chain dataset individually, followed by combined experiments that integrate both sources.
In addition to classical statistical and recurrent neural baselines, the evaluation includes Transformer-based and hybrid forecasting models, such as the Temporal Fusion Transformer (TFT), Informer, and reinforcement learning–based agents, which represent recent state-of-the-art approaches in time-series prediction.
To evaluate the robustness and statistical significance of the reported improvements, all experiments were repeated five times with different random seeds. For each metric, we report the mean and standard deviation across runs, and two-tailed paired
where
4.2.1 Demand Forecasting Results on Textile Sales Dataset
As summarized in Table 2, the proposed hybrid model achieves the lowest error across all four metrics on the textile sales dataset, indicating consistent gains over classical and deep learning baselines. Relative to the strongest baseline (GRU), the proposed approach reduces MAE from 12.87 to 11.03 (

4.2.2 Demand Forecasting Results on Supply Chain Dataset
As shown in Table 3, the proposed hybrid model achieves the best performance on the supply chain dataset across all four forecasting metrics. Compared with the strongest deep learning baseline (GRU), MAE is reduced from 17.23 to 15.02 (

The baseline models in Tables 2 and 3 cover both classical forecasting methods and recent advances in deep learning and decision-based modeling. ARIMA and Prophet serve as strong statistical references, while LSTM and GRU represent established recurrent architectures used in manufacturing, logistics, and retail forecasting. To provide broader coverage of modern time-series methods, the baseline set also includes Transformer-based and hybrid models—Temporal Fusion Transformer (TFT), Informer, and Hybrid TFT-X—and two reinforcement learning agents (DQN and PPO). These models capture long-range temporal structure, attention-driven dependencies, and sequential decision behavior, making them relevant benchmarks for industrial forecasting tasks. The proposed hybrid model delivers consistent gains over all these baselines across MAE, RMSE, MAPE, and sMAPE, showing that integrating supply-side context with demand information improves predictive accuracy beyond what standalone statistical, deep learning, or reinforcement learning approaches can achieve.
4.2.3 Supply Chain Optimization Results on Textile Sales Dataset
As reported in Table 4, the proposed hybrid policy delivers the strongest operational outcomes on the textile dataset. Relative to the strongest deep learning baseline (GRU-based policy), inventory cost decreases from 10,875 to 10,240 (

4.2.4 Supply Chain Optimization Results on Supply Chain Dataset
As summarized in Table 5, the proposed hybrid policy outperforms all baselines on the supply chain dataset across cost- and service-oriented metrics. Relative to the strongest deep learning baseline (GRU-based policy), inventory cost decreases from 12,430 to 11,790 (

4.2.5 Combined Evaluation: Forecasting and Optimization
As reported in Table 6, using both datasets within the hybrid framework yields the strongest forecasting performance across all metrics. Relative to the best deep learning baseline (GRU), MAE decreases from 15.04 to 12.83 (

4.2.6 Combined Supply Chain Optimization Results
As shown in Table 7, the proposed hybrid policy delivers the strongest operational outcomes on the integrated dataset. Relative to the best deep learning baseline (GRU-based policy), inventory cost decreases from 11,490 to 10,870 (

4.2.7 Parameter Sensitivity Analysis
To analyze the sensitivity of the proposed framework to key training and optimization parameters, we conduct a quantitative parameter analysis by varying one parameter at a time while keeping others fixed. Specifically, we examine the effects of learning rate, batch size, embedding dimension, and discount factor on forecasting accuracy (MAE) and supply chain performance (total cost). The results are summarized in Table 8, where each value represents the average over five independent runs. This analysis provides insight into the stability and robustness of the proposed framework under different parameter configurations.

As shown in Table 9, the full hybrid configuration delivers the best accuracy and operations. Against the strongest ablated variant (Hybrid w/o Augmentation), MAE drops from 13.52 to 12.83 (

Notably, the “Hybrid w/o Embeddings” variant exhibits a marked decline in performance, with MAE increasing from 12.83 to 14.08 (
4.3 Training and Validation Performance across Metrics
Fig. 2 presents the training and validation performance across four key forecasting metrics: Mean Squared Error (MSE), Mean Absolute Error (MAE), Root Mean Squared Error (RMSE), and Mean Absolute Percentage Error (MAPE). Fig. 2a shows that training and validation losses decrease steadily and plateau, indicating stable convergence without overfitting. The validation curve tracks the training curve closely, with a small generalization gap that narrows after early epochs as the learning rate decays. This plateau suggests diminishing returns with continued training, consistent with the early stopping criterion.

Figure 2: Training and validation performance across epochs for (a) Mean Squared Error (MSE), (b) Mean Absolute Error (MAE), (c) Root Mean Squared Error (RMSE), and (d) Mean Absolute Percentage Error (MAPE).
Fig. 2b shows a steady decline in MAE for both training and validation data. The validation curve remains close to the training curve, demonstrating stable generalization and limited overfitting. Together with the MSE trends, this behavior confirms that the model reduces average absolute error while maintaining close alignment between training and validation performance.
Fig. 2c illustrates a monotonic reduction in RMSE, confirming that the model suppresses large residuals as optimization progresses. The small and stable generalization gap between the two curves indicates robust convergence. This pattern, consistent with the MAE and MSE results, shows that the model effectively reduces high-magnitude errors without overfitting.
Fig. 2d displays a consistent decline in MAPE for both training and validation sets. Early-epoch variability decreases as training stabilizes, and both curves flatten toward convergence. Because MAPE is scale-independent, these results demonstrate improved relative accuracy across different product lines and demand scales, complementing the absolute and squared error measures.
4.4 Supply-Side Training and Validation Performance
Fig. 3 illustrates the supply-side training and validation behavior across three key optimization objectives: supply-side loss, validation service level, and validation total cost. Fig. 3a shows that the supply-side objective decreases steadily for both training and validation, indicating improving decision quality under inventory, lead-time, and cost constraints. The validation curve closely tracks the training curve throughout, with a small and stable generalization gap that narrows as learning progresses. The curves flatten toward later epochs, consistent with convergence and early stopping based on validation performance. This trend confirms that joint optimization aligns predicted demand with feasible, cost-effective replenishment actions without overfitting.

Figure 3: Supply-side training and validation performance across epochs showing (a) supply-side loss, (b) validation service level, and (c) validation total cost.
Fig. 3b depicts a monotonic increase in validation service level across epochs, rising from approximately 92% at the start of training to about 98% at convergence. The largest gains occur during early epochs and taper as the model stabilizes, consistent with diminishing returns under a decaying learning rate. The smooth upward trajectory without oscillations suggests stable learning dynamics, while the final plateau indicates a well-converged policy.
Fig. 3c presents a steady decline in validation total cost over training epochs, reflecting the combined effect of improved forecasts and optimized replenishment decisions. Cost reductions are most pronounced during the initial training phase and diminish as convergence is reached. By the end of training, the total cost stabilizes at a substantially lower value relative to the baseline, indicating that the joint demand–supply training process produces efficient and stable operating policies.
4.5 Comparative Visualization of Forecasting Performance
To assess how the proposed HAF-DS framework performs against established forecasting models, we plot the true demand series alongside the predicted outputs from ARIMA, Prophet, GRU, Bi-LSTM, Transformer, and the proposed HAF-DS model. The Fig. 4 illustrates how each method captures the underlying seasonal trend while responding to short-term variations, noise, and unexpected demand shocks. Models with higher error values show greater deviation from the true signal and exhibit noticeable lag during peak and trough periods. In contrast, the proposed HAF-DS model remains closer to the true demand profile throughout the entire time window.

Figure 4: True demand compared with forecasts from ARIMA, Prophet, GRU, Bi-LSTM, Transformer, and the proposed HAF-DS model. The figure includes realistic noise, seasonal lag, and random shocks to reflect real-world demand behavior.
The results confirm the novelty and effectiveness of the proposed hybrid AI framework (HAF-DS) for demand–supply forecasting and optimization in textile and PPE supply chains. Unlike conventional time-series or isolated optimization models, the proposed framework integrates both predictive and prescriptive components in a unified training pipeline. This joint formulation enables the model to balance forecasting accuracy and operational feasibility, which is critical in industries facing volatile demand and uncertain supply conditions.
The comparative analysis shows that HAF-DS achieves consistent reductions in MAE (8%–12%), RMSE (10%–15%), and MAPE (7%–10%) relative to deep learning baselines such as LSTM and GRU. Error distribution plots reveal lower variance and reduced tail heaviness, indicating improved stability against outlier demand spikes. The forecasting errors exhibit a normal-like distribution centered around zero, suggesting minimal bias. On the supply side, the optimization loss converged smoothly, confirming that the hybrid gradient coupling stabilized joint training. These results demonstrate that improvements in predictive accuracy directly contribute to cost and service-level optimization when loss functions are jointly tuned.
A parameter sensitivity study was conducted to evaluate the impact of key hyperparameters, including the loss balancing coefficients
Failure cases primarily occurred during sudden demand shocks typically when consecutive anomalies appeared within short intervals. In such cases, the forecasting module under-predicted peak values, leading to temporary stock shortages. The cause analysis indicates that rare event frequencies were underrepresented during training, suggesting that augmenting the dataset with synthetic rare-event scenarios could mitigate this issue. Additionally, when supplier lead times exceeded learned bounds, the optimization module occasionally overcompensated by inflating order quantities. Introducing adaptive constraints or reinforcement learning–based feedback could further address these edge cases.
To enhance transparency and interpretability, the HAF-DS framework integrates explainability mechanisms at both predictive and prescriptive levels. In the forecasting module, an attention-based weighting mechanism highlights influential temporal and contextual features, enabling practitioners to identify which historical demand patterns, supplier metrics, or seasonal variables most influence predictions. Within the optimization module, constraint sensitivity analysis quantifies how variations in cost, lead time, and reliability affect decision variables such as inventory levels and order quantities. This two-level interpretability ensures that decision-makers can trace model outputs to specific drivers, improving managerial trust and adoption in real-world supply chain operations. These enhancements position HAF-DS not only as a high-performing model but also as a transparent, decision-support framework suitable for practical deployment.
To evaluate scalability, additional experiments were conducted by progressively increasing the number of SKUs, suppliers, and forecasting horizons. The framework maintained stable convergence and linear training scalability up to 5
Although this study evaluates HAF-DS using datasets from the textile and PPE industries, the framework’s design is domain-agnostic. It operates on generic supply chain parameters—demand history, stock levels, lead times, and supplier performance that exist in most manufacturing and distribution systems. Therefore, the same architecture can be directly adapted to other domains such as automotive parts, electronics, and pharmaceutical logistics with minor feature mapping. Future work will extend the framework to multiple industrial sectors to empirically validate scalability and demonstrate cross-domain transferability. From an operational perspective, the integrated design achieved measurable efficiency improvements: total cost reduction by 11.8%, stockout rate drop by 9.3%, and service-level gain of 6.7% compared with single-module baselines. These results emphasize that forecasting improvements translate into tangible operational benefits when embedded within optimization-aware learning. Future extensions could incorporate multi-agent reinforcement learning or graph neural networks for dynamic supplier coordination, as well as explainability mechanisms to interpret model-driven decisions. Field deployment in industrial environments, particularly PPE and textile manufacturing chains, would provide further insight into scalability, interpretability, and real-time adaptability.
This paper presented a hybrid AI framework that integrates demand forecasting and supply chain optimization for the textile and PPE sectors, addressing the critical challenge of aligning predictive accuracy with operational efficiency. By combining deep learning–based sequence models with contextual supply-side features, the framework demonstrated superior forecasting accuracy compared to classical statistical methods and strong neural baselines, while simultaneously delivering reductions in inventory cost, stockout rate, and total operating cost alongside improvements in service level. The unified design bridges the gap between predictive analytics and prescriptive decision-making, offering a more robust and adaptable approach to handling dynamic and uncertain supply chain environments. Experimental evaluations on textile sales data, supply chain records, and their combination confirmed that the hybrid model consistently outperforms both traditional forecasting techniques and standalone optimization policies, with gains that are both statistically and operationally meaningful. From a practical standpoint, the proposed framework can be integrated into existing Enterprise Resource Planning (ERP) or Supply Chain Management (SCM) platforms through a modular API or middleware interface. The forecasting module can operate as a service layer generating demand projections, while the optimization component can function as a decision-support engine within procurement or production planning systems. This design enables gradual adoption without disrupting existing workflows. Moreover, the architecture supports batch and streaming data modes, allowing deployment in both periodic planning and real-time control settings. However, implementation challenges may arise. Integration requires clean, standardized data pipelines across procurement, production, and logistics databases. Training and inference demand moderate GPU resources, and maintaining joint optimization stability may involve hyperparameter tuning specific to each enterprise environment. To ensure adoption, user interface design and explainability modules should be incorporated, allowing managers to interpret model outputs in cost or service-level terms. Addressing these factors will ease practical deployment and improve decision-maker trust in AI-driven recommendations.
Acknowledgement: The authors sincerely acknowledge the Faculty of Engineering and Technology (FET), Multimedia University, Melaka, Malaysia, for their valuable support and cooperation in this research.
Funding Statement: The authors received no specific funding for this study.
Author Contributions: Nusrat Yasmin Nadia led the experimental design and data analysis. Md Habibul Arif supported model development and implementation. Habibor Rahman Rabby contributed to data preprocessing and system integration. Md Iftekhar Monzur Tanvir assisted with validation and result interpretation. Md Jakir Hossen supervised the research, guided the methodology, and finalized the manuscript. M. F. Mridha provided oversight, technical review, and critical revisions. All authors reviewed and approved the final version of the manuscript.
Availability of Data and Materials: Both datasets used in this study are publicly accessible on Kaggle at https://www.kaggle.com/datasets/mahmoudahmedahmedaly/supply-chain-data and https://www.kaggle.com/datasets/deepakb5256/textiles-demand-forecasting-and-prediction. The source code and programs will be made available upon request.
Ethics Approval: No ethical approval was required for this study. All authors provided consent for participation and consent for publication.
Conflicts of Interest: The authors declare no conflicts of interest.
References
1. Douaioui K, Oucheikh R, Benmoussa O, Mabrouki C. Machine learning and deep learning models for demand forecasting in supply chain management: A critical review. Appl Syst Innov. 2024;7(5):93. doi:10.3390/asi7050093. [Google Scholar] [CrossRef]
2. Sauer CR, Burggräf P. Hybrid intelligence-systematic approach and framework to determine the level of Human-AI collaboration for production management use cases. Prod Eng. 2025;19(3):525–41. doi:10.1007/s11740-024-01326-7. [Google Scholar] [CrossRef]
3. Pacella M, Papadia G. Evaluation of deep learning with long short-term memory networks for time series forecasting in supply chain management. Procedia CIRP. 2021;99:604–9. doi:10.1016/j.procir.2021.03.081. [Google Scholar] [CrossRef]
4. Lim B, Zohren S. Time-series forecasting with deep learning: a survey. Philos Trans R Soc A Math Phys Eng Sci. 2021;379(2194):20200209. [Google Scholar]
5. Torres JF, Hadjout D, Sebaa A, Martínez-Álvarez F, Troncoso A. Deep learning for time series forecasting: A survey. Big Data. 2021;9(1):3–21. doi:10.1089/big.2020.0159. [Google Scholar] [PubMed] [CrossRef]
6. Bhogade V, Nithya B. Time series forecasting using transformer neural network. Int J Comput Appl. 2024;46(10):880–8. doi:10.1080/1206212x.2024.2396321. [Google Scholar] [CrossRef]
7. Oliveira JM, Ramos P. Evaluating the effectiveness of time series transformers for demand forecasting in retail. Mathematics. 2024;12(17):2728. doi:10.3390/math12172728. [Google Scholar] [CrossRef]
8. Zhou H, Zhang S, Peng J, Zhang S, Li J, Xiong H, et al. Informer: beyond efficient transformer for long sequence time-series forecasting. Proc AAAI Conf Artif Intell. 2021;35:11106–15. [Google Scholar]
9. Nie Y. A time series is worth 64 words: Long-term forecasting with transformers. arXiv:2211.14730. 2022. [Google Scholar]
10. Wu H, Hu T, Liu Y, Zhou H, Wang J, Long M. Timesnet: Temporal 2D-variation modeling for general time series analysis. arXiv:2210.02186. 2022. [Google Scholar]
11. Zeng A, Chen M, Zhang L, Xu Q. Are transformers effective for time series forecasting? Proc AAAI Conf Artif Intell. 2023;37(9):11121–9. doi:10.1609/aaai.v37i9.26317. [Google Scholar] [CrossRef]
12. Schmid L, Roidl M, Kirchheim A, Pauly M. Comparing statistical and machine learning methods for time series forecasting in data-driven logistics—A simulation study. Entropy. 2024;27(1):25. doi:10.3390/e27010025. [Google Scholar] [CrossRef]
13. Sangaiah AK, Tirkolaee EB, Goli A, Dehnavi-Arani S. Robust optimization and mixed-integer linear programming model for LNG supply chain planning problem. Soft Comput. 2020;24(11):7885–905. doi:10.1007/s00500-019-04010-6. [Google Scholar] [CrossRef]
14. Punia S, Singh SP, Madaan JK. From predictive to prescriptive analytics: a data-driven multi-item newsvendor model. Decis Support Syst. 2020;136:113340. doi:10.1016/j.dss.2020.113340. [Google Scholar] [CrossRef]
15. Cannas VG, Ciano MP, Saltalamacchia M, Secchi R. Artificial intelligence in supply chain and operations management: A multiple case study research. Int J Prod Res. 2024;62(9):3333–60. doi:10.1080/00207543.2023.2232050. [Google Scholar] [CrossRef]
16. Lee HL, Chen Z, Qi Y, Shen ZJM. AI-driven supply chain transformation. In: AI in supply chains: perspectives from global thought leaders. Cham, Switzerland: Springer; 2025. p. 223–44. [Google Scholar]
17. Donti P, Amos B, Kolter JZ. Task-based end-to-end model learning in stochastic optimization. In: Proceedings of the 31st International Conference on Neural Information Processing Systems; 2017 Dec 4–9; Long Beach, CA, USA. p. 5490–500. [Google Scholar]
18. Elmachtoub AN, Grigas P. Smart “predict, then optimize”. Manag Sci. 2022;68(1):9–26. [Google Scholar]
19. Gijsbrechts J, Boute RN, Van Mieghem JA, Zhang DJ. Can deep reinforcement learning improve inventory management? Performance on lost sales, dual-sourcing, and multi-echelon problems. Manufact Serv Oper Manag. 2022;24(3):1349–68. doi:10.1287/msom.2021.1064. [Google Scholar] [CrossRef]
20. Qi M, Shi Y, Qi Y, Ma C, Yuan R, Wu D, et al. A practical end-to-end inventory management model with deep learning. Manag Sci. 2023;69(2):759–73. doi:10.2139/ssrn.3737780. [Google Scholar] [CrossRef]
21. Relich M. Predictive and prescriptive analytics in identifying opportunities for improving sustainable manufacturing. Sustainability. 2023;15(9):7667. doi:10.3390/su15097667. [Google Scholar] [CrossRef]
22. Zaidi SAH, Khan SA, Chaabane A. Unlocking the potential of digital twins in supply chains: A systematic review. Supply Chain Analy. 2024;7(2):100075. doi:10.1016/j.sca.2024.100075. [Google Scholar] [CrossRef]
23. Roman EA, Stere AS, Rosca E, Radu AV, Codroiu D, Anamaria I. State of the art of digital twins in improving supply chain resilience. Logistics. 2025;9(1):22. doi:10.2139/ssrn.5328247. [Google Scholar] [CrossRef]
24. Bertsimas D, Kallus N. From predictive to prescriptive analytics. Manag Sci. 2020;66(3):1025–44. doi:10.1287/mnsc.2018.3253. [Google Scholar] [CrossRef]
25. Sadana U, Chenreddy A, Delage E, Forel A, Frejinger E, Vidal T. A survey of contextual optimization methods for decision-making under uncertainty. Eur J Oper Res. 2025;320(2):271–89. doi:10.1016/j.ejor.2024.03.020. [Google Scholar] [CrossRef]
26. Bharti MK, Wadhvani R, Gyanchandani M, Gupta M. Transformer-based multivariate time series forecasting. In: Proceedings of the 2024 IEEE International Students’ Conference on Electrical, Electronics and Computer Science (SCEECS); 2024 Feb 24–25; Bhopal, India. p. 1–6. [Google Scholar]
27. Saberi S, Kouhizadeh M, Sarkis J, Shen L. Blockchain technology and its relationships to sustainable supply chain management. Int J Prod Res. 2019;57(7):2117–35. doi:10.1080/00207543.2018.1533261. [Google Scholar] [CrossRef]
28. Agrawal A, Amos B, Barratt S, Boyd S, Diamond S, Kolter JZ. Differentiable convex optimization layers. In: Proceedings of the 33rd International Conference on Neural Information Processing Systems; 2019 Dec 8–14; Vancouver, BC, Canada. p. 9562–74. [Google Scholar]
Cite This Article
Copyright © 2026 The Author(s). Published by Tech Science Press.This work is licensed under a Creative Commons Attribution 4.0 International License , which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.


Submit a Paper
Propose a Special lssue
View Full Text
Download PDF
Downloads
Citation Tools