During recent years Artificial Intelligence has been applied to almost all domains and industries in order to improve or solve specific problems identified by humans. One example is the industry of Food and Beverages, where AI models are being used for different purposes:
- Finances: by creating more predictable demand forecasts
- Innovation: by suggesting new ingredients combination and more diverse menus
- Environmental sustainability: through the reduction of waste, water and power
This last point is particularly important as statistics say that, in the US, 5% to 10% of the food purchased by restaurants is wasted, which corresponds to direct cuts of the restaurants profit. This waste can be the result of inefficiency in the management of the chain store, bad estimations of the ingredients needed for a given dish, oversized portions and high variety of menus, which require a wider set of different ingredients.
In order to reduce food waste and increase restaurants profits, in this post we will discuss an approach to estimate the food waste (per ingredient) based on the restaurant orders and respective dish recipes.
This will allow a more clear perception of the contribution that each dish makes to the total food waste produced by the restaurant. Also, through a forecast of the actual quantity of ingredients required, we can avoid the need to overbuy groceries.
Data and Modeling
In order to estimate the food waste of a restaurant we essentially need to know:
- The recipes from which the kitchen team make the dishes
- Number of dishes made in the past
- Reporting of the groceries shopping for the same time span
So, the overall ingredients used by the kitchen team can be structured as follows (from now on referred as matrix K):
Where we have, based on the restaurant recipes, the expected amount of each ingredient used for the different dishes that the restaurant serves.
However, for each dish and each ingredient we will have some associated waste (that can be zero). Thus, the overall food waste can be represented as follows (from now on referred as matrix Ɛ):
Where Ɛi, j corresponds to the amount of ingredient j of dish i that was wasted.
Thus, in order to determine the waste the kitchen is producing, per dish and ingredient, we need to learn the values of matrix Ɛ.
To do that, we can start by modeling the problem as follows:
- Nd : Number of meals of dish d made by the restaurant
- Kd : Ingredients (and amounts) needed for cooking dish d
- Ɛd : Food waste derived from the confection of a single dish d
- Consumption: Total amount of ingredients bought by the restaurant for the same time span
From the restaurant’s historical data we can use the grocery receipts for determining the total amount of ingredients bought (Consumption) and the history of orders for computing Nd . This way, knowing the variables Nd , Kd and Consumption, we can train a Machine Learning model to learn the matrix Ɛ, based on the previous equation.
After the model learns the matrix Ɛ, we can make some detailed analysis:
- Analyzing the matrix Ɛ row-wise, we can check which dish contributes the most to the total waste.
- When analyzing the matrix Ɛ column-wise we will find out which ingredient contributes the most to the total waste produced by the restaurant.
- By dividing the matrix Ɛ by the sum of matrices Ɛ and K, we determine the percentage of waste, per ingredient, of each dish.
Based on these points, some actions can be taken in order to improve the restaurant profit and environmental footprint, like reviewing the cooking process of the dishes with the greater waste, removing dishes or menus where the wasting percentage is significant (which results in reduced profit margins) or investing more on dishes/ingredients where the waste is lower.
Extension to a more complex scenario
In a more complex, and perhaps, realistic scenario, we can formulate the problem considering multiple kitchen teams that work simultaneously in different restaurants and share the same food supply. In that case, we would have the following scenario:
Where N_xd corresponds to the number of meals of dish d made by team x and Ɛ_xd to the waste derived from confection of dish d by team x. In this case, each kitchen team will have an individual Ɛ matrix that contains the waste weights of that specific team.
This scenario allows some more complex analysis, like:
- Which team contributes the most to the overall produced waste?
- Is the waste per dish independent of the team who is preparing it, or is there significant variability of the cooking process in different teams?
- For a given dish, which team cooking process is more efficient, that is, produces less waste for the same amount of time?
One of the action points where we can use this formulation, is to make a more accurate forecast of the amount of ingredients needed for the next D days. In order to do that, we just need to directly apply the formulation with the learned matrix Ɛ.
For instance, if we expect to have 25 orders of Hamburgers and 20 orders of Steak and Baked potato for the next 5 days, based on the tables above, the expected consumption of ingredient Beef would be:
25 * (K2,2 +Ɛ2,2) + 20 * (K0,2 +Ɛ0,2)
Which corresponds to:
25 * (0.15 + 0.08) + 20 * (0.3 + 0.12) = 14.15 Kg
In this hypothetical scenario, we would need to buy 14.15 Kg of beef, assuming that, after training the model, we concluded that making a dish of Hamburger and Steak and Baked potato would led to an average waste of 80g (K2,2) and 120g (K0,2) of beef, respectively.
Every action towards reducing our impact on the environment is valuable, even more so if it can help to optimize our business. Therefore, reducing the waste in restaurants is a great way to improve profitability and contribute to a more sustainable environment.
With that in mind, in this post, we propose an approach for determining the wastes produced in a restaurant at a dish and ingredient level, based on the recipes and the history of restaurant groceries.
This can help perform a more accurate forecast of the groceries needed based on the expected orders in the following days and also create a more realistic idea of which ingredients and dishes are contributing to more waste, so that the restaurants can take action in reducing waste.
As always, if you have any other ideas about how to reduce food wasting, make sure to reach us!