Configuring a Coveo Insight Panel Lightning Component for Cases

Pro and Enterprise editions only

Coveo for Salesforce 3 (May 2018)

Prerequisite

Make sure that you added a Coveo Insight Panel Lightning Component to the Case record page in the Lightning Service Console (see Integrating a Coveo Insight Panel Lightning Component).

Optimizing the Coveo Insight Panel Lightning Component Configuration

The Coveo Insight Panel Lightning Component offers some functionalities that are specific to the Case object type. You should perform these additional steps to get the best of the component.

Since the case you’re currently working on doesn’t need to appear in your results, you can filter it out by following these steps:

  1. On the Case page, click Setup and then select Edit Page.

  2. After clicking anywhere on the Coveo Insight Panel Lightning Component, in the Record Fields, add Case_CaseNumber.

  3. In your Coveo Administration Console, in the Filters tab, click Add Rule.

    1. On the Add a Filter Rule page, under Query parameter, select cq (constant query)

    2. Under Query Filter, add the following code:

      NOT @sfcasenumber=$context.Case_CaseNumber
      
    3. Click Add Rule.

Adding the Coveo Attached Results Component

When used on the Case record page, the Coveo Insight Panel Lightning Component lets you attach search results to the case. The Coveo Attached Results component lists all the results attached to the current case.

To add the component:

  1. Access your Lightning Service Console, and then open any of your cases.

  2. Add the AttachedResults component on the Case record page.

Adding a Coveo Insight Panel Lightning Component to a Live Agent Chat Page

Step 1: Adding a Coveo Insight Panel Lightning Component to a Live Agent Chat Page in Salesforce

  1. Ensure that you have enabled a Live Agent chat page in your Salesforce organization.

  2. In Salesforce, access your Lightning Service Console, and then open any of your Chat sessions.

  3. At the top right of the page, click Settings, and then select Edit Page.

  4. In the Lightning App Builder, on the Live Chat Transcript Record Page, drag and drop the Coveo Insight Panel component to the right side panel.

  5. At the top right, click Save.

  6. Activate the new page, if not already done.

    1. Click Assign as Org Default.

      You can make these changes available as default, or edit the assignment rules to only activate this page for specific users or profiles.

    2. Once you’re done with the assignment rules, click Save.

  7. Now that your page is saved, at the top right of the page, select Back.

  8. In the Coveo Insight Panel component, click Set Up a Search Page.

  9. Choose the tabs that you want to have in your panel, and then select Create Page. You can always change the tabs later.

You should now have a functional Coveo Insight Panel Lightning Component.

Step 2: Configuring the Coveo Insight Panel Lightning Component for Live Agents

  1. In your Coveo Administration Console (see Logging in to Coveo Cloud), select the query pipeline used by your Coveo Insight Panel Lightning Component, and then access the query pipeline Query Parameters tab (see Manage Query Parameter Rules).

    By default, the Coveo Insight Panel Lightning Component uses the Default pipeline.

  2. In the Machine Learning tab, add an Automatic Relevance Tuning (ART) model with the Comply with Intelligent Term Detection (ITD) option selected.

  3. In the Query Parameters tab, add a rule overriding the large query (lq) parameter value:

    1. Click Add Rule, and then select Query Parameters With Code.

      1. In the Add a Rule With Code dialog, in the form editor box, enter the following rule:

        override query lq:"<@+ $context.LiveAgent_AllVisitorMessages +@>"
        

        The context can either be: LiveAgent_LastVisitorMessage, LiveAgent_LastAgentMessage, LiveAgent_AllVisitorMessages, or LiveAgent_AllAgentMessages.

        The LiveAgent_AllVisitorMessages context value provides all the customers messages and context from which Coveo Machine Learning can identify relevant keywords. With LiveAgent_LastVisitorMessage, the previous messages context values are excluded. LiveAgent_LastAgentMessage and LiveAgent_AllAgentMessages context values only show agent results.

      2. Click Add Rule.

    2. In the Action bar, click More, and then select Select condition.

    3. Add a Condition that’s applied when an empty query is performed (see Create a Condition).

      You can use the same query pipeline for both of your Case and Live Agent chat pages, but you have to enter different SearchHub names, typically AgentCase and AgentChat.

      Ensure that, when adding the overriding rules in your Query Parameters for each Coveo Insight Panel Lightning Component, you create a condition Search hub is [SearchHub name] for each Search hub.

  4. Your Query Parameters tab should now look like this:

What’s Next?

Depending on your use case, you must add the custom dimensions to make the search and click events metadata available in your usage analytics reports (see Manage Dimensions on Custom Metadata).

  • For the Live Agent Chat Page: add context_liveagent_allvisitormessages, context_liveagent_allagentmessages, context_liveagent_lastvisitormessage, or context_liveagent_lastagentmessage dimensions.
What's Next for Me?