Scientists have developed a first-of-its-kind smart underwear to track how often people actually fart, an advance that could lead to new insights into human metabolism.

Until now, tracking human farts in studies has mainly relied on participants’ self-reporting their flatulence, which has been unreliable as people tend to forget, miscount, or don’t consider tiny gas releases.