Skip to content

Excuse me, bartender, there’s AI in my beer [DATAcated Conference 2021]

According to German law, beer can only contain four ingredients: barley, hops, yeast, and water. But recently, breweries in Germany have been adding a secret, fifth ingredient to help them optimize their processes and get a lead over their competitors: machine learning.

When you’ve already bubbled to the top of your game, how do you keep going, especially in an industry that’s facing increased prices, competitive pressures, and initiatives to promote efficiency? The answer is simpler than you might think, and it’s easier to grab than a draft of Dunkel: it’s your data.

In this presentation, we’ll explore the possibilities and limits of existing approaches to data-based process optimization and show why new approaches are needed to help you brew up your best, no matter what kind of beverages you produce.

In this video, you will learn:

  • A framework for using AI in the beverage industry, based on work done by the DaPro research consortium in Germany
  • Insight into how any old process can be reinvigorated with novel approaches
  • How machine learning is accessible to anyone without having to become a data scientist

RapidMiner works with leading brands in food and beverage (and other industries) to help all data-loving people achieve results with predictive analytics, data science and machine learning. So, grab your favorite brew (coffee’s a brew, too, if you’re on company time) and settle in to learn more about adding this secret ingredient to your beverage-production processes.

00:00 Of this session, Martin Schmitz, he is the head of data science service at RapidMiner and the talk today is, Excuse me, bartender, there is AI in my beer, data driven process optimization for the beverage industry. Martin studied physics at the TU Dortmund University and joined RapidMiner in 2014. During his career as a researcher, Martin was part of the IceCube Neutrino Observatory located at the geographic South Pole. Using RapidMiner and IceCube data, he studied the most violent phenomena in the universe, supermassive black holes and gamma ray bursts. Being part of several interdisciplinary research centers, Martin dived into computer science, mathematics, and statistics, and has taught data science and the use of RapidMiner. All right, Martin, let’s go ahead and bring you up on our virtual stage here. Hello, welcome to the DATAcated Conference.

00:53 Thank you. Hello, everybody. Hello, Kate. Thank you for the introduction. And let’s move continents a bit. So I think for the last hour or so, we heard quite a lot about very American sports. I mean, basketball, baseball. I think I heard a bit of hockey there. And let’s move over to beer and most importantly, German beer. So we’ll talk about how do we make German beer, well, even better. We know German beer is the best beer in the world. How can we make it even better? And when I was writing about DATAcated on my LinkedIn a month ago or something, a Belgian friend of mine came in and said, “Hey, it’s easy, just stop what you’re doing and do it the Belgian way. Our beer is better,” and that’s kind of what we don’t want to do. A lot of the decision-making is, of course, driven by gut feeling. We heard that today and yesterday quite a lot, that there are many decisions which are done nowadays which are not data driven, and we want to make them data driven and not just, this beer is better than this beer just because it’s my beer or my country’s beer or something. That’s the first thing which is important.

02:01 The other thing which is important is beer is actually an industry which is a few thousands years old. I haven’t checked it, but beer is brewed forever. So one of the breweries we are working with was founded in the 16th century, actually, before America was rediscovered or discovered. It’s quite a long thing. So this is also something where there is a lot of knowledge, historic knowledge and also a lot of language we are talking about here. Later on during this track, we also hear about wine, where it’s a very, very similar story and we hear a lot about data literacy here. So in the brewing industry, there’s a lot of naming and historic things. And it’s also a hard thing for me here. You probably hear, I’m German myself and a lot of the things we’re doing, we’re doing in German and then translating it over to English or the other way around, translating it from the beer language to the data science language is always a challenge. And you’ll probably see I’m coming from RapidMiner, one of the sponsors of this conference, and we are having a tool where truly everyone can influence the future and can do data science to positively influence the future, in this case, positively influence German beer. In order to do this, you of course need to know first what are you doing or what is the use case? And when we are working with our clients, we first do what we call an AI assessment. So we first check what are use cases, what can you do? And let’s have a look at a few of these, what you can do in the brewery.

03:46 So from right to left, let’s start at the end, basically. So what you learn when you’re starting to talk to brew masters or to brewery is, well, there are merchants or companies coming and saying, “Hey, guys, I need three trucks of beer tomorrow.” Okay, thank you. Beer isn’t brewed in a day. It needs a while to be brewed or actually to stand there. So it’s– and well, you may say, “Hey, why don’t you tell these guys, tell us up front,” then they say, “No, I mean, we now need a truck.” And of course, there are situations where you know up front that you need more beer, European soccer, World Cup or football. World Cup is starting next month. Well, we’re not sure about corona here, but in general, this would be something or a carnival in Germany is a big thing. There you need a lot more beer and stuff. But then again, forecasts of the volume of trucks or then again, how much beer you need to create or brew is, of course, very, very important.

