Recommendation for more than one last viewed item

73 views Asked by At

Currently I have a Recommendation block (Recommendation logic- items with similar attribute) at home page. Here the entire block get tuned and limit the suggestions only to the last viewed item. I wanted to increase the recommendation (incoming feeds) for atleast last 2 or 3 viewed items.
**For example-**Currently If user visits items Z > Y > X then the recommendation blocks gets filled with items which has similar attribute only to item "X" (leaving last to last viewed). I would like to explore the possibility of recommendation block having track of items Z, Y and X.

1

There are 1 answers

0
Mike Van Stan On

You would have to push multiple entity.IDs within your targetPageParams() function so the algorithm can generate based off of that.

Here's an example snippet I made whereby I'm excluding items (in a JSON format) already viewed:

<script type="text/javascript">         
        targetPageParams = function()
        {
            return { "excludedIds": [] }
        }
    </script>