Inventory Management using Machine Learning

DOI : 10.17577/IJERTV9IS060661

Download Full-Text PDF Cite this Publication

Text Only Version

Inventory Management using Machine Learning

Praveen K B

Student of Computer Science Engineering Bangalore Institute of Technology Bengaluru, India

Pradyumna Kumar

Student of Computer Science Engineering Bangalore Institute of Technology Bengaluru, India

Prateek J

Student of Computer Science Engineering Bangalore Institute of Technology Bengaluru, India

Pragathi G

Student of Computer Science & Engineering Bangalore Institute f Technology Bengaluru, India

Prof. Madhuri J

Assistant Professor, Computer Science Engineering Bangalore Institute of Technology

Bengaluru, India

AbstractA major requirement for small/medium-sized businesses is Inventory Management since a lot of money and skilled labor has to be invested to do so. E-commerce giants use Machine Learning models to maintain their inventory based on demand for a particular item. Inventory Management can be extended as a service to small/medium sized businesses to improve their sales and predict the demand of various products. Demand forecasting is a crucial part of all businesses and brings up the following question: How much stock of an item should a company/business keep to meet the demands, i.e., what should the predicted demand of a product be? Among its many benefits, a predictive forecast is a key enabler for a better customer experience through the reduction of out-of-stock situations, and for lower costs due to better planned inventory and less write-off items. We discuss the challenges of building an Inventory system and discuss the design decisions.

