Implementing Algolia Recommend
On this page
Algolia Recommend generates recommendations based on user behavior, for example, products that are often bought together, or products that are often looked at in the same context.
Capturing your user events with the Insights API
To generate recommendations, you need to collect enough click and conversion events. Implementing events requires coding.
Training the machine learning models
- Go to Recommend in the Algolia dashboard.
- Select your Algolia application, for which you want to implement Algolia Recommend.
- Select the models you want to use for recommendations amongst Frequently Bought Together, Related Products, Trending Items, Trending Facets.
-
Click Start using.
- Select the main index from which recommendations should be generated. Optional: You can add replicas of the main index to train the machine learning model with more events.
-
Collect user events:
- Frequently Bought Together requires at least 1,000 conversion events with two or more items per user within the last 30 days.
- Related Products requires at least 10,000 click or conversion events within the last 30 days.
- Trending Items and Trending Facets require at least 5,000 conversion events within the last 30 days.
You can’t start training the model, if you haven’t collected enough events.
-
Click Start training to train the selected machine learning models.
-
After training is complete, you can preview the recommendations by searching for items from your index and checking the recommendations in the Preview section.
Each recommendation comes with a confidence score between 0 and 100. The higher the score, the more relevant the recommendation is.
Integrating recommendations into your front end
After you configured Algolia Recommend in the dashboard, your front-end engineers can integrate the recommendations in your front end. Your team can leverage Algolia’s Recommend UI component libraries, available in JavaScript and React, or use one of Algolia’s API clients.
You can choose how many recommendations to show. The Algolia models generate a maximum of:
- Frequently Bought Together: 3 recommendations
- Related Products, Trending Items, Trending Facets: 30 recommendations