04:53 Then in the filling line where you take the beer and put it into bottles, there you want to know– there is a predictive maintenance problem. Actually, to be fair, predictive maintenance you can can look at all of these things here and probably figure out a predictive maintenance case for all the things. Here it’s a very special one, because this filling machine can have several things which can break. And what we want to do is do a cause analysis. What caused the break right now so that we can directly go to the right place and fix it. Then in the filtering of the beer, the filter lifetime is something also very interesting. It’s remaining useful lifetime prediction. And a lot of the use cases we are talking about here are, well, this is a beer use case. You need to filter beer and there’s a filter and the filter has a certain lifetime. And at some point you need to change it. Actually, there are also some settings which you can change to prolong or shorten their lifetime and so on. And then what you want to do is predict how long can I still use this filter, when do I need to change it? IA, to maximize the lifetime filter, B, to of course, schedule the maintenance need. That is something you have in a lot of cases. A lot of the use cases you have here are actually transferable over to other industries, other manufacturing. You’re producing, well, a good at end. Also, focus of energy demands, super, super interesting because there are sometimes spikes that you need to cool down quicker than something and they are actually reserves into the system. If the spike is only for 10 minutes, we’re good. The condensers, they take care of it. If it’s longer than 10, maybe 30 minutes, don’t really, yeah, about the exact minutes, then you need to push new condensers on, get more cooling powers and so on. And actually is the start of this is super expensive. If you start the additional cooling machines, super expensive. So knowing whether it’s a small spike or large one, big, big thing, because then you can decide whether you add additional cooling resources.

07:17 And then there are two use cases we’ll talk a bit more about. And they are both about hop and malt. I mean, malt is basically something coming from grain and hop is a plant. I mean, it’s there, which has different quality basically when it comes from the field. And what we will talk about the big use cases is, okay, how do I optimize either the selection, the composition, or the process parameters, given that I have this natural good coming in with varying quality so that I get the perfect beer in the end? Pretty straightforward. Again, you have this use case of, I have different materials coming in and I want to set the right parameters in a lot of use cases outside of beverages. So you actually have that in the complete opposite use cases and chemical industry, steel industry, same question. But here we talk about beer. So sounds like we’re good. We know what to do. Let’s rush ahead and fix these things. We figured out big things. The filter relevant downtime, we talked to these guys who have this problem and they always need to crouch down into the machine and figure out is is there this or not? No, that’s what we don’t do. There’s something very important what we do, which is you need to map the business problem. This is essential. We don’t do data science for fun mostly, mostly, but we do this to drive business revenue. So what we do here, RapidMiner, when we have a new client coming up, and if you want to become a RapidMiner client, we will do this with you as well as is we do not just look at the use cases, but we put them into this AI assessment map where we map two things.

09:10 The first one is relatively easy, impact compared to feasibility. Impact is value in euros or dollars or local currency units, whatever you prefer. Or sometimes it’s in KPI’s, like customer satisfaction went up if it’s a customer use case. Feasibility is a bit of a mixture. It’s including is the data available, is the use case solvable from a data science standpoint? It’s how do we deploy it different? Yeah, it’s definitely hard when you do it or not. And you see here our two use cases, malt prediction, I’ll have to talk about this in a second, and hop alpha prediction where we look about the two ingredients as hop and malt have very different points here on the scale of feasibility. They’re both important. But why? In the hop alpha prediction, what you want to do is use weather data and so on to define or predict the best harvest time for hop. So you need to take data into account from the farmers and from the farms, which you need to get, and also the predictions you need to deliver not to the brewery, but actually to the farmers who are delivering the hop to the brewery. Way harder. That is one of the reasons why we are looking at malt prediction.

10:40 What is this? So I said malt has different specifications. So you can actually go there and there are quite some lab measurements running. And to be fair, there are also different kinds of malts coming into the brewery, which you want to mix to get going. And then you have the process parameters. And then later on, you measure the malt yields. And in very layman term, what you want to know is how much sugar is there, because the sugar if you add the yeast, it gets to alcohol. It’s actually the cold wort if you’re getting getting deeper into that. But you want to predict the sugar content from the specifications of the malt and the process parameters, or later, you want to optimize either the malt mixture or the process parameters for a given malt mixture to get the best beer or best sugar or cold wort. And that’s what we want to do. So we have now mapped our use cases, figured out this is the doable one, a high value one. Let’s get going. Let’s start RapidMiner, load the data in and encode. And then we hit reality because everybody is saying, “Hey, you get insights in seconds, we load your data and then the magic machine is going on and so here we are.”

