Product DocsMenu

Adding Thesaurus Entries From the Administration Tool

The CES thesaurus is a list of related or equivalent words used to expand queries. The thesaurus transparently adds expressions to the search, thus returning more results that would otherwise be missed. You can easily populate the thesaurus using the Administration Tool (see Thesaurus Best Practices).

Example: The thesaurus is useful to expand queries for abbreviations. When a user enters the short form of an expression like XML, the thesaurus adds to the query the long form of the expression like extensible markup language, thus returning results containing either form of the expression.

Note:

To add a thesaurus entry

  1. On the Coveo server, access the Administration Tool (see Opening the Administration Tool).

  2. In the Administration Tool, select Index > Thesaurus.

  3. In the navigation panel on the left, click Keywords.

  4. In the right pane, click Add.

  5. In the Add Thesaurus Keyword page:

    1. In the Keyword box, enter the word or exact phrase for which you want to enter one or more synonyms.

      Example: To add bob to the query robert, enter robert as the keyword.

    2. In the Synonyms box, enter one or more words to add as synonyms of the keyword. When entering more than one synonym, enter one entry per line. You can enter an exact phrase.

      Example: To add bob to the query robert, enter bob as the synonym.

      Note: You cannot use search prefixes or operators such as OR, AND, or NEAR (described in Search Prefixes and Operators) to define Keyword and Synonyms.

    3. In the Option section:

      • Clear the Use the synonym relationship advanced rule check box to use the basic relationship rule that adds the synonyms to the keyword using the OR operator.

      OR

      1. Select the Use the synonym relationship advanced rule.

      2. Select Replace the keyword by its synonym to replace the keyword by the synonym. This synonymy rule allows only one synonym per keyword.

        Note: You cannot use the same keyword twice, meaning that a specific keyword can only be contained in one rule.

        Example: A query for robert becomes bob.

        OR

        Select Establish reciprocal synonymy between the keyword and its synonyms to add the synonym to the keyword using the OR operator and vice versa.

        Example: A query for robert becomes robert OR bob and a query for bob becomes bob OR robert.

        Note: Selecting this option is equivalent as setting the attribute bidirectional=true for the mapping tag in the XML thesaurus file.

    4. In the Collection box, you can select one or more collections that must be specifically selected for search in a .NET Interface Editor to allow the thesaurus entry expansion. By default, no collection is selected, meaning that the thesaurus entry is always expanded (for all collections), in any Coveo .NET Front-End search interface.

      Important: The conditions required to make this feature work (explained in this step) are not obvious and often misunderstood, leading to thesaurus entries not taking effect. The easy solution to ensure a thesaurus entry takes effect is to clear all collection check boxes.

      Note: A Coveo .NET Front-End search interface specifically selects one or more collections for search when its scope does not include all available collections. You can see and set the scope of a Coveo .NET Front-End search interface from the .NET Interface Editor in the Search Interfaces > FeaturesScope page. In this page, for thesaurus entry collection restriction to work, under Available Collections, select one or more (but not all) collections, and under Scope Configuration, select No Scope (see Configuring the Scope of a .NET Search Interface).

      Example: In the Administration Tool, you create a thesaurus entry for robert and bob, and only select the R&D collection.

      In your Coveo .NET Front-End R&D Stuff search interface that includes the R&D collection in its scope, the query robert is expanded to bob.

      In your Coveo .NET Front-End Human Resources search interface that does not include the R&D collection, the query robert is not expanded to bob.

      In the default Coveo .NET Front-End All Content search interface, that by default includes all collections and does not specifically select collections for search, the query robert is not expanded to bob. However, if you use the Advanced Search page to select one or a few available Collections including the R&D collection, then the interface specifically selects these collections and the query robert is expanded to bob (see Using the Advanced Search Page in .NET Search Interfaces).

      In the Administration Tool, when you select one, a few, or all available collections for a given thesaurus entry, the thesaurus entry is expanded when at least one of the selected collections are selected for search in a given .NET Interface Editor, and the thesaurus entry is expanded for all collections included in the scope of the .NET Interface Editor.

      Example: Your index is made of 5 collections (A, B, C, D, E). You assign a thesaurus entry to collections A and B. In a Coveo .NET Front-End search interface with a scope that includes collections B, C, and D, the thesaurus entry is expanded for documents from collections B, C, and D.

      Important: Currently, a Coveo JavaScript search interface cannot specifically select one or more collections for search. Consequently, a thesaurus entry for which you selected one or more collections will never be expanded in a Coveo JavaScript Search interface.

      When your Coveo deployment includes only Coveo JavaScript Search interfaces (no Coveo .NET Front-End search interfaces), do not select collections. Rather use the thesaurus feature available from the REST Search API (see Thesaurus).

      Note:

      • CES 7.0.7256– (December 2014) Selecting all collection check boxes results in the thesaurus entry being applied for none of the collections. This issue was corrected in CES 7.0.7338 (January 2015 release).

      • CES 7.0.6607– (April 2014) The Collection option is a drop-down list where you can select either All Collection, the default, or one specific collection.

    5. Click Save.

  6. Refresh the thesaurus (see Refreshing the Thesaurus).

People who viewed this topic also viewed