KendraRanking / Client / create_rescore_execution_plan

create_rescore_execution_plan#

KendraRanking.Client.create_rescore_execution_plan(**kwargs)#

Creates a rescore execution plan. A rescore execution plan is an Amazon Kendra Intelligent Ranking resource used for provisioning the Rescore API. You set the number of capacity units that you require for Amazon Kendra Intelligent Ranking to rescore or re-rank a search service’s results.

For an example of using the CreateRescoreExecutionPlan API, including using the Python and Java SDKs, see Semantically ranking a search service’s results.

See also: AWS API Documentation

Request Syntax

response = client.create_rescore_execution_plan(
    Name='string',
    Description='string',
    CapacityUnits={
        'RescoreCapacityUnits': 123
    },
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ],
    ClientToken='string'
)
Parameters:
  • Name (string) –

    [REQUIRED]

    A name for the rescore execution plan.

  • Description (string) – A description for the rescore execution plan.

  • CapacityUnits (dict) –

    You can set additional capacity units to meet the needs of your rescore execution plan. You are given a single capacity unit by default. If you want to use the default capacity, you don’t set additional capacity units. For more information on the default capacity and additional capacity units, see Adjusting capacity.

    • RescoreCapacityUnits (integer) – [REQUIRED]

      The amount of extra capacity for your rescore execution plan.

      A single extra capacity unit for a rescore execution plan provides 0.01 rescore requests per second. You can add up to 1000 extra capacity units.

  • Tags (list) –

    A list of key-value pairs that identify or categorize your rescore execution plan. You can also use tags to help control access to the rescore execution plan. Tag keys and values can consist of Unicode letters, digits, white space, and any of the following symbols: _ . : / = + - @.

    • (dict) –

      A key-value pair that identifies or categorizes a rescore execution plan. A rescore execution plan is an Amazon Kendra Intelligent Ranking resource used for provisioning the Rescore API. You can also use a tag to help control access to a rescore execution plan. A tag key and value can consist of Unicode letters, digits, white space, and any of the following symbols: _ . : / = + - @.

      • Key (string) – [REQUIRED]

        The key for the tag. Keys are not case sensitive and must be unique.

      • Value (string) – [REQUIRED]

        The value associated with the tag. The value can be an empty string but it can’t be null.

  • ClientToken (string) –

    A token that you provide to identify the request to create a rescore execution plan. Multiple calls to the CreateRescoreExecutionPlanRequest API with the same client token will create only one rescore execution plan.

    This field is autopopulated if not provided.

Return type:

dict

Returns:

Response Syntax

{
    'Id': 'string',
    'Arn': 'string'
}

Response Structure

  • (dict) –

    • Id (string) –

      The identifier of the rescore execution plan.

    • Arn (string) –

      The Amazon Resource Name (ARN) of the rescore execution plan.

Exceptions

  • KendraRanking.Client.exceptions.AccessDeniedException

  • KendraRanking.Client.exceptions.ConflictException

  • KendraRanking.Client.exceptions.ServiceQuotaExceededException

  • KendraRanking.Client.exceptions.ThrottlingException

  • KendraRanking.Client.exceptions.ValidationException

  • KendraRanking.Client.exceptions.InternalServerException