Background
Our client is a platform which aims to streamline end-to-end supply chain processes for fast growing e-commerce organizations. They acquire customer inventory data from several channels, notably Shopify and Amazon, and store this data in a PostgreSQL database hosted on AWS. The available historical data ranges from several weeks to well over a year amongst their longer standing clientele.
Problem Statement
In an effort to further scale our client’s services, Beam Data was tasked to develop a robust framework to forecast demand and inventory levels for their varied customer base. In order to develop this framework, Beam Data introduced and compared classic statistical techniques against machine learning (ML) models using comprehensive evaluation methodologies.
Methodology
The first thing we needed to do was to get access to and begin exploring the data. Once we were able to assess the distribution of the data, we chose a representative sample which we could begin evaluating our models on.
Custom functions were created to establish intuitive benchmarks (same sales as yesterday, same sales as last week, moving averages, weighted moving averages) that could serve as a benchmark. Different deep learning and traditional machine learning techniques (gradient boosted trees, N-Beats, linear regression) were tuned and ensembled to produce the lowest possible loss (root mean logarithmic error) on the evaluation dataset.
A robust validation method of 4 different folds of 7 days was used to test the performance of each model. This strategy increased the sample size of our evaluation phase and reduced the uncertainty of how the winning model would perform in practice. Functionality for probabilistic forecasts was built into the models and evaluated. This allowed our client’s customers the ability to add levels of uncertainty into their production run planning.
Conclusion
In this engagement, the Beam Data team utilized their expertise in developing and evaluating time series forecasting methods to provide a robust probabilistic framework for predicting inventory demand. This provided an immediate improvement over their current system and produced real value to their client’s customers by demonstrably reducing stockouts and spoilages.