The prototype detected capsaicin and pungent-flavored compounds - such as those behind garlic’s "zing" - in a range of foods.