Wednesday, October 3, 2018

Tea taste profiling and machine testing "tasting"

Part one of this two part post series covered a Singapore tea expo / conference, with input from two participants about how that went.  To me one of the most interesting parts of the theme was them trying out a profile preference mapping approach integrated with the products theme.

Per a photo reference in the last post that Teapasar process surveyed tea aspect range preferences to result in recommendations for attendees for what to try, even narrowed to teas on display at different booths, if I understood that correctly.  Just brilliant!

The natural first consideration is if that would work, and then next if the form they used would work best, versus other types of approaches that might be taken.  Let's start with what they were doing first.

Their related website reference mentions some background on that, but this never does go into a lot of detail, because there is only so much on it there. A couple of Teapasar reference page captures explain the basics behind the profile system:

All of that definitely works, but of course I was expecting something similar to the tasting flavor wheels, like this Tea Masters version:

The full reference description of that Teapasar system (the organizer who held the event, who isn't limited to event production) runs a little into marketing, but it also serves as a background explanation:

Firstly, ProfilePrint can accurately recognise the tea leaves of the same type, whilst being able to differentiate between different tea regions; quality; production methods; and even between different seasons. Such a methodology allows us to authenticate the tea leaves sold by retailers or wholesalers, preventing unfair pricing and misrepresentation. All single-origin teas sold via teapasar’s marketplace will first be authenticated against the origin, and re-tested periodically to verify its purported quality.

Our ProfilePrint methodology also identifies distinct taste profiles of each tea listed on the marketplace. At the same time, when customers create their personalised taste profile online, their unique preferences can then be matched to our database of teas, and the closest matches can be recommended. This allows customers to shop with confidence and discover other blends of tea they may enjoy.

All of that rings a bell, doesn't it?  I get the sense it's really talking about two different things, based on how the content overlaps but isn't the same.  Flavor aspect preference mapping (in the second paragraph) and identifying teas as genuinely from a region in the first paragraph could be regarded as two completely different subjects.  It's easy to see how those two could connect but not as simple to see how they could be exactly the same thing.

This relates to a subject I spent a few months researching last year, tea quality testing and machine "tasting," which never did turn into a finished blog post.  What they are saying here could mean a broad range of different things, extending several steps beyond having a potential customer fill out a preference by aspect survey and matching that to standard tea version descriptions.

Background on tasting and compound types

It would be nice to jump ahead to what machine testing is about but a short aside on different compounds in tea, or those we taste in general, will help clarify what all those testing processes really relate to.  Our process of tasting is complicated, making it not so easy to replicate a lot of it.

It's helpful to start with a tea chemistry basics article from a familiar reference blog site (formerly the World of Tea site, now the Specialty Tea Alliance):

...on the bush, tea leaves contain thousands of chemical compounds, when they are processed, these compounds break down, form complexes and form new compounds. When we steep tea leaves, our senses are tingled by the thousands of volatile compounds (collectively known as the “aroma complex”) from the tea liquor and the thousands of non-volatile compounds and the complexes between them, not all of which are water soluble...

So all of this makes it very difficult to generalize and say that x chemical is responsible for y taste. Many tea chemicals have been categorized into broad groups, and collectively we have some idea of what happens to these groups during processing and what flavors and aromas they are responsible for... 

Of course that does go on to pass on some insight about categories of components:

In steeped tea, polyphenols are largely responsible for astringency...  Flavanols are also referred to as tannins, and during oxidation are converted to theaflavins and thearubigins—the compounds responsible for the dark color and robust flavors notably present in black teas. The major flavanols in tea are: catechin (C), epicatechin (EC), epicatechin gallate (ECG), gallocatechin (GC), epigallocatechin (EGC), and epigallocatechin gallate (EGCG)... 

Amino acids give tea its brothiness, or umami taste. Tea leaves contain many amino acids, the most abundant of which is theanine... 

Methylxanthines in tea include the stimulant caffeine and two similar compounds: theobromine and theophylline...  Methylxanthines also contribute to a bitter taste in the tea infusion...

The rest of that is well worth a read, but those few points cover some basics.  Defining individual flavor characteristics in terms of specific compounds is problematic but defining the broad categories and some generalities works.

It's interesting considering how volatile compounds map onto individual flavors.  The subject is too broad to get far with it, but some summary-level reading up on Wikipedia on aroma compounds connects some of the dots:

An aroma compound, also known as an odorant, aroma, fragrance, or flavor, is a chemical compound that has a smell or odor. A chemical compound has a smell or odor when it is sufficiently volatile to be transported to the olfactory system in the upper part of the nose...

Flavors affect both the sense of taste and smell, whereas fragrances affect only smell. Flavors tend to be naturally occurring, and fragrances tend to be synthetic.[1]

Aroma compounds can be found in food, wine, spices, floral scent, perfumes, fragrance oils, and essential oils…

just a sample; other different types and examples are listed

None of this summarizes just how complex the sensation of taste really is.  At this very low resolution perspective it should be simple to isolate the inputs of taste, identified by the tongue, and aroma, carried by volatile compounds and identified in the rear nasal passages, and map the influence of specific types and levels of compounds to a human perception.  Those are the broad strokes (just skipping "feel" related aspects, chemesthetic compounds or irritants, like astringency) but it's not at all that simple.  

This following reference guide fills in some of the methodology and related complications, even through only reading selected samples in the Google books passage citations:

This is already bridging over from the subject of how we taste into what machines can replicate of that, and why it would or wouldn't make sense to attempt that.  That reference is from 2013; the research scope has surely expanded since that was written, even in that short time, but it seems it would take time for the findings to be applied for food production industry use.  For now there is some limited application for quality control, expanded on more in that reference.

Related to just reading up on the subject of research of machine replicated tasting, it's more a problem that the subject keeps expanding as you look into it, than that there isn't good information out there.  There is a lot of research available about the science behind food tasting, and even the extension of that into research on tea evaluation.  The following section selects some ideas and themes about testing of tea components and flavor compounds relatively randomly, not "backing up" to explain the overall context of sensation in people further, or machine testing related to aspects of those processes.

These ideas were selected for being interesting, not so much because they represent a good overall summary of current research, or of the subject in general.  In reading back over what I had researched on the subject the initial notes and citations amounted to 13 pages, and I quit at that point because the potential scope and material just kept expanding, not due to exhausting what turned up easily.

Machine testing / "tasting" of teas 

Machines can actually "taste" tea now, to a very limited extent.  That ends up meaning a broad range of different things.  One part is that certain aspects (compound type and levels) can serve as a type indicator or quality marker.  Or more generally, but even more complicated in form, a profile of levels of flavor related compounds can be identified (for example, by identifying specific compounds related to volatile compounds and aroma through use of gas chromatography).

It sounds crazy, doesn't it?  The reason I never finished a summary of those findings was because the subject just kept expanding, and there was no way to isolate and simplify parts of it for an easy review.  Here's a citation of part of what I mean, by no means representative of the whole scope of what is currently possible for this type of testing:

In this paper, we have (analyzed using a metal oxide sensor (MOS)-based electronic nose (EN)) five tea samples with different qualities...  The flavour of tea is determined mainly by its taste and smell, which are determined by hundreds of volatile organic compounds (VOC) and non-volatile organic compounds present in tea. Tea flavour is traditionally measured through the use of a combination of conventional analytical instrumentation and human organoleptic profiling panels. These methods are expensive in terms of for example time and labour. The methods are also inaccurate because of a lack of either sensitivity or quantitative information. In this paper an investigation has been made to determine the flavours of different tea samples using an EN and thus to explore the possibility of replacing existing analytical and profiling panel methods... 

It's my impression that what Teapasar is doing falls somewhere in between using surveys and rough summary descriptions, along with spiderweb graphs, which would only relate to the profiling side of the work described here.  It would really be another completely different step to use complex sensors with advance AI processing to replicate more of human tasting, to try to build that part of the analysis into a program.

Parts of the reading of various references on the subject expanded considerably on the comparison role played by combining human taster input with machine results.  Testing can identify what compounds are present but can't necessarily clearly place those related to human perception, as strong versus weak, pleasant versus unpleasant, related to interpretation tied to food items or specific flavors, etc.

The data output by any of the various forms of testing results tends to look like unfamiliar graph forms.  It can be evaluated and summarized as a table of relative compound types, as related to that study output in the following:

Not necessarily familiar, are they?  Referencing back to that Wikipedia aromatic compound page will fill in a little detail, related to the three "linalool" compound types listed:

A clearer description requires a bit more detailed reference, but in general linalool is a subset of linear terpene compounds that represent floral, sweet, woody, or lavender scents.  About the "hexanal":

Aldehydes:  High concentrations of aldehydes tend to be very pungent and overwhelming, but low concentrations can evoke a wide range of aromas.

Acetaldehyde (ethereal)
Hexanal (green, grassy)
cis-3-Hexenal (green tomatoes)...

Really those only work as broad strokes; the next level of detail beyond a Wikipedia page reference would work better for a clearer rough image of what compounds pass on what aroma aspects.

Here are a few other interesting references, articles available for review as free online pdf copies, with more sampling of taste and aroma testing research:

4. Conclusion [final summary]

We have developed a simple, rapid, and reproducible SALDI-MS approach for the determination of the con- centrations of theamine and four catechins using TiO2 NPs as matrices and CAP as internal standard. The SALDI-MS approach was further validated by the analy- sis of tea samples from Taiwan and four other areas.

Each sample has its unique SALDI-MS profile, revealing that the source, harvest region and seasons affect the con- tents of the analytes. The amounts of theamine in the Jin Xuan tea samples from Alishan and Zhushan are much higher than those from other counties (Table 2). Our rapid and simple SALDI-MS approach reveals that the amounts of ECG and EGCG in Taiwanese Oolong tea samples are lower than those from other countries. Our preliminary results suggest that our SALDI-MS profiles shall be useful for the identification of tea samples.

That's back to the first subject raised in the Teapasar cited content, machine testing used to confirm what a tea really is.  It's a different subject than tasting for flavor profile effect but per that reference measuring the relative distribution of compounds in different teas can be used to accurately identify where the teas are from (still in the research phase for most of this material, more an indication the direction is promising in that paper than as a worked-out system).

This next reference covers some similar ground but shifts research further back towards connecting with flavor aspects in teas, with mapping what the machines test back to what humans sense:

The Joint Use of Electronic Nose and Electronic Tongue for the Evaluation of the Sensorial Properties of Green and Black Tea Infusions as Related to Their Chemical Composition

The objectives of the present study were to determine the effects of the brewing method on the amount of the major catechins, methylxanthines, total polyphenols and antioxidant capacity in green and black teas, and to correlate the chemical composition of tea infusions to their sensorial properties by the combined use of the electronic nose and tongue. For this purpose, tea infusions were prepared from 7 green teas and 6 black teas...

 Electronic tongue and electronic nose were able to discriminate green teas from black teas on the basis of their sensorial properties. Considering the taste, green teas were characterized by astringency and aftertaste-astringency and this sensation was increased by prolonging the infusion time; black teas were perceived as more bitter, sour, salty and the extraction time affected the astringent sensation. The aroma of green and black teas was discriminated by specific sensors and the increase of the extraction time produced more richly flavoured infusions. This work adds information about correlation between sensorial properties, antioxidant capacity and chemical composition of green and black teas.

That work is interesting for including a lot of reference data related to different types of compounds in the various teas.  I had referenced it in the past related to reviewing caffeine levels, in a combined table as follows (with "CA" relating to amount of caffeine expressed as mg / gram of dry leaf):

Caffeine does affect taste, but this study is also covering a lot of scope that one might associate with trying to review health effects instead.  This research wasn't about getting machine testing to simulate tea tasting, in the sense of replacing human functions, or even conducting a detailed mapping, but the results are compared to tasting experience in the write-up:

It is known that tea taste is influenced by the processing method and the infusion conditions, which affect the extraction of phenolic compounds and caffeine [5]. The e-tongue score plot (Figure 1(a)) showed the discriminative ability of this device in distinguishing the taste of green and black teas. In particular, green teas, grouped at the left of PC1 (explained variance 56.9%), were discriminated from black teas, which were more dispersed along PC1 and located in the lower part of PC2 (explained variance 28.4%). At the right of the score plot the Bancha Tostato Hojicha tea (G1-G2) was completely separated from the other green teas. Moreover, different teas of the same type (for example different green teas) were not overlapping each other, indicating the sensitiveity of the e-tongue. From the loading plot (Figure 1(b)), it can be noticed that green teas were characterized by astringency and aftertaste-astringency, while black teas were perceived as more bitter and sour and were also characterized by saltiness and aftertaste-bitterness. Concerning Bancha Tostato Hojicha tea (G1-G2) its taste was similar to Grand Keemun black tea (B5-B6); these two samples were perceived as the least astringent and  the most bitter.

Figure 1a. Principal component analysis of electronic tongue data: Score plot of green and black teas defined by the first two principal components.

A bit different format than my tea review tasting notes.  It is possible to take different types of testing even further, to explore how individual compounds beyond these being measured there relate to a range of other flavors experienced, by measuring aromatic compound components.

This is all drifting away from the initial subject of machine testing / "tasting" teas, isn't it, as much into quality control range.  That study focused on broad types of compounds and general attributes, which worked to describe tea character in a limited sense but not necessarily what different teas taste like, related to individual flavor aspects.  Another reference shifts back to replicating human taste, it just doesn't get far for completeness related to that:

Discrimination of Green, Oolong, and Black Teas by GC-MS Analysis of Characteristic Volatile Flavor Compounds

I won't do this paper justice but a citation of the intent and then a bit of results is interesting, with that link leading to a complete download version of the paper for further review.

...In our study, we collected more than 38 kinds of tea products including green teas, oolong teas, and black teas from different production areas, investigated their volatile compounds to study the different manufacturing processes on the tea aroma profiles as well as relationships between particular processes and tea aroma compounds.  We aimed to develop a fast method to determine the origin based on profiling of volatiles by GC-MS and statistical analysis.

So back to the type mapping and origin study idea, with some parts of that paper easier to follow than others.  Not so far in a type of characteristics mapping turns up, back to the theme of flavor profiling that started this review:

In a limited sense this is a simple measurement, summary, and mapping function of flavor related elements in different teas.  It's not quite that simple, and only goes so far, identified by a citation related to the role and types of volatile compounds:

In general, the aroma profiles of black teas and oolong teas are more complex than the ones of green teas. In green tea fewer volatiles can be found and among the 200 volatiles about 30 compounds essentially contribute to the typical green tea aroma [5] [6]. Besides short chained alcohols and aldehydes, geraniol, linalool, 2-phenylethanol, benzyl alcohol, indole, and coumarin lead to green tea aroma. In black tea infusions about 600 constituents have been identified and 41 compounds importantly  contribute to the aroma of black tea infusions [11].

Interesting!  Reading further about the different compounds is also interesting, but it doesn't map back directly to ordinary experience very well:

Several of these important aroma compounds have been found in all kinds of black tea, among them Z-3-hexen-1-ol, linalool and its oxides, geraniol, and 2-phenylethanol contributing to the green, citrus-like, rose-like and honey-like notes, respectively. Linalool and its oxides, benzylalcohol, and 2-phenylethanol were detected as volatiles in all oolong teas. Although contents of most volatiles in black teas are higher than oolong teas and green teas, jasmine lactone and indole were the highest in oolong teas. Both volatiles possess jasmine-like floral and fruity fragrances and importantly contribute to oolong tea aroma [12]. This result is identical with previous reports [13]. Methyl salicylate, previously described as characteristic aroma component of oolong tea, has been only found in some teas of Chinese Taipei (Table S1 No. 7, 8, and 10) or Japanese (Table S1 12 and 13) origin [14].

So not much overlap with ordinary language and ordinary taste experience, but it does seem like the description of the role of different compounds in tasting can be pushed down to a lower and more specific level.  It just can't be a complete mapping, yet; a machine can't replicate our experience of taste, with the results more in the form of a summary of chemical proportions than main and secondary flavors.  They can make a good start, though, with the final interpretation step still requiring more development work.  One recurring question and theme that keeps coming up is why to do it, why to get a machine to replicate tasting, which I will get back to.

Initial conclusions

When I first considered whether or not a machine could "taste" tea it seemed to me that of course they couldn't.  Even if testing could identify main compound types and specific levels of very clearly identified specific molecules, mapped directly to aspects that people taste, there would have to be severe limits to what testing results could determine.

Two things in particular came to mind that a machine couldn't do:

1.  identify the role of all potential "off" flavor related compounds.  A testing process could identify standard compounds and flavor contributions, the typical positive flavor-related compounds that occur in different types, but couldn't map out everything that might conceivably be in tea, and how some of it might throw off a standard positive profile.

2.  mimic subjective interpretation of overall balance of flavors and compounds present.  When we taste we summarize how well it all works together, how the unique mix of aspects "works" to us, and it would seem that a machine or testing and analysis process would have problems replicating that.

That earlier cited reference, Instrumental Assessment of Food Sensory Quality: A Practical Guide, adds a concern to the second issue, beyond the problem with mapping out what the flavor impact of every single compound might be, especially in different combinations (on page 56 of the sample text):

...laboratory instrumentation is not as sensitive to many odors as is the human olfacotry system.  It is widely accepted that as few as 8 molecules of a potent oderant can trigger one olfactory neuron and that only 40 molecules may provide an identifiable sensation...

Even though that text source only sites samples of the entire book it's well worth a read, and for those more interested in the subject obtaining the book may be.  As I interpret this well beyond the problem that machine testing can't even match human sensation the interpretation step that comes after this, mapping all potential volatile compounds to effects, makes for a second impossible task.

Of course machine "tasting" research is really back on the basics; identifying what we do when we taste, which more basic or standard compounds cause which reactions or interpretations, and setting up testing processes to copy that.  With advanced enough testing procedures and interpretation (AI / artificial intelligence interpretation) most if not all of what we are doing could be replicated.

That testing process, software, and related data set would need to be just as experienced as a human taster to get there, with input across trying thousands of samples of teas.  It would have to somehow map each related input and sets of compounds to actual subjective interpretations by experienced human tasters.  It would have to be drilled down to component by component analysis, and mapped back up to how countless combinations were experienced by people, somehow accounting for individual preference / subjectivity, at least to some extent.  It's all a nearly impossible task, at present, or really completely impossible based on current capabilities.  But of course it will become possible, it's just a matter of when.

Most of what is currently possible was developed in the last 20 years, it seems, at least related to advanced forms of testing equipment, software, testing methodology, and analysis in use.  In 20 more years there will be development work in progress on what we can only imagine to be possible today.  How long until an apparently sentient program can discuss tea tasting with us, and move beyond human capability?  Who knows.  It's more interesting to consider what is possible now, even if the research doesn't make for light reading.

Another starting point on profile mapping

It's difficult to summarize the extent to which any of this flavor profile mapping works, either the relatively simple Teapasar Singapore expo event version, informed by questionnaire input, or any version based on test results.  The cumbersome and problematic verbal aspect category descriptions of teas in review formats seem to go a lot further now.  But people are working on that, providing summary formats that go further, even onto attempting a more complete and objective assessment.  It starts with coming at the problem from different directions, using more basic tools to collect and present data.

I first heard about the project of mapping out tea aspects in graphical form related to the Penn State Tea Institute's work on exactly that.  It's not related, but I first graduated from PSU, an age ago, as an Industrial Engineer.

visiting back at PSU nearly two years ago now

This article covers some of that early background:

In a small house in State College, a group of college students and recent graduates sip Bolivian black coffee... After each one takes a sip, they record the flavors they taste on a circular graph via a mobile application they built from scratch.

This is a daily tasting at the Hacker House, the nickname given to the home and office of Analytical Flavor Systems (AFS). AFS is a Penn State startup bringing technology to the artisan beverage industry (coffee, beer and tea) with its unique quality control system, the Gastrograph.  AFS was founded in 2011 by Jason Cohen who was later joined by John Dori...    The duo met at the Tea Institute at Penn State, a part-tea house, part-research lab that Cohen founded as a student in 2010.

Gastrograph microbrew beer mapping (details and photo credit)

A Guardian article titled "Tastemakers: Can a robot really know what we’ll want to eat?" goes into how the related graphic mapping works:

...Analytical Flavor Systems’ main data collection tool is its smartphone app, Gastrograph. The app’s central feature is a wheel with 24 spokes, where each sliver represents a discrete category of sensory experience – such as “meaty”, “bitter” or “mouthfeel”. Tasters map the contours of flavor perception by tracing the spokes corresponding to the qualities they detect, designating the intensity of each on a scale from one to five. A submenu allows for a more granular record of experience: specifying that “meaty” quality, for instance, as beefy, sausage-like, or more exotic options (moose, kangaroo). Tasters are then prompted to give the product a preference rating, on a scale from one to seven.

That article goes further than short citations here could about the overall vision and goals, also covering the opposing view, related to problems with the approach taken.  But this second citation does map out some of the broad strokes, based on an author's summary of that interview input from Jason Cohen:

Ultimately, what Analytical Flavor Systems is selling is not a food or beverage: it is a descriptive picture of experience, a predictive image of desire, and a vision of a food system fragmented into niches of highly attached consumers. If the future is, as its founders say, in foods optimized to our most personal appetites, the company’s success will ultimately depend on the Gastrograph’s ability to tell food and beverage companies what you will love, the flavors that you won’t be able to live without – and to do this more accurately, efficiently, or cost-effectively than established companies...

They're not moving into machine tasting as one foundation for setting this up, it doesn't seem (the main theme addressed in the rest of this post), but the work is interesting nonetheless.  Starting from much more sophisticated mapping of how people experience and communicate flavors may turn out to be a productive step towards meeting up with machine testing and tasting results once the two scopes are mapped onto each other better later.

Those two themes didn't necessarily connect as well as they might have in this blog post.  As of now tea aspect profile mapping is something people can do, with limited coordinating help from application tools like the Gastrograph program.  Eventually machine testing could support that, or potentially in the very long run replace it.  For now using testing to confirm a tea version is from a certain region seems more promising.  Exploring use of individual measured aspects as quality markers is still just an interesting idea, and actually replicating more of tasting in the form people do that seems pretty far off.


  1. I still don't understand where is the biz idea?

    1. That's a good question, and one I didn't really get to addressing much in this post. My understanding is that the Gastrograph (AFS) company does commissioned focus group studies. The graphing part doesn't add much value or play all that central a role. The Tea Pasar company is an ordinary tea vendor and event organizer, and the mapping theme is just part of participants' event guidance. It wouldn't change much. They do further study in a different form that's not commercially developed, but for all I know that may not ever make it out of academic application. It's strange saying there is almost no commercial point but that's my understanding.