openfoodfacts / smooth-app

The new Open Food Facts mobile application for Android and iOS, crafted with Flutter and Dart
https://world.openfoodfacts.org/open-food-facts-mobile-app?utm_source=off&utf_medium=web&utm_campaign=github-repo
Apache License 2.0
753 stars 261 forks source link

Propose changing the défaut contribution language when switching countries #5339

Open teolemon opened 1 month ago

teolemon commented 1 month ago

Problem

From Yaron: "Hey everyone, I wanted to raise a concern about the app and web behavior; most of the products documented in Israel have their image tagged as English, even though the product is clearly in Hebrew. Is there a way to configure a default language for image tagging in the app? Is there an easy way to change the language using the web interface? Thanks :)"

Screenshot_20240606-092940.png

monsieurtanuki commented 1 month ago

@teolemon Different topics here.

Should we suggest an app language change when the user changes countries, the way we do with currency? (cf. your screenshot) Small difference: there's one currency per country but potentially several languages.

Should we consider an additional "product language", or a contextual default language? Typical use case: I'm French, I speak a bit of Italian, I visit Italy and scan italian products, and I shouldn't have to switch the whole app to Italian just to consider Italian as the most probable language for each new product image or translation. In that case it's already been deal with in #4996 and its "sticky" language.

Which direction should we go, then?

yarons commented 1 month ago

I also think that the list of languages should be sorted by priority (usage/country/both) instead of alphabetically, I am more likely to document products in the languages I used before rather than browse through the list to the same location and I'm also trying to think of a way to make the user aware of the chosen language before saving, otherwise the default is English regardless of the product language.

monsieurtanuki commented 1 month ago

I also think that the list of languages should be sorted by priority (usage/country/both) instead of alphabetically, I am more likely to document products in the languages I used before rather than browse through the list to the same location and I'm also trying to think of a way to make the user aware of the chosen language before saving

@yarons Somehow already in place since #4996. We could go a step beyond with explicit "user favorite languages" that would always go on top of the language lists.

otherwise the default is English regardless of the product language.

There's no default language, it's always the selected language.

yarons commented 1 month ago

Indeed so what happens is that they're using the app in English, taking photos in Hebrew and they are completely unaware :)

monsieurtanuki commented 1 month ago
@yarons Understood as a different use case (not the tourist case): countries where users would use the app in English (and not in their native language) but with products predominantly not in English. That said, the language is already explicit in the following pages. What are your suggestions? existing image no image
Screenshot_1717746850 Screenshot_1717747170
monsieurtanuki commented 1 month ago

@yarons This is what I suggest: reordering the languages so that the current country languages are more or less on the top of the list. What do you think of it?

yarons commented 1 month ago

Good call! Regarding the misclassified item: if there's a way to try and detect the languages on the product + barcode country and suggest accordingly, it would be awesome, but I know it's too much to ask so let's keep it as a fantasy for now :)

monsieurtanuki commented 1 month ago

Good call!

Thank you! That's rather easy to implement, too.

Regarding the misclassified item: if there's a way to try and detect the languages on the product + barcode country and suggest accordingly, it would be awesome, but I know it's too much to ask so let's keep it as a fantasy for now :)

Don't ask me, ask @teolemon instead, who in those cases typically summons the power of MLKit.

teolemon commented 1 month ago

It's not at all a fantasy, it's an out of the box library for Flutter :-) We already use the scanner component of the library through a Dart package https://developers.google.com/ml-kit/vision/text-recognition/v2