Skip to main content

query_suggestions_configs

Creates, updates, deletes, gets or lists a query_suggestions_configs resource.

Overview

Namequery_suggestions_configs
TypeResource
Idaws.kendra.query_suggestions_configs

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
attribute_suggestions_configobjectConfiguration information for the document fields/attributes that you want to base query suggestions on.
include_queries_without_user_informationbooleanTRUE to use all queries, otherwise use only queries that include user information to generate the query suggestions.
last_clear_timestring (date-time)The Unix timestamp when query suggestions for an index was last cleared. After you clear suggestions, Amazon Kendra learns new suggestions based on new queries added to the query log from the time you cleared suggestions. Amazon Kendra only considers re-occurences of a query from the time you cleared suggestions.
last_suggestions_build_timestring (date-time)The Unix timestamp when query suggestions for an index was last updated. Amazon Kendra automatically updates suggestions every 24 hours, after you change a setting or after you apply a block list.
minimum_number_of_querying_usersintegerThe minimum number of unique users who must search a query in order for the query to be eligible to suggest to your users.
minimum_query_countintegerThe minimum number of times a query must be searched in order for the query to be eligible to suggest to your users.
modestringWhether query suggestions are currently in ENABLED mode or LEARN_ONLY mode. By default, Amazon Kendra enables query suggestions.LEARN_ONLY turns off query suggestions for your users. You can change the mode using the UpdateQuerySuggestionsConfig API. (ENABLED, LEARN_ONLY)
query_log_look_back_window_in_daysintegerHow recent your queries are in your query log time window (in days).
statusstringWhether the status of query suggestions settings is currently ACTIVE or UPDATING. Active means the current settings apply and Updating means your changed settings are in the process of applying. (ACTIVE, UPDATING)
total_suggestions_countintegerThe current total count of query suggestions for an index. This count can change when you update your query suggestions settings, if you filter out certain queries from suggestions using a block list, and as the query log accumulates more queries for Amazon Kendra to learn from. If the count is much lower than you expected, it could be because Amazon Kendra needs more queries in the query history to learn from or your current query suggestions settings are too strict.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_query_suggestions_configselectregionGets information on the settings of query suggestions for an index. This is used to check the current settings applied to query suggestions. DescribeQuerySuggestionsConfig is currently not supported in the Amazon Web Services GovCloud (US-West) region.
update_query_suggestions_configupdateregion, IndexIdUpdates the settings of query suggestions for an index. Amazon Kendra supports partial updates, so you only need to provide the fields you want to update. If an update is currently processing, you need to wait for the update to finish before making another update. Updates to query suggestions settings might not take effect right away. The time for your updated settings to take effect depends on the updates made and the number of search queries in your index. You can still enable/disable query suggestions at any time. UpdateQuerySuggestionsConfig is currently not supported in the Amazon Web Services GovCloud (US-West) region.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
regionstringAWS region (default: us-east-1)

SELECT examples

Gets information on the settings of query suggestions for an index. This is used to check the current settings applied to query suggestions. DescribeQuerySuggestionsConfig is currently not supported in the Amazon Web Services GovCloud (US-West) region.

SELECT
attribute_suggestions_config,
include_queries_without_user_information,
last_clear_time,
last_suggestions_build_time,
minimum_number_of_querying_users,
minimum_query_count,
mode,
query_log_look_back_window_in_days,
status,
total_suggestions_count
FROM aws.kendra.query_suggestions_configs
WHERE region = '{{ region }}' -- required
;

UPDATE examples

Updates the settings of query suggestions for an index. Amazon Kendra supports partial updates, so you only need to provide the fields you want to update. If an update is currently processing, you need to wait for the update to finish before making another update. Updates to query suggestions settings might not take effect right away. The time for your updated settings to take effect depends on the updates made and the number of search queries in your index. You can still enable/disable query suggestions at any time. UpdateQuerySuggestionsConfig is currently not supported in the Amazon Web Services GovCloud (US-West) region.

UPDATE aws.kendra.query_suggestions_configs
SET
IndexId = '{{ IndexId }}',
Mode = '{{ Mode }}',
QueryLogLookBackWindowInDays = {{ QueryLogLookBackWindowInDays }},
IncludeQueriesWithoutUserInformation = {{ IncludeQueriesWithoutUserInformation }},
MinimumNumberOfQueryingUsers = {{ MinimumNumberOfQueryingUsers }},
MinimumQueryCount = {{ MinimumQueryCount }},
AttributeSuggestionsConfig = '{{ AttributeSuggestionsConfig }}'
WHERE
region = '{{ region }}' --required
AND IndexId = '{{ IndexId }}' --required;