Prompt-engineered contextual embeddings for panel time-series demand forecasting: a benchmark in multi-store inventory analytics
Demand forecasting is a central time-series analytics problem in inventory systems because forecast error directly affects replenishment, service levels, stock availability and operating cost. Recent interest in prompt engineering and language-model-inspired forecasting has created a need to test whether prompt-derived contextual representations add value when rich operational predictors are already available in structured form. This study develops a prompt-engineered hybrid forecasting framework for a multi-store inventory setting and benchmarks it against tabular machine-learning models. Using the Ramin Huseyn Kaggle Demand forecasting dataset, containing 76,000 observations across 760 daily timestamps, 5 stores and 20 products, the study constructs contextual prompts from store, product, price, promotion, inventory, weather, epidemic and seasonal attributes, converts the prompts into dense sentence embeddings and combines them with engineered tabular time-series features. LightGBM, XGBoost and Random Forest are evaluated in tabular-only and hybrid forms using validation-slice tuning, a chronological holdout, model-seed stability checks, rolling-origin sensitivity checks, paired statistical tests and an illustrative nonzero-lead-time inventory simulation. The strongest tuned holdout model is Tabular_XGBoost, with MAE = 11.4174, RMSE = 16.3032, MAPE = 17.8859%, R² = 0.8638 and WAPE = 11.4220%. Hybrid contextual embeddings improve Random Forest but worsen LightGBM and XGBoost under the tuned holdout. The findings support a contingent view of prompt engineering in time-series analytics: prompt-derived embeddings may provide selective value, but they do not necessarily surpass strong structured-data benchmarks when operational predictors already contain the dominant forecasting signal.
Authors
- Mohammad Shamsuddoha (ORCID: https://orcid.org/0000-0002-9509-9060)
- Muhtasib Sarker Tahsin
- Abdullah Al Mamun
- Md Raisul Islam Khan
Institutions
- Western Illinois University (US)
- International American University (US)
- Pacific States University (US)
- California State Polytechnic University (US)
Publication Details
- Journal
- Discover Analytics
- Published
- 2026-10-05
- DOI
- https://doi.org/10.1007/s44257-026-00094-1
- Primary Topic
- Forecasting Techniques and Applications
- Type
- article
- Field-Weighted Citation Impact
- 0.00