BIER BROUWEN MET AI
A data driven beer. These words by themselves bring up a lot of thoughts! Is it brewed by computers? Is that beer even drinkable? Brewing beer is a crafmanship, shouldn’t we leave that to the brewers?
No worries, grab a beer, in this blog we will dive into the beer we’ve created in a collab with Uiltje Brewing Company. We hope to give you a clear view on how this is done and make the words ‘data driven’ a little bit less mystical.
As a young innovative company, we immediately found a like-minded company in Uiltje. Brewing beer based on data, how cool would that be! A project that fits perfectly within our Lab. However, how is such an idea being formed? It would be a surprise that during a Friday afternoon the idea came up. Could we do something with data & beer? The sequel to this is clear… Nothing ventured, nothing gained.
Great idea, but how are we going to do this? In a data related project, regardless of whether this should result in a dashboard or a Deep Learning model, the foundation is data. Nothing shocking by itself, although which data should this be? How do we acquire this data? And perhaps more importantly, what exactly are we going to do with the data? That is step 2. First of all, the question arises, how does beer normally come about?
To get a good answer to this question, we met with Marko Mihalić, Brewery Manager at Uiltje.
“Uiltje has a Fresh & Fast line of course. Every other week a new beer is being delivered. This means that we brew a new beer every 2 weeks. Doing so, we vary in style. One week a DIPA, 2 weeks later a Session IPA. This allows us to bring some variation in the beers we are selling. Inspiration to do so, we get from the available hops and the quality of these hops. Hop is like a grape with wine, the same hop gives a slightly different taste each year. In addition, we do test a lot with different hop combinations in our lab to come up with new flavors. Furthermore, there are always new hop varieties coming in from the US which we can use. In our lab we brew experimental brews of 20 to 25L and we test things that eventually lead to recipes for new beers.”
Clearly, brewing beer is a craft. As in almost all sectors’ data can be a very nice supporting factor. It can bring relations to the surface nobody would have thought of. After this, it is up to the end user to do something with this information or not. Computers simply cannot interpret information. With this in mind, as with all projects, we start with this project. Ultimately, the brewers have to work with our results. Therefore, they are a logical starting point, which input would be workable for you? How could you brew a data driven beer with our help? And how do you as a brewery look at developments like using computers and data within the brewing sector?
We asked these, and many other questions to the brewers of Uiltje Brewing Company. Their answers? …
Marko: ““A flavor pallet would be a perfect starting point for us in order to develop a recipe and brew. If a set of characteristics can be supplied for a specific beer style from the data algorithm, then we can continue with this. Using data in this way to develop a recipe is new for us. In the field of marketing and sales, more and more is done with data, this can be compared with other commercial companies. However, this is not yet the case in the development of a new recipe and brew. When it comes to our ‘brew kit’, we work fairly manual. We do have computers that regulate the cooling of the brew and the pumps are also controlled by computers. Although, we do have the ambition to automate some other processes a bit more as well, for example when it comes to mashing. This ambition fits within the framework of being a Craft brewery. Craft is mainly about working with a living product, the brew, without weird extracts, without the use of hop extracts and without pasteurization.””
Great. We know what to do, collect data! This is familiar territory for us. We need review data, consumer opinions about beer. Despite the fact that we have our own bar at the office, our own data on this point is still fairly limited. This should not be a problem, the lack of suitable data within a project is more common for us. Fortunately, we live in the 21ste century and external data sources are almost always available, also in this case. Online reviews are being written on many things, including beer. Several websites, apps, forums, etc. have even been created for this. Perfect!
Webscraping. A technique that collects information form web pages and through which a dataset can be formed. In this way, an external dataset can easily be from publicly available data. You can read how this can be done technically in this blog , in which we will also discuss various snags. In this blog, we keep things light. We have the data, what’s next?
We now have the reviews, many opinions from people about many different beers and styles. How much did they like the beer? What flavors did they taste? What beer style does it refer to? How much ABV did the beer have? Was there anything else worth mentioning? Enough information, we now have to create an overview. We are looking for the optimal combination of characteristics of a specific beer style. Some information is readily available, such as ABV, beer style, etc. However, what they exactly liked or disliked about a beer is not directly available. Which flavor combinations do people appreciate? To gain more insight into this, we have used Natural Language Processing, also known as NLP.
NLP-methods are being used to extract valuable information from pieces of text. In this way we can assign flavors and keywords to a review. All being said and done, someone can taste citrus, grass & creaminess in an IPA, but how do these flavors even get into the beer? Which ingredients cause these flavors? How does Uiltje do this?
Marko: “De aroma’s die vrijkomen in een brouwsel kunnen door verschillende dingen worden veroorzaakt. Zo hebben hop soorten elk hun eigen specifieke smaak. Bijvoorbeeld de ‘Columbus’ hop geeft een grasachtige smaak af en zijn er gist soorten welke een ‘hazy’ smaak veroorzaken. Wij hebben verschillende bieren met fruit tonen. Smaken als ananas kunnen niet direct uit hop of gist worden gehaald, hiervoor werken wij regelmatig met fruit purees welke aan het brouwsel worden toegevoegd. Verder kan er met hop oliën & dry-hoppen nog verschillende smaken aan het brouwsel worden meegegeven. Naast hop is mout natuurlijk een ingrediënt van bier. Smaken als chocolade en koffie komen uit de mout. Bier rijpen op vaten, ‘barrel aged bier’, kan ook weer andere unieke smaken aan het bier geven vanuit het hout of de drank welke daarvoor op dat vat lag”
So many options to impart flavors to beer! Not surprising that craft beer has taken off in the recent years. We do see a trend, of data science projects being common in such ‘growing markets’ because often even more development can be achieved here. This promises a lot for this project!
What’s next? Modeleren! Op deze dataset maken we een regressiemodel om een set van optimale kenmerken te vinden. Dit zijn de kenmerken van het optimale bier. Hoe wij dit technisch hebben aangepakt lees je in de volgende blog! Bij kenmerken denken wij dan o.a. aan het alcoholpercentage, IBU (bitterheid uit hop), geur, mondgevoel en natuurlijk de smaak combinatie. Met dit regressie model zijn wij bij een optimale set van bieren gekomen van een specifieke bierstijl. Beter gezegd, dit model geeft ons de verhoudingen weer van de best mogelijke smaak combinatie. Deze verhouding geven wij door aan Uiltje. De brouwers kunnen aan de slag, wij kunnen niet wachten.