Mixing properties of the same entity in the same TextSimilaritySpace #48
-
|
Hello 👋 It would be something like this: The reason for this is that the user can set their desired_product arbitrarily and they may write "Dairy products" rather than "milk", which is much closer to X.product_category. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Hi @miraseus! The general rule of thumb is 1 schema 1 space 1 field, but for your use-case I can currently suggest 3 different approaches, please find them below and feel free to ask any followup questions about each!
text_sim_space = TextSimilaritySpace([user.pref, product.product_and_category_concatenated])
text_sim_space_1 = TextSimilaritySpace([user.pref, product. product])
text_sim_space_2 = TextSimilaritySpace([user.pref, product. product_category])
text_sim_space = TextSimilaritySpace([user.pref, prod_1.description, prod_2.category]) |
Beta Was this translation helpful? Give feedback.
Hi @miraseus!
The general rule of thumb is 1 schema 1 space 1 field, but for your use-case I can currently suggest 3 different approaches, please find them below and feel free to ask any followup questions about each!