Researchers Say This AI Can Spot Unsafe Food on Amazon Faster Than the US Food and Drug Administration

By Andrew Liszewski on at

It’s been most famously used to swap celebrities into movies and even erase unwanted moustaches, but the real power of artificial intelligence is its ability to spot patterns in large amounts of data and make startlingly accurate predictions. Researchers at the Boston University School of Public Health have now trained a deep learning AI to find dangerous food items potentially needing a recall by analysing reviews on Amazon’s website.

In a study published yesterday in the Journal of the American Medical Informatics Association, the researchers detail the steps they went through to train their neural network, which started with the arduous task of collecting 1,297,156 reviews of food products sold on Amazon.com and then matched 5,149 of them to products that had been officially recalled by the US Food and Drug Administration (FDA) between 2012 and 2014.

The next step was to teach a type of deep learning AI known as a Bidirectional Encoder Representation from Transformations—or BERT, for short—to spot telltale terminology in these reviews that could indicate a product was legitimately unsafe. That required real people to sort 6,000 of the collected reviews that contained the same words and terminology the FDA used to justify recalls (like “sick,” “rotten,” and even “label”) into four different categories. Those included if the reviewer got sick, had an allergic reaction, or found an error in the product’s labelling; the product looked or tasted bad, was expired, or needed further inspection; the reviewer made no claims the product was unsafe; or none of the previous three categorisations.

Using the sorted reviews, as well as additional information like the review’s title and the number of stars the reviewer gave the product, the BERT AI was able to correctly identify which foods had been officially recalled by the FDA with around 74 per cent accuracy. But it also managed to identify red flags in over 20,000 other food products, most of which have yet to be officially recalled.

There are certainly some concerns to be raised over relying on reviews from a public forum such as Amazon to identify products potentially requiring a recall. Sorting real reviews from fake ones posted by an angry consumer trying to be vindictive, or even another seller trying to harm the competition, is just as challenging a task, and the AI’s results could potentially be swayed by someone who figures out how to game the criteria it’s relying on.

But it’s a step in the right direction. Government agencies like the FDA are slow-moving beasts, and undoubtedly have to pour through thousands, if not millions, of complaints before investigating, confirming, and taking action—and that’s just when it comes to food. Given the breadth of Amazon’s catalogue and its user base, an AI like this could spot problems with almost any kind of product and speed up the process of identifying which need to be further investigated and eventually recalled. It could even put pressure directly on manufacturers to voluntarily investigate widespread claims and recall their own products before a government agency has to use up valuable resources to step in and require them too.

Featured image: Screenshot: Amazon