Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quality facet - Products that should not be in French, based on their brand #2954

Open
Tracked by #10273
teolemon opened this issue Feb 26, 2020 · 2 comments
Open
Tracked by #10273
Labels
🧽 Data quality - Measure - Quality facets One of the facets available in Open Food Facts is /quality & allows us to spot products w/ bad data ✨ Feature Features or enhancements to Open Food Facts server 🧽 Quality - foreign-products-stored-in-french This is a quality issue. It would need to be checked whether it's still significant.

Comments

@teolemon
Copy link
Member

teolemon commented Feb 26, 2020

What

  • Create quality facet for products that should not be in French, based on their brand
  • EG: Conad is an Italian brand, and products are never in French.
  • We see however that products are stored in a variety of languages.
IT_only_brands = {
Conad
}

ES_only_brands = {
	Hacendado,
	Coviran
}

DE_only_brands = {
	REWE,
}

NL_only_brands = {
	
}

for product in all_openfoodfacts_products:
	if product.brand in IT_only_brands and product.language_count==1 and "en:French" in product.language:
		write_quality_facet(italian-products-stored-in-french)
		transfer_language(italian, french, product.code)

https://world.openfoodfacts.org/brand/conad/languages
image

Code pointer

lib/ProductOpener/DataQuality*.pm

Part of

@teolemon teolemon added ✨ Feature Features or enhancements to Open Food Facts server 🧽 Quality - foreign-products-stored-in-french This is a quality issue. It would need to be checked whether it's still significant. 🧽 Data quality - Measure - Quality facets One of the facets available in Open Food Facts is /quality & allows us to spot products w/ bad data labels Feb 26, 2020
@github-actions
Copy link
Contributor

github-actions bot commented Jul 1, 2020

Stale issue message

@github-actions github-actions bot closed this as completed Jul 8, 2020
@teolemon teolemon changed the title Create quality facet for products that should not be in French, based on their brand Quality facet - Products that should not be in French, based on their brand Oct 11, 2021
@benbenben2
Copy link
Collaborator

That would be only for brands that are in a single country. What about the others brands that are in more than a single country?

Do you think that having a list of all brands, each containing a list of countries where they are established may be another option?

Kaufland:

  • de (using language ISO 639-1 abbreviation for languages)
  • pl
  • cs
  • ro
  • sk
  • bg
  • hr

Rewe:

  • de

Currently, 156 350 brands are referenced: https://world.openfoodfacts.org/brands

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🧽 Data quality - Measure - Quality facets One of the facets available in Open Food Facts is /quality & allows us to spot products w/ bad data ✨ Feature Features or enhancements to Open Food Facts server 🧽 Quality - foreign-products-stored-in-french This is a quality issue. It would need to be checked whether it's still significant.
Projects
Status: To discuss and validate
Status: To do
Development

No branches or pull requests

3 participants