Keywords Inventory management; Machine Learning; XGBoost; Demand forecasting.

  1. INTRODUCTION

    "Inventory is the supply of raw materials, partially finished goods called work-in-progress and finished goods, an organization maintains to meet its operational needs. It represents a sizeable investment and a potential source of waste that needs to be carefully controlled. Inventory is defined as a stock of goods that is maintained by a business in anticipation of some future demand [2]". Inventory management is a major requirement even for the small and medium shop owners. A system which tracks inventory levels, orders and sales in order to perform predictive analysis, obtaining forecasted demand will help to reduce over-stock and out of-stock situations. A good inventory management system must ensure keeping enough stock in the warehouse to ensure the business keep functioning but not enough stock to drain its limited cash reserves. This is a task where all business needs are to be anticipated, most of the calls made are crisis calls, yet where the people in-charge of the inventory need to find a solution. All done while simultaneously not using all the capital into non-moving stock." Forecasting product demand is one of the core challenges in any retail business [1]". Another question that needs to be answered is how we plan on using

    artificial intelligence into inventory management. Does it have any use in managing inventory? Artificial intelligence needs to be teamed with human oversight and should be treated as part of the system but not as a replacement for the system or the system itself. That being said, there are several companies that are using artificial intelligence in the inventory process and it is yielding very impressive results which leads us to believe that artificial intelligence might after all have a significant impact on demand forecasting. We are transitioning from the traditional ways of managing inventory, which is the direct result of the availability of the huge amounts of real-time data that are now routinely generated on the internet and through the interconnected world of enterprise software systems and smart products. Managers need to make effective use of this newly available data, by redesigning their inventory management process, to stay in the competition against several other E- commerce businesses. Amazon, one of the giants in the business have used inventory management teamed with artificial intelligence in almost every part of the prediction process. "Optimum inventory should be maintained by all organization so that under inventory can be eliminated which disrupt the financial figures. Careful evaluation of internal and external factors through better planning can improve the status of inventory [4]".

  2. LITERATURE SURVEY

    The concept of inventory management includes a vast set of areas to be dealt with. With the rapid expansion of e- commerce industry, the demand for efficient inventory management is the need of the hour. More research effort is required to improvise the existing inventory management techniques.

    E-commerce giants define an end-to-end machine learning system using probabilistic demand forecasting models that is built on Apache Spark. Such e-commerce giants contain large datasets. Forecasting usually includes two different methodologies: Time series methodology and Machine learning methods [1].

    A case study of Inventory Management focused on identification of factors that influences inventory optimization

    among SMEs in steel sector through a structured and unstructured questionnaire can aid in effective inventory management. It involves grouping the factors into two sets as internal variables and external variables [2].

    Artificial neural networks (ANN) is an intelligent system that uses layers of neurons. ANNs are very good with fitting problems. A retrospective study on ANN for inventory management is required to improve prediction accuracy [3].

    AI proves to be beneficial in handling the customer data and forecasting the purchase behavior of customers AI can be used to provide notification when a company has to re-order stock and assist in creating manufacturing schedule considering the variations in demand including seasonal increases accurately [4].

    A decision support system (DSS) is another technique that could be used to assist for effective monitoring of inventory levels and to ensure continuous availability [5].

    To perform inventory analysis that consists of multiple attributes under consideration, a hybrid methodology that integrates multi-criteria decision making (MCDM) techniques with different machine learning algorithms are used. The methodology uses ABC analyses for determining classes and Artificial Neural Network (ANN), Bayesian network, and Support Vector Machine (SVM) algorithms to predict different classes for inventory items. [6].

    Identification of dead inventory can be achieved by predictive modelling. Predictive modelling is a methodology in which a predictive algorithm predicts part obsolescence in advance with reasonable accuracy [7].

    ABC analyses is a classification technique that determines the relevant classes for each of the inventory items, thus providing the proper foundation for demand forecast process. ABC analyses generates an optimized inventory stock classification. [8].

    The demand forecasting technique can be modeled by artificial intelligence approaches using artificial neural networks. Algorithms used for training such models include Batch gradient descent and Variable learning rate [9].

    Software agents are multiagent systems developed within the JADE platform. Agents communicate through message exchange. The system is proposed to make the transition from the manual approach of inventory management software to a completely automated process [10].

  3. PROPOSED SYSTEM

    Organizations face a lot of internal and external risks, like high competition, labor unrest, high risk and change in governmet laws. So, a lot of the decisions an organization makes are under conditions of risk and grave uncertainty. These risks can be reduced by predicting the demand for sales of its products and services in the future. Demand forecasting is a systematic process of anticipating the demand of a product or service offered by the organization in the future under a set of unpredictable and competitive forces. In this paper we use the XGBoost regression model to perform demand predictions. XGBoost is a machine learning algorithm which uses decision trees. In prediction problems that have the data unstructured Neural networks outperform other prediction algorithms, but in our case the data is structured and tabulated, and decision tree algorithms are considered best for structured

    Figure 1: architrcture

    data. Hence, we decided to go with the XGBoost algorithm for demand forecasting.

  4. ARCHITECTURE

    The proposed architecture is collectively obtained from five components: Data Ingestion, Data Pre-Processing, Storage, Feature Extraction, ML model. The architecture of Inventory Management Using Machine Learning is as shown in Fig.1:

    1. Data Ingestion:

      Initially, shop owners can login to the system and add their product details which is stored in a database. Also, the historical sales data is recorded in the database. This data, which is used to train the ML model, is ingested to the system. The training data used consists of several thousands of rows

    2. Data Pre-processing:

      Data pre-processing is a data mining technique which is used to transform the raw data in a useful and efficient format. The data ingested is cleaned before it is used for training the model. Hence, the unnecessary fields are eliminated from the database. Pre-processing also involves the transformation of raw data into an understandable format.

      Semana

      Agencia

      _ID

      Canal

      _ID

      Ruta

      _SAK

      Cliente

      _ID

      Producto

      _ID

      Demanda_ uni_ equil

      3

      1110

      7

      3301

      15766

      1212

      3

      3

      1110

      7

      3301

      15766

      1216

      4

      3

      1110

      7

      3301

      15766

      1238

      4

      3

      1110

      7

      3301

      15766

      1240

      4

      3

      1110

      7

      3301

      15766

      1242

      3

      Table 1: training data

      The training data has weekly (i.e. Semana) demands of all the products as shown in table 1. Starting from the third week till the seventh week. Hereby, the trend in weekly demands was analyzed.

    3. Storage:

      S3 stands for Simple Storage Service. Amazon Simple Storage Service (Amazon S3) is an object storage service that offers industry-leading scalability, data availability, security,

      and performance. S3 enables customers of all sizes and industries to use it and protect any amount of data for various use cases, such as websites, mobile applications, backup and restore. It is designed for 99.999999999% (11 9's) of durability. The pre-processed data is stored in the S3 Bucket.

    4. Feature Extraction:

      The data stored in S3 bucket contains several fields. With the help of proper feature extraction, the accuracy of model can be increased, hence only certain fields of the dataset were extracted for training. For example, the training data consists of product name as well as product ID. Only product ID is required to train the model. Thus, only the required features are extracted from the dataset and used to train the model.

    5. ML Model:

      An algorithm called XGBoost is used as the machine learning model. XGBoost is an ensemble algorithm which is based on decision-trees and uses gradient boosting framework. It was evolved from basic bagging algorithm. Normally prediction problems consisting of unstructured data neural networks tend to perform poorly when compared to other algorithms or frameworks. However, when it comes to small- to-medium, structured/tabular data, decision tree-based algorithms perform well.

    6. Report:

    The demand values for the next 2 weeks are predicted by the XGBoost model. The predicted demand values are real numbers. To get actual demand values, the values were rounded. The predicted values are output as a report to the shop owners aiding for an efficient inventory management.

  5. IMPLEMENTATION

    The model utilized to perform the prediction is known as XGBoost (Extreme Gradient Boosting) regression model. XGBoost is an ensemble decision tree machine learning algorithm. When the data is small and structured, these decision tree-based algorithms outperform other algorithms. XGBoost algorithm was evolved from Bagging Algorithm.

    Figure 2: Evolution of XGBoost

    The evolution of the XGBoost can be better understood from the figure 2, which makes it highly suitable for implementing large amount of data.

    1. XGBoost Working:

      The XGBoost constructs the decision trees based on the error factor obtained from the previous tree. The technique followed is like that of a normal tree boosting except the way error calculated from the loss function is different. The XGBoost follows certain steps; 1. Model fitting to the data, 2. Model fitting to the residuals, 3. Generating new model (where the new model is boosted version of the old), 4. Repeating all the steps till error is improved.

    2. Training the model:

    After the model is implemented, training of the model is necessary to predict the demand with better accuracy. The train_test_split is a function for splitting data arrays into two subsets: for training data and for testing data. With this function, eliminates the task of splitting the dataset manually. By default, train_test_split will make random partitions for the two targets x and y. The model is trained using an approach known as early-stopping-rounds which helps to avoid overfitting. It works by halting the training when there is no increase in the performance on the test dataset up to the specified number of iterations (i.e. up to 100 in our case). It can automatically circumvent overfitting by considering the point of inflection where the performance starts to decrease on test data while for the training data goes on improving towards overfit.

  6. EXPERIMENTAL RESULTS

    On each week the data was extrapolated of the previous week and the predicted demands was verified with the dataset. The table 2 depicts the RMSE values obtained for each week added. The increase in the RMSE values is due to the new week data appended to the previous and so on, making the training data large.

    Week

    RMSE

    3

    0.6778

    4

    0.6921

    5

    0.6654

    6

    0.6814

    7

    0.7015

    Table 2: RMSE values for each extrapolation

    Thus, there was an improvement in efficiency of the model when new weeks were added and trained together. With more weekly data outcomes more accuracy.

    Product_ID

    Product_Name

    Demand

    1

    NO IDENTIFICADO 0

    4

    9

    Capuccino Moka 750g NES 9

    39

    41

    Bimbollos Ext sAjonjoli 6p 480g BIM 41

    2

    53

    Burritos Sincro 170g CU LON 53

    31

    72

    Div Tira Mini Doradita 4p 45g TR 72

    2

    73

    Pan Multigrano Linaza 540g BIM 73

    2

    98

    Tostado Integral 180g WON 98

    2

    99

    Pan Blanco 567g WON 99

    2

    100

    Super Pan Bco Ajonjoli 680g SP WON 100

    2

    106

    Wonder 100pct mediano 475g WON 106

    2

    Product_ID

    Product_Name

    Demand

    1

    NO IDENTIFICADO 0

    4

    9

    Capuccino Moka 750g NES 9

    39

    41

    Bimbollos Ext sAjonjoli 6p 480g BIM 41

    2

    53

    Burritos Sincro 170g CU LON 53

    31

    72

    Div Tira Mini Doradita 4p 45g TR 72

    2

    73

    Pan Multigrano Linaza 540g BIM 73

    2

    98

    Tostado Integral 180g WON 98

    2

    99

    Pan Blanco 567g WON 99

    2

    100

    Super Pan Bco Ajonjoli 680g SP WON 100

    2

    106

    Wonder 100pct mediano 475g WON 106

    2

    The future week demand for each product is predicted by the trained model where each demand values are rounded off to their nearest integer as shown in table 3.

    107

    Wonder 100pct gde 680g SP WON 107

    2

    108

    Baguette Precocida Cong 280g DH 108

    2

    109

    Pan Multicereal 475g WON 109

    2

    112

    Tostado Integral 180g WON 112

    2

    122

    Biscotel Receta Original 410g CU SUA 122

    2

    123

    Super Bollos 5in 8p 540g WON 123

    2

    125

    Bollos 8p 450g WON 125

    2

    131

    Bollos BK 4in 36p 1635g SL 131

    2

    132

    Bollos BK 5in 30p 1730g SL 132

    2

    134

    Bollos BK 4in 30p 1635g TIR SL 134

    2

    135

    Bollos BK 5in 20p 1730g TIR SL 135

    3

    141

    Hot Dogs 8p 290g WON 141

    3

    145

    Super Hot Dogs 8p 435g WON 145

    4

    151

    Medias Noches 24p 470g BK SL 151

    2

    157

    Bollo WB 5in snAjn 20p 1950g SL 157

    2

    160

    Molido Bolsa 180g WON 160

    4

    Table 3: demand predicted for the next week (10th week)

    Figure 3: Bar graph of top 50 products.

    With the result obtained, figure 3 illustrates the analysis (product versus demand) performed to understand and verify the demand predicted for each product

  7. CONCLUSION

The Demand Forecasting will help Small/Medium businesses to maintain inventory and minimize manual labor. Allowing it to reduce the capital spent on maintaining inventory. In this process it aims at simultaneously improve in profitability. With the forecasting technique, the overstock and stock-out of items are reduced as the stocks are ordered based on the Demand. In the future, the accuracy of the model can be improved by incorporating categorical embeddings in neural networks as it is still a budding topic in the field of neural networks and requires more research.

REFERENCES

[1]. Joos-Hendrik B¨ose, Valentin Flunkert, Jan Gasthaus, Tim Januschowski, Dustin Lange, David Salinas, Sebastian Schelter, Matthias Seeger, Yuyang Wang (Amazon), Probabilistic Demand Forecasting at Scale, Proceedings of the VLDB Endowment, Volume 10, Issue 12, 2017, pp. 1694-1705.

[2]. Nazar Sohail, Tariq Hussain Sheikh, A Study of Inventory Management Case Study, Journal of Advanced Research in Dynamical & Control Systems, Vol. 10, 10-Special Issue, 2018, pp. 1176-1190.

[3]. Rohaifa Khaldi, Abdellatif El Afia, Raddouane Chiheb, Rdouan Faizi, Artificial Neural Network Based Approach for Blood Demand Forecasting, ACM ISBN 978-1-45034852-2/17/03 , 2017.

[4]. Yashoda, Kiran and Lingam, The role of Artificial Intelligence (AI) in making accurate stock decisions in E-commerce industry; International Journal of Advance Research, Ideas and Innovations in Technology, ISSN: 2454-132X (Volume 4, Issue 3), 2018, pp. 2281-2286.

[5]. Mahuya Deb, Prabjot Kaur and Kandarpa Kumar Sarma, Inventory Control Using Fuzzy-Aided Decision Support System, Advances in Computer and Computational Science, Vol 554, Springer, Singapore, 2017, pp. 549-557.

[6]. Hasan Kartal , Asil Oztekin, Angappa Gunasekaran, Ferhan Cebi, An integrated decision analytic framework of machine learning with multi- criteria decision making for multi-attribute inventory classification, 2016, pp. 599-613.

[7]. Madhu Babu Cherukuri, Tamoghna Ghosh, Control Spare Parts Inventory Obsolescence by Predictive Modelling, IEEE Smart Data, 2016, pp. 865-869.

[8]. Darya Plinere, Arkady Borisov, Inventory Management Improvement using ABC Classification, Information Technology and Management Science, Riga Technical University, 2015, pp. 91-96.

[9]. Ashvin Kochak, Suman Sharma, Demand Forecasting using neural network for Supply chain management, International Journal of Mechanical Engineering and Robotics Research, ISSN 2278-0149, 2015, pp. 96-104.

[10]. D.S. Plinere, A.N. Borisov, L.Ya. Aleksejeva, Interaction of software agents in the problem of coordinating orders, Automatic Control and Computer Sciences, Vol 49 Issue 5, Springer, 2015, pp. 268-276.

Leave a Reply