openfoodfacts / openfoodfacts-server

Open Food Facts database, API server and web interface - 🐪🦋 Perl, CSS and JS coders welcome 😊 For helping in Python, see Robotoff or taxonomy-editor
GNU Affero General Public License v3.0
633 stars 371 forks source link

Handling geo-adjectives in ingredient lists #3086

Open teolemon opened 4 years ago

teolemon commented 4 years ago

Handling geo-adjectives in ingredient lists would enable us to get location for ingredients from the current: cuisse de porc italienne -> fr:cuisse de porc italienne - percent_min: 50 - percent_max: 100 to: cuisse de porc italienne -> fr:cuisse de porc - country: Italy - percent_min: 50 - percent_max: 100 To multiply by all languages having feminine and plural forms of adjectives

fr:singular:masculine:français
fr:singular:feminine:française
fr:plural:masculine:français
fr:plural:feminine:françaises
italien
italienne
italiens
italiennes
espagnole
allemande
polonaise
…
stephanegigandet commented 4 years ago

We can do something like that, but it needs to be done one by one for each adjective in each language:

  1. First do queries like https://fr.openfoodfacts.org/ingredients?filter=italien https://fr.openfoodfacts.org/ingredients?filter=suedois etc.
  2. Find false positives ("pain suédois", "pain allemand", "french toast" etc.) and add them to the taxonomy
  3. Add the adjective.
CharlesNepote commented 4 years ago

Another example: "Pitted california prunes": https://world.openfoodfacts.org/product/0802763331700/ones-amazin-prunes-sunsweet

teolemon commented 4 years ago

I have generated a multilingual list of adjectives for countries using Wikidata: w.wiki/QjV

aleene commented 4 years ago

And add them to the processes/adjectives taxonomy?

Ban3 commented 4 years ago

And add them to the processes/adjectives taxonomy?

I'd suggest a new demonym taxonomy.

teolemon commented 4 years ago

Given the volatility of Wikidata (more demonyms are added overtime, in more languages), I would rather have a conversion pipe rather than a fixed taxonomy. French regions: https://w.wiki/RyT French communes: https://w.wiki/RyX French départements: https://w.wiki/RyZ

github-actions[bot] commented 6 months ago

This issue has been open 90 days with no activity. Can you give it a little love by linking it to a parent issue, adding relevant labels and projets, creating a mockup if applicable, adding code pointers from https://github.com/openfoodfacts/openfoodfacts-server/blob/main/.github/labeler.yml, giving it a priority, editing the original issue to have a more comprehensive description… Thank you very much for your contribution to 🍊 Open Food Facts