Create a Ranking Policy

A ranking policy enables you to control the ranking of indexed items matching a search query in Oracle Content Management. You must be a content administrator to create and manage ranking policies.

To create a ranking policy:

  1. Sign in as a content administrator in your browser and click Content under Administration in the left navigation menu.
  2. Choose Ranking Policies from the drop-down list, and then click Create.
  3. Enter a name for the ranking policy.

    Note:

    The API Name is generated automatically based on the ranking policy name you entered, or you can overwrite the auto-generated name. You would use the API name to invoke the ranking policy when using REST API calls.
  4. Enter an optional description explaining what the ranking policy should be used for.
  5. Build your ranking policy by adding methods. Click Add Method, and select a method:
    • Boost - Phrase Match: This method increases the relevance score of items returned by the search request only if the phrase values in the selected asset types match the values assigned below (MT operator is applied).
    • Boost - Equals: This method increases the relevance score of items returned by the search request only if the data field values in the selected asset types exactly match the values assigned below (EQ operator is applied).
    • Pin - Equals: This method sets the topmost relevance to items returned by the search request only if the data field values in the selected asset types exactly match the values assigned below (EQ operator is applied).
    • Pin - Phrase Match: This method sets the topmost relevance to items returned by the search request only if the phrase values in the selected asset types match the values assigned below (MT operator is applied).
  6. When you're done, click Save.

Here are some things to consider when creating a ranking policy:

  • If you enter more than one value in your method, the ranking policy will be applied if either value matches the returned item (OR is applied). For example, in an equals method, if you have two values (value-1 and value-2) for a field (field-1), the ranking policy would be applied if field-1 EQ value-1 OR field-1 EQ value-2.
  • For boost methods, if a returned item matches more than one field in the method or more than one boost method in the ranking policy, the relevance score is boosted (multiplied) for each match. For example, say you have a method with a boost value of 20, and it includes field-1 and field-2. If a returned item matches a value for both field-1 and field-2, the original relevance score would be multiplied by 20 for the field-1 match and then multiplied by 20 again for the field-2 match. Another example, if an item matches method-1 with a boost value of 20 and method-2 with a boost value of 30, the original relevance score would be multiplied by 20 for the method-1 match and then multiplied by 30 for the method-2 match.
  • For phrase match methods, the phrase value can appear anywhere in the data field. For example, if you enter a value of "capital city", it will match if the data field value is "The capital city of France is Paris" or "Palermo is the capital city of Sicily".

When the ranking policy is finalized, you must promote it to make it available to be assigned as a publishing channel default. If you want to assign the ranking policy as the global default, you must first publish the ranking policy.

Boost - Phrase Match Method

The 'boost - phrase match' method increases the relevance score of items returned by the search request only if the phrase values in the selected asset types match the values you enter in the method. (MT operator is applied).

To configure a 'boost - phrase match' method:

  1. Enter a name for the method.
  2. Enter an optional description describing what the method does.
  3. Enter a Boost Value between 10 and 100. This determines the amount the relevance score is boosted (multiplied) by.
  4. Select an Asset Type and Data Field to which the method will be applied. Enter a Weight between 0 and 10. Items with value matches for this asset type and data field will have their relevance score boosted by the boost value multiplied by the specified weight.

    For example, say you have a method with a boost value of 20, one field (field-1) with a weight of 10, and another field (field-2) with a weight of 1. Returned items that match field-1, will have their original relevance score multiplied by 20 for the boost value and then multiplied by 10 for the field weight, for a total boost of 200 times the original relevance score. Returned items that match field-2, will have their original relevance score multiplied by 20 for the boost value and then multiplied by 1 (no change) for the field weight, for a total boost of 20 times the original relevance score.

    To apply the method to the standard fields (asset name or description) available in all asset types, select Any as the asset type.

  5. To add additional data fields, click Add icon, and select the asset type and data field.
  6. Enter the values to be matched against the selected data fields. Enter a word or term, and then press Enter to add it.

    The phrase value can appear anywhere in the data field. For example, if you enter a value of "capital city", it will match if the data field says "The capital city of France is Paris" or "Palermo is the capital city of Sicily".

    If you enter more than one value in your method, the ranking policy will be applied if either value matches the returned item (OR is applied). For example, if you have two values (value-1 and value-2) for a field (field-1), the ranking policy would be applied if field-1 MT value-1 OR field-1 MT value-2.

  7. When you're done, click Save.

Boost - Equals Method

The 'boost - equals' method increases the relevance score of items returned by the search request only if the data field values in the selected asset types exactly match the values you enter in the method (EQ operator is applied).

