Skip to content
Go to insights Blog

Data Driven Double IPA

Data Driven Double IPA
Written by
Data Science Lab
Published on
4 May 2021

Data-driven beer?

Brewing a data-driven beer? That will probably raise plenty of questions. Is the beer brewed by computers? Will it taste any good? Brewing beer takes skill and craftsmanship, so shouldn’t we leave it to brewers?

Don’t worry. Grab a drink: in this blog, we’ll look at the beer being created through a collaboration between Uiltje Brewing Company and Data Science Lab. We’ll give you insight into the process and demystify the word ‘data-driven’.

As a young, innovative company, we immediately found a like-minded partner in Uiltje. Brewing a beer based on data — how cool is that! It’s a project that fits well within our Lab. But how does an idea like this come about? It will surprise no one that it started on a Friday afternoon. Could we do something with data and beer? What happened next is clear… Nothing ventured, nothing gained.

Nice idea, but how are we going to do it? In any data project, whether the aim is to produce a dashboard or a deep learning model, data is the foundation. Nothing surprising there, but what data do we need? How do we get it? And perhaps more importantly, what exactly do we want to do with it? First, we need to ask: how is a beer usually made?

To get a good answer to that question, we spoke with Marko Mihalić, Brewery Manager at Uiltje:

“Uiltje has its Fresh & Fast range, of course, with a new beer delivered every 2 weeks. That means we make a new beer every 2 weeks. We vary the style: one week it might be a DIPA and 2 weeks later, for example, a Session IPA. That gives us variety in what we release. We draw inspiration partly from the hop varieties available and the quality of those hops. Hops are like grapes in wine: the same hop variety tastes slightly different each year. We also do a lot of testing with different hop combinations in our own lab to create new flavours. And new hop varieties are always coming out of the US for us to work with. In our lab, we brew experimental batches of 20 – 25L and try things out until we arrive at recipes for new beers”

Clearly, brewing beer is a craft. As in almost every sector, data can provide useful support. It can reveal connections you might not spot yourself. It is then up to you to act on the results. After all, computers cannot interpret data on their own. With this in mind, we started the project with the brewers. They would ultimately be the ones working with the results, so they were the logical starting point. What input from data could you use? How could you brew a data-driven beer with our help? And how do you, as a brewery, feel about using data?We put these and many other questions to the brewers at Uiltje. This is what they told us:

Marko: “A flavour profile would be the perfect starting point for us to develop a recipe and a beer. If the data and algorithm could give us a set of characteristics for a specific beer style, we could take it from there. Using data to develop a recipe this way is new to us. Data is playing an increasing role in marketing and sales, much as it does in other commercial companies. But that is not yet the case when we develop a new recipe and beer. Our ‘brew kit’ is fairly manual. We do have computers that regulate the cooling of the brew, and the pumps are computer-controlled too. We want to automate more of the process, for example during mashing. That fits with being a craft brewery. Craft is mainly about working with a living product, the brew, without artificial extracts or hop extracts, and without pasteurising”

Right. As data scientists, we know what to do: collect data! This is familiar territory for us. We need data from reviews: real consumer opinions about beer. Even though we have our own bar at the office, our own data is still fairly limited on this front. That need not be a problem; a lack of suitable data is common. Fortunately, we live in the 21st century, and external data sources are almost always available. This case is no exception. People review all sorts of things online, including beer. There are even dedicated websites, apps, forums and more. Perfect! Web scraping. This technique gathers information from web pages to build a dataset. It makes it easy to collect an external dataset from publicly available data. We’ll keep things light for this blog. We have the data, so what’s next?

We now have the reviews: plenty of opinions on many different beer styles. How much did people like the beer? What flavours did they taste? What style of beer was it? How much alcohol did it contain? Did they mention anything else worth noting? There is plenty of information to organise. We’re looking for the optimal combination of characteristics for a specific beer style. Some information, such as alcohol percentages and beer styles, is readily available. But what exactly people liked about a beer is less obvious. Which flavour combinations appeal to them? To gain more insight into this, we used Natural Language Processing, or NLP.

NLP methods extract valuable information from text. This lets us link flavours and keywords to a review. So far, so good. Someone might taste citrus, grass & creaminess in an IPA, but how do those flavours get into the beer? Which ingredients produce which flavours? How does Uiltje achieve this?

Marko: “The aromas released in a brew can come from various sources. Each hop variety has its own distinctive flavour. For example, ‘Columbus’ hops give a grassy flavour, while some yeast strains produce a ‘hazy’ character. We have several beers with fruity notes. Flavours such as pineapple do not come directly from hops or yeast, so we regularly add fruit purées to the brew. Hop oils & dry hopping can also add different flavours. Besides hops, malt is of course an ingredient in beer. Flavours such as chocolate and coffee come from the malt. Ageing beer in barrels — ‘barrel-aged beer’ — can bring other distinctive flavours from the wood or from the drink previously held in the barrel.”

So many ways to give beer flavour! It is no surprise that ‘craft beer’ has grown rapidly in recent years. We often see data science projects in ‘growing markets’ like this, where there is usually plenty of scope for further development. That makes this a promising project! What’s next? Modelling! We use this dataset to build a regression model and find an optimal set of characteristics: the characteristics of the optimal beer. You can read how we approached this technically in the next blog post! These characteristics include alcohol content, IBU (bitterness from hops), aroma, mouthfeel and, of course, the combination of flavours. Using this regression model, we arrived at an optimal set of beers within a specific beer style. More precisely, the model shows us the proportions for the best possible combination of flavours. We pass these proportions on to Uiltje.  The brewers can get to work, and we cannot wait.

Blog

You may also find this interesting,

Sign up for our newsletter.

Want to be the first to hear about a new blog post?

Enter a valid email address.