Can we/How to provide an array as contextual metadata on GetRecommendation?

0

This is a follow up question after this Question.

I am storing contextual metadata on interaction whose value is an array so it is stored as | separated string. The data stores the users licenses at the time of interaction. User may bought new licenses any time. Say, The definition of the Contextual Metadata on interaction is,

{
          "name": "LICENSES",
          "type": "string",
          "categorical": true
 }

And the data can be "L1", "L1|L3",, or "L1|L2|L3" etc. Where L1, L2, L3 are different licenses. Users may have any combination of them.

Now I want to get Recommendations using GetRecommendation based on that context data. I would like to pass the current licenses user have on the Context. Can I pass the | separated string and get the desired result? For example an user has license L1 and L2,

context = {
      'LICENSES': 'L1|L2'
    }

Now my question is, can we pass context like this? And will it work? I want to show items based on the license users have. On the documentation, it never explicitly says that we can provide such categorical data in context. All the examples use a single string, not a | separated array of strings. So I am wondering if I can pass such | separated array of string on context which would work.

One might suggest filtering the Items based on license. But we want to show items without filtering in our case.

已提問 2 年前檢視次數 256 次
1 個回答
0

Hello,

Thank you for using Personalize Service.

Looking at the questions you have asked along with the follow up question, I believe deeper exploration needs to be done on your use case along. To get better assistance, I'd recommend you to open a case with Premium Support Personalize team so that we can discuss more on the use case along with the implementation required for your use case

Open a support case with AWS using the link:

https://console.aws.amazon.com/support/home?#/case/create

AWS
支援工程師
已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南