-
-
Notifications
You must be signed in to change notification settings - Fork 400
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Synonyms in taxonomized suggestions (#9395)
When creating suggestions for taxonomized fields like categories, the API gives back results where one of the synonyms match. However, they are not displayed when they don't include the typed string. This tries to fix that by returning which synonym the input matched to build the suggestions list.
- Loading branch information
Showing
7 changed files
with
217 additions
and
35 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
...expected_test_results/api_v3_taxonomy_suggestions/allergens-string-fr-o-get-synonyms.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
{ | ||
"errors" : [], | ||
"matched_synonyms" : { | ||
"Arachides" : "Cacahouètes", | ||
"Crustacés" : "Homard", | ||
"Fruits à coque" : "Fruits à coque", | ||
"Gluten" : "Orge", | ||
"Lait" : "Lactose", | ||
"Mollusques" : "Mollusques", | ||
"Moutarde" : "Moutarde", | ||
"Poisson" : "Poisson", | ||
"Soja" : "Soja", | ||
"Œufs" : "Œufs" | ||
}, | ||
"status" : "success", | ||
"suggestions" : [ | ||
"Gluten", | ||
"Œufs", | ||
"Arachides", | ||
"Crustacés", | ||
"Fruits à coque", | ||
"Lait", | ||
"Mollusques", | ||
"Moutarde", | ||
"Poisson", | ||
"Soja" | ||
], | ||
"warnings" : [] | ||
} |
Oops, something went wrong.