Coveo Machine Learning Event Recommendations Deployment Overview

The output of a Coveo™ Machine Learning (Coveo ML) Event Recommendations (ER) model depends on recent user actions history and recorded Coveo Usage Analytics (Coveo UA) search, click, and view events (see Event Recommendations Feature).

The more usage analytics data, the better the recommendations. Therefore, you should start sending view events to Coveo UA as soon as possible (see How Long Do Coveo ML Features Take to Start Improving Relevance?).

Deploying Coveo ML ER requires programming skills.

In a technical documentation site, you could add a People Also Viewed recommendation interface to complement the table of content and suggest articles which are frequently viewed by other users with similar session navigation history. Such an interface is rendered in the right-side panel of each article (including this one) on

To deploy Coveo Machine Learning Event Recommendations (ER)

  1. Optionally, plan the types of content to recommend:

    A Coveo ML ER model can be configured to learn exclusively from usage analytics events pertaining to one or several specific types of content. Therefore, unless you simply want to create a model that outputs generic recommendations, you should plan ahead (see Coveo Machine Learning Recommendation Content Types).

    You want to design a Recommended Articles interface, and a Recommended Courses interface.

    You determine that the Recommended Articles interface should only take the KBArticle content type into account, whereas the Recommended Courses interface should take the TrainingVideo or InteractiveTutorial content types into account.

  2. Optionally, plan the contextual user information to leverage:

    You can determine what contextual user information is relevant to your use-case, and send this data along with each usage analytics event and query to allow your Coveo ML Event Recommendations model to further personalize its output (see Leveraging Custom Contexts in Coveo Machine Learning Features).

    You want the output of your recommendation interfaces to be tailored to the products owned by the end user.

    You determine that you should leverage this contextual user information.

  3. Get an access token:

    You need an access token granting limited privileges to:

    Depending on your use case, you can use either:

    See also Choosing and Implementing a Search Authentication Method.

  4. Send usage analytics events:

    1. Send view events.

      As soon as possible, use the coveoua.js script to start recording usage analytics view events in the web pages which correspond to the indexed items you want to be able to recommend (see Sending Usage Analytics View Events).

    2. Send search and click events.

      Coveo ML ER models can also learn from search and click events originating from other search interfaces configured against the same Coveo Cloud organization. Ensure that all of your search pages are properly configured to send standard usage analytics events (see Getting Started With Coveo Usage Analytics).

  5. Create a Coveo ML ER model and associate it with a dedicated query pipeline.

    For Coveo Cloud organizations that were created prior to April 23, 2019 and did not go through the Coveo ML migration process, create a Coveo ML ER model in a dedicated pipeline.

    • Use a dedicated query pipeline for your ER model to ensure that other search optimization features such as Coveo ML Automatic Relevance Tuning (ART) or query ranking expressions (QREs) do not interfere with the output of the ER model.

    • When you want to power distinct recommendation interfaces (e.g., Recommended Technical Articles, Recommended Experts, Recommended Courses, etc.), configure one model for each planned interface, using a dedicated query pipeline for each model.

    Do not use the Default query pipeline for your ER model. Otherwise, all search interfaces routing their queries to the Default pipeline will essentially break.

    1. In the Coveo Cloud administration console, create a new query pipeline that will contain or be associated with only one ER model (see Adding and Managing Query Pipelines).

    2. Depending on your Coveo Cloud organization creation date (see Review Organization Information):

  6. Include a recommendation interface in your web pages.

    Coveo JavaScript Search Framework 1.667.24 (July 2016) The Coveo JavaScript Search Framework offers a Recommendation component that you can configure in your web pages to create one or more recommendation interfaces (see Integrating a Coveo Recommendation Interface in a Web Page).

    For a Recommendations widget in a ServiceNow service portal, see Configuring a Recommendations Panel.

What’s Next?

You may now want to have a look at an actual code sample to consolidate your understanding of the Coveo ML ER deployment process in a website (see Coveo Machine Learning Recommendations Complete Code Sample).