Every year, 14.5 trillion cigarette butts end up as litter around the world. The tiny pieces of trash end up all over the place but, in one case, they ended up in the hands of a four-year-old on Scheveningen Beach on the Netherlands coast. So his dad decided to do something about it.

Together with his fellow entrepreneur Martijn Lukaart, the boy’s father, Edwin Bos, created the Beach Bot, an autonomous robot that combs beaches looking for cigarette butts in the sand using artificial intelligence.

The robot uses cameras to look through the sand and pick out cigarette butts that it then picks up using a pair of… well, they really do look like combs. It then stores the butt to be thrown out at an appropriate disposal site. And the locals are on board.

Read Also: Honda Introduces Grass Miimo, Its Improved Robot Mower

“I want my kids to be able to sit barefoot in the sand without any glass or cigarette butts lying around,” Oscar de Grave, who lives near Scheveningen Beach told Microsoft, which is providing help on the project. “A clean beach is very important to me.”

Unfortunately, the problems that cigarette butts pose run deeper than simply being gross. Cigarette butts take 14 years to disintegrate and have become “the most frequent form of personal item found on beaches,” according to a 2019 study out of Brazil. Full of microplastics and chemicals, they are “very toxic,” according to a study from February by U.S. government scientists who also found that they are a major hazardous waste problem.

Fortunately, with help from the Microsoft Trove app, people can submit photos of beach scenes and get paid 25 cents per accepted photo. The photos are then analyzed for cigarette butts, which helps the Beach Bot find them in real life.

“The bot does all the legwork. It goes to the beach, and it is the hero of cleaning,” de Grave adds. “But to clean, it needs all these people to give it consistent data input. Without that, the bot will run into new situations it doesn’t understand. Machines like this only work because of people.”

In its first demo, last September, the Beach Bot was able to pick up 10 cigarette butts in 30 minutes and it has a battery that lasts about an hour. For its next demo, it will have two smaller scout bots that simply look for the butts and tell it where to go with a vision of someday helping get more than just cigarettes off the beach.

“We start with cigarette butts. That’s the world’s most littered item,” Bos said. “In the future, we want the robots to detect a range of other litter.”