HOW TO Filter Products on Open Food Facts by Country (India) Using DuckDB & Superset
Open Food Facts (OFF) is a crowd-sourced database of food products from around the world. Somewhere in the world, a shopper scans the barcode on a packet of biscuits and adds basic product details. Another person photographs a package label for the same product in Hyderabad. A volunteer in France fixes a typo. That's Open Food Facts, a volunteer-built, openly licensed database of food products that's continually changing and growing. Each product is identified by a barcode and carries ingredients, nutrition facts, brands, labels and more. The whole database has millions of products, and let's say you only want the products recorded as being sold or available in one country like India. There are multiple ways to extract a subset of the OFF database. I have already tried using the daily dump available on Hugging Face through Google Colab and GitHub Actions in the past but it blew my mind that using the OFF deployed Apache Superset , you can execute a SQL query in a brows...