Categories are the general groups in which the products belong. The main identifier is “categoryID” by default.
Each product has to belong to exactly one “categoryID”.
Sources of categoryID in a page
Categories are composed from the following sources:
- If a page sends an event containing “categoryID”, Persoo assumes that the page belongs to that category. It is generally a list of products from the given category, or it is a product detail page with the given category.
- If the “categoryID” is missing, Persoo looks for a field “itemID” (i.e. the product ID). If found, Persoo assumes that the “categoryID” of the page is the same as “categoryID” of the current product.
- If no “categoryID” or “itemID” is sent, Persoo will not attribute any category to the pageview/other event. In this case, algorithms with conditions such as “category that is currently viewed” will not work, since there is no “currently viewed” category.
Categories registered by Persoo
By default, Persoo will ackowledge the existence of categories, whose categoryID exists at at least one product in the Product Feed. In addition, Persoo will add categoryID of the categories present in the Category Feed (if provided).
Only categories, whose categoryID has been acknowledged, will have calculated values, such as “alsoViewed90”, “alsoBought30”, “buyTrend” etc.
Some e-commerce sites use virtual categories, so they can assign more than one category to a product.
This might cause some confusion in the data.
The problem generally happens when the virtual categoryID does not exist in the Product Feed or Category Feed.
Take the following example: A Samsung phone X exists in two category trees, one “real” and one “virtual”:
“Real”: Phones and Tablets – Phones – “Smartphones” – Samsung X
“Virtual”: Samsung – Samsung Phones – Samsung X
If we visit the Product Detail page from the “virtual” category, it might happen, that the categoryID is “Samsung Phones”. But since this category does not exist in either Product or Category Feed, Persoo system will not have available stats for the given category. Therefore, conditions such as “category is also viewed in last 90 days with category that is currently viewed” will not have any effect.
The solution is to provide a Category Feed that includes all categories, including virtual.