To configure a 'boost - equals' method:

  1. Enter a name for the method.
  2. Enter an optional description describing what the method does.
  3. Enter a Boost Value between 10 and 100. This determines the amount the relevance score is boosted (multiplied) by.
  4. Select an Asset Type and Data Field to which the method will be applied. Enter a Weight between 0 and 10. Items with value matches for this asset type and data field will have their relevance score boosted by the boost value multiplied by the specified weight.

    For example, say you have a method with a boost value of 20, one field (field-1) with a weight of 10, and another field (field-2) with a weight of 1. Returned items that match field-1, will have their original relevance score multiplied by 20 for the boost value and then multiplied by 10 for the field weight, for a total boost of 200 times the original relevance score. Returned items that match field-2, will have their original relevance score multiplied by 20 for the boost value and then multiplied by 1 (no change) for the field weight, for a total boost of 20 times the original relevance score.

    To apply the method to the standard fields (asset name, description, or published date) available in all asset types, select Any as the asset type.

    Note:

    Large text fields aren't supported for the 'boost - equals' method.
  5. To add additional data fields, click Add icon.
  6. Enter the values to be matched against the selected data fields.
    • Text values—Enter a word or term, and then press Enter to add it.
    • Numeric values—Enter a numeric value, and then press Enter to add it.
    • Data and time values—Click the date box or Calendar icon to select a date, time, and time zone. Enter an offset of 1 or greater and a period of time to create a range to which the boost will be applied. For example, if you select December 1, 2021 and enter an offset of 10 days, returned items will match if their date value is between December 1, 2021 and December 11, 2021.

      To add additional date and time values, click Add icon.

    If you enter more than one value in your method, the ranking policy will be applied if either value matches the returned item (OR is applied). For example, if you have two values (value-1 and value-2) for a field (field-1), the ranking policy would be applied if field-1 EQ value-1 OR field-1 EQ value-2.

  7. When you're done, click Save.

Decay - Date Method

The 'decay - date' method decreases the relevance score of items that are returned by the search request. An item's relevance score decreases as the selected asset type's date value gets further away from the origin date and offset. The rate of decrease is defined by the specified decay rate and scale.

To configure a 'decay - date' method:

  1. Enter a name for the method.
  2. Enter an optional description describing what the method does.
  3. Enter a Decay Origin by clicking the date box or Calendar icon to select a date, time, and time zone. This will be the middle of the date range to which the relevance score will remain unchanged (no decrease will be applied).
  4. Enter a Decay Rate between 0.1 and 1.0. This determines the amount the relevance score is decreased by. For example, if the original relevance score is 10, and your decay rate is 0.5, the fully applied decay rate would decrease the score to 5 (10 x 0.5 = 5).
  5. Enter a Scale of 0 or greater and a period of time. This determines how rapidly the decrease in relevance score approaches 0. Returned items with values within the scale range ('decay origin' - 'offset' - 'scale' to 'decay origin' + 'offset' + 'scale') will have half the decay rate applied. Returned items with values outside the scale range will have the full decay rate applied.
  6. Enter an Offset of 1 or greater and a period of time. This determines the beginning and ending of the date range to which the relevance score will remain unchanged (no decrease will be applied). Returned items with values within the offset range ('decay origin' - 'offset' to 'decay origin' + 'offset') will have no decay rate applied.
  7. Select an Asset Type and Data Field to which the method will be applied. Only date type data fields are available for selection.

    To apply the method to the standard field, published date, available in all asset types, select Any as the asset type.

  8. To add additional data fields, click Add icon.
  9. When you're done, click Save.

Example

Let's say you have a decay method with the following values:

  • Decay Origin: December 1, 2021
  • Decay Rate: 0.5
  • Scale: 1 day
  • Offset: 10 days

If your returned item has an original relevance score of 10, here's how the decay rate would be applied:

  • If the returned item's date is between November 21, 2021 and December 11, 2021 (within the offset range), no decay rate would be applied, and the relevance score would remain 10.
  • If the returned item's date is between November 20, 2021 and December 12, 2021 (within the scale range), half the decay rate would be applied. The original relevance score (10) would be decreased by half (0.5) of the decay rate (0.5), making the relevance score decrease by 2.5 (10 x 0.5 x 0.5 = 2.5), so the new relevance score would be 7.5 (10 - 2.5 = 7.5).
  • If the returned item's date isn't between November 20, 2021 and December 12, 2021 (outside the scale range) the full decay rate would be applied. The original relevance score (10) would be decreased by the full decay rate (0.5), making the relevance score decrease by 5 (10 x 0.5 = 5), so the new relevance score would be 5 (10 - 5 = 5).

Decay - Numeric Method

The 'decay - numeric' method decreases the relevance score of items that are returned by the search request. An item's relevance score decreases as the selected asset type's numeric value gets further away from the origin and offset. The rate of decrease is defined by the specified decay rate and scale.

