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

feat: 785 - list of problematic attributes as score explanation #786

Closed
wants to merge 1 commit into from

Conversation

monsieurtanuki
Copy link
Contributor

What

  • The PR provides, as an option, lists of problematic attributes when the score is not explicit (unknown match, may not match, does not match).
  • With this, we can be more verbose than "It's not OK", and provide localized explanations about the score, e.g. 'Caractère végétarien inconnu' (FR) / 'Vegetarian status unknown' (EN).

Fixes bug(s)

Part of

Impacted files

  • api_matched_product_v1_test.dart: minor refactoring
  • api_matched_product_v2_test.dart: added a test about score explanations
  • api_product_preferences_test.dart: minor refactoring
  • available_attribute_groups.dart: refactored with language instead of language code
  • available_preference_importances.dart: refactored with language instead of language code
  • matched_product_v2.dart: added an optional parameter that lists the problematic attributes when the status unknown, does not match and may not match

Impacted files:
* `api_matched_product_v1_test.dart`: minor refactoring
* `api_matched_product_v2_test.dart`: added a test about score explanations
* `api_product_preferences_test.dart`: minor refactoring
* `available_attribute_groups.dart`: refactored with language instead of language code
* `available_preference_importances.dart`: refactored with language instead of language code
* `matched_product_v2.dart`: added an optional parameter that lists the problematic attributes when the status unknown, does not match and may not match
@codecov-commenter
Copy link

Codecov Report

Merging #786 (43e94f6) into master (5dabb08) will increase coverage by 0.06%.
The diff coverage is 88.23%.

@@            Coverage Diff             @@
##           master     #786      +/-   ##
==========================================
+ Coverage   73.00%   73.07%   +0.06%     
==========================================
  Files         203      203              
  Lines        7417     7472      +55     
==========================================
+ Hits         5415     5460      +45     
- Misses       2002     2012      +10     
Files Changed Coverage Δ
...ersonalized_search/available_attribute_groups.dart 71.42% <66.66%> (-11.91%) ⬇️
...lized_search/available_preference_importances.dart 72.41% <66.66%> (-5.37%) ⬇️
...ib/src/personalized_search/matched_product_v2.dart 84.93% <85.71%> (-0.07%) ⬇️
test/api_matched_product_v2_test.dart 96.74% <90.90%> (-3.26%) ⬇️
test/api_matched_product_v1_test.dart 100.00% <100.00%> (ø)
test/api_product_preferences_test.dart 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@stephanegigandet
Copy link
Contributor

Just curious: where will those explanations be displayed?

@monsieurtanuki
Copy link
Contributor Author

I guess we would be better off trying to code it directly in Smoothie with incremental changes, and different UI/UX.
And then, if relevant, move some code from Smoothie to off-dart.
Therefore, closing here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

Successfully merging this pull request may close these issues.

Listing problematic attributes for obscure matches
3 participants