12:04 Reality is always different. Reality means then things get hard. Why does it get hard? Because you need to understand the data. And then again, we’re talking about a brewery with supposedly hundreds of years of history and knowledge and also processes going on, which you need to understand what’s going on. And there was something very simple we encountered, which then is very hard because you think I know what malt is used. I know it. I know what comes in. And then you have a look at a malt silo and this is a simulation of it. And, well, there’s literally a truck coming, putting the malt into the silo. And then there are layers of the different malts coming from different farms, having different ingredients and different properties. And if you open basically the door down here and take malt out of this, this is how the malt folds down into your wagon or whatever you use. And so the first thing is actually you need to calculate what kind of malt was used what, when. And that’s only one of the problems you face, which are real life problems, which you probably don’t see really in kettle problems because that is, well, it’s not fancy data science, but it’s necessary. And to understand what is going on and we could take a dozens of these problems where like, huh, what is this? And then people are telling you, “Oh yeah, there’s something later down the road,” the whole, “Let’s go over, I explain to you, you need to understand this.” So teamwork is key to success in those use cases. You need to work together. RapidMiner is giving you the platform. It’s a visual platform which is code optional. You can add your Python, you can use R, if you want to, but you don’t need to. So this gives also brew masters the option to run the analytics and do the data preprocessing on their own or together with a data scientist. And the more complex the data sets, the more– I mean, everybody can think about, okay, this is how basketball works. I’m a German. I have no clue about basketball, but I know the fundamental rules that could follow our stock, great. If it’s going down into chemical equations, beer brewing, steel industry, pharmaceuticals, way harder and this joint work or work of the expert is something where we are very, very successful with.

14:36 So what’s the result? So we used first only one malt source. So we went for a prototype and this quick prototype using RapidMiner automodel was already getting decent results. I think R-squared of .8 or something, something around this line. So it was pretty good. Okay, so this gave a lot of drive for the project, which is always good if your prototype gives you a good result. But then we did it on the full data set and it was even more surprising and something is a good takeaway message. So the second model on the full data set was as good as the lab measurements taken in the middle of the brewing process. When you just take a sample and you measure the, quote-unquote, “sugar content” of the beer and this is the perfect model. So usually when you’re doing a lot of analytics, there is no perfect model because you may think you can always do a better model. In some of the industrial cases, if you’re predicting in the accuracy of the measurement, you cannot become better than the accuracy of the measurement because you don’t know the truth, the label, the why variable better than this accuracy. And that’s what we achieved here. We’ve built the model where at this point we say, “Well, maybe we can build a better model if you get a better measurement.” But so far, let’s move over to the next use case. We’ve got a few of them. We talked about this earlier, and so then

16:08 So if you’re interested in learning more about these things, the six use cases I mentioned in the beginning, we just published a blog post walking you through this and explaining again the different ones. You can, of course, look at the recording again. But if you want to have a written version, RapidMiner.com/blog then also supply chain, the truck thing. The truck comes here and says, “Hey, I need three trucks of beer. How do you handle these things?” what our approach is to do that, check out our blog.

16:38 Awesome. Thank you so much, Martin. I was going to come back here with a beer, but I didn’t have one of the best German beers. So I’m just not going to risk it and stick to my water and coffee for now. Thank you. Thank you so much for that presentation. We do have time for one question and I’ll take a question here from Kevin. And he’s asking, does consolidation in the beverage industry limit the amount of data that is available since there are fewer companies that are providing the data?

17:06 Oh, that is a good– well, that’s an American question. Let’s say like that. So not necessarily American, but the German brewery market is actually pretty diverse compared to other breweries or other markets where there is a lot more to do. I think there are four big players getting more and more. I would rather put it really the other way around. Those four or five players who have everything really have the ability to build more and more powerful models. And then it’s the question, what about middle-sized breweries? Do they have enough data to build good models? That is the good question. But that’s a question you see in every industry, every small and medium enterprise who’s producing some machine, there’s the question, do you have enough data to build powerful models? So far if you look at the German market, it’s not a– it’s with a very big ones like Heineken and Anheuser-Busch and so on. They have a few brands here, but it’s more diversified. And this is also not done with one of the super large ones. It works pretty decently. So I would say short, no.

18:15 No. Okay, all right. Yeah, I didn’t think so, because the data is still there. It is just formatted– it’s consolidated across a smaller number of companies. But, Martin, I learned a lot today about the beer industry. So thank you so much for educating us. And like you mentioned about the RapidMiner.com/blog can provide you with additional case studies and articles. So go ahead and check that out. All right, Martin, thank you so much. We’re going to go and keep this data party moving.

Accelerate Your Data-Driven Transformation

Read our study conducted by Forrester Consulting to get a better understanding of how other organizations are achieving success and planning for the future.

Related Resources. Take a Look!