To configure a 'decay - numeric' method:

  1. Enter a name for the method.
  2. Enter an optional description describing what the method does.
  3. Enter a Decay Origin. This will be the middle of the numeric range to which the relevance score will remain unchanged (no decrease will be applied).
  4. Enter a Decay Rate between 0.1 and 1.0. This determines the amount the relevance score is decreased by. For example, if the original relevance score is 10, and your decay rate is 0.5, the fully applied decay rate would decrease the score to 5 (10 x 0.5 = 5).
  5. Enter a Scale of 0 or greater. This determines how rapidly the decrease in relevance score approaches 0. Returned items with values within the scale range ('decay origin' - 'offset' - 'scale' to 'decay origin' + 'offset' + 'scale') will have half the decay rate applied. Returned items with values outside the scale range will have the full decay rate applied.
  6. Enter an Offset of 1 or greater. This determines the beginning and ending of the numeric range to which the relevance score will remain unchanged (no decrease will be applied). Returned items with values within the offset range ('decay origin' - 'offset' to 'decay origin' + 'offset') will have no decay rate applied.
  7. Select an Asset Type and Data Field to which the method will be applied. Only number type data fields are available for selection.
  8. To add additional data fields, click Add icon.
  9. When you're done, click Save.

Example

Let's say you have a decay method with the following values:

  • Decay Origin: 100
  • Decay Rate: 0.5
  • Scale: 1
  • Offset: 10

If your returned item has an original relevance score of 10, here's how the decay rate would be applied:

  • If the returned item's numeric value is between 90 and 110 (within the offset range), no decay rate would be applied, and the relevance score would remain 10.
  • If the returned item's numeric value is between 89 and 111 (within the scale range), half the decay rate would be applied. The original relevance score (10) would be decreased by half (0.5) of the decay rate (0.5), making the relevance score decrease by 2.5 (10 x 0.5 x 0.5 = 2.5), so the new relevance score would be 7.5 (10 - 2.5 = 7.5).
  • If the returned item's numeric value isn't between 89 and 111 (outside the scale range) the full decay rate would be applied. The original relevance score (10) would be decreased by the full decay rate (0.5), making the relevance score decrease by 5 (10 x 0.5 = 5), so the new relevance score would be 5 (10 - 5 = 5).

Pin - Equals Method

The 'pin - equals' method sets the topmost relevance to items returned by the search request only if the data field values in the selected asset types exactly match the values assigned below (EQ operator is applied).

To configure a 'pin - equals' method:

  1. Enter a name for the method.
  2. Enter an optional description describing what the method does.
  3. Select an Asset Type and Data Field to which the method will be applied.

    To apply the method to the standard fields (asset name, description, or published date) available in all asset types, select Any as the asset type.

    Note:

    Large text fields aren't supported for the 'pin - equals' method.
  4. To add additional data fields, click Add icon.
  5. Enter the values to be matched against the selected data fields.
    • Text values—Enter a word or term, and then press ENTER to add it.
    • Numeric values—Enter a numeric value, and then press ENTER to add it.
    • Data and time values—Click the date box or Calendar icon to select a date, time, and time zone. Enter an offset of 1 or greater and a period of time to create a range to which the boost will be applied. For example, if you select December 1, 2021 and enter an offset of 10 days, returned items will match if their date value is between December 1, 2021 and December 11, 2021.

      To add additional date and time values, click Add icon.

    If you enter more than one value in your method, the ranking policy will be applied if either value matches the returned item (OR is applied). For example, if you have two values (value-1 and value-2) for a field (field-1), the ranking policy would be applied if field-1 EQ value-1 OR field-1 EQ value-2.

  6. When you're done, click Save.

Pin - Phrase Match Method

The 'pin - phrase match' method sets the topmost relevance to items returned by the search request only if the phrase values in the selected asset types match the values assigned below (MT operator is applied).

To configure a 'pin - phrase match' method:

  1. Enter a name for the method.
  2. Enter an optional description describing what the method does.
  3. Select an Asset Type and Data Field to which the method will be applied.

    To apply the method to the standard fields (asset name or description) available in all asset types, select Any as the asset type.

  4. To add additional data fields, click Add icon, and select the asset type and data field.
  5. Enter the values to be matched against the selected data fields. Enter a word or term, and then press ENTER to add it.

    The phrase value can appear anywhere in the data field. For example, if you enter a value of "capital city", it will match if the data field says "The capital city of France is Paris" or "Palermo is the capital city of Sicily".

    If you enter more than one value in your method, the ranking policy will be applied if either value matches the returned item (OR is applied). For example, if you have two values (value-1 and value-2) for a field (field-1), the ranking policy would be applied if field-1 MT value-1 OR field-1 MT value-2.

  6. When you're done, click Save.