One of the biggest headaches for anyone purchasing food in bulk – whether it’s grocery stores or restaurants – is figuring out how much to buy. Perishable foods go bad quickly and if ordering is off, the food that’s thrown out has a direct impact on the bottom line. This problem is what led Stefan Kalb, a Seattle food entrepreneur and owner of a local sandwich and salad distributor, to create a software platform that could use artificial intelligence and predictive analytics to cut waste.

Shelf Engine is a Seattle startup that just announced an $800K seed round of funding to deliver a software platform to grocery stores and food distributors that would predict and in some cases automate perishable food ordering. The software works with the retailer’s existing system, pulling in historical sales data, profit margins and combines it with external factors like seasonality, volatility and gross profit by product to deliver precise food orders.

Reddit co-founder and Shelf Engine seed investor Alexis Ohanian commented about the startup’s potential on Product Hunt, saying:

As seed investors, we’re always excited to learn about new problems that have potentially valuable software solutions — food waste is one of them. The food industry hasn’t had the ability to solve this with software and this app helps retailers and distributors reduce their waste.

Kalb uses Molly’s, the food distributor he founded, as a case study for Shelf Engine. Molly’s distributed fresh, locally sourced sandwich, salad and deli products to local businesses and guaranteed their sales – meaning, if they didn’t sell, Molly’s refunded the retailers. And because they used such fresh ingredients, the food only had a shelf life of five days or less.

Often, Kalb found, the company was using waste data as the sole metric to predict future orders. If waste was high for one account, they’d lower the next order. If it was low, they’d increase the next order. But this method is highly problematic – according to the study, “when managers react to waste, they are reacting to a single point of data. That decision isn’t based on a cumulation of waste and deliveries.” It often led to volatile availability of their products at places like Seattle Children’s Hospital cafeteria – at times the shelves would be full, and other times they would be empty. There was little predictability for customers looking for Molly’s food at meal time.

The company then began using Shelf Engine, which generated a probability model for all ten of their accounts. Basically, the model looked at the likelihood of products selling or products being wasted at any given level of availability and would then find the maximum between the two.

After using Shelf Engine for just a few months, the company saw a 7% leap in profitability.

Kalb opened Molly’s at the age of 23, with a degree in actuarial science and economics and on a 2014 ski trip with friend and engineer Bede Jordan found themselves wondering why the processes and systems in the food industry were so outdated.

 Could we create a platform that enables retailers to buy food and eliminate significant waste?  Could we create a platform that eliminates redundant busy work between vendors and retailers?  Could we create a more perfect marketplace?

These questions led the pair to create a product that would move the food industry towards more efficient systems using technology. Jordan himself is a former engineering lead at Microsoft who worked on HoloLens, an augmented reality technology. He will now lead the development of Shelf Engine as its CTO.

To get analysis like this and to stay up to date on the future of cooking and the kitchen, subscribe to our newsletter, the Weekly Spoon.