AWS Machine Learning Blog
Promote search content using Featured Results for Amazon Kendra
Amazon Kendra is an intelligent search service powered by machine learning (ML). We are excited to announce the launch of Amazon Kendra Featured Results. This new feature makes specific documents or content appear at the top of the search results page whenever a user issues a certain query. You can use Featured Results to improve the visibility of new documents or to promote certain documents when users enter certain queries.
For example, you can specify that if your users enter the query “new products 2023,” then select the documents titled “What’s new” and “Coming soon” will feature at the top of the search results page. Furthermore, if your users frequently use certain queries, you can specify these queries for Featured Results. For example, if you look at your top queries using Amazon Kendra Analytics and find that specific queries such as “How does kendra semantically rank results?” and “kendra semantic search” are frequently used, then it might be useful for the queries to feature the document titled “Amazon Kendra search 101.”
In this post, we introduce Featured Results and show you how to use them.
Overview of solution
Featured results enables you to create direct mappings from exact queries to documents in your index, allowing you to bypass the usual Amazon Kendra ranking process. Amazon Kendra naturally handles keyword type queries to rank the most useful documents in the search results, avoiding excessive featuring of results based on simple keywords. Featured results are designed for specific queries, rather than queries that are too broad in scope. You can experiment with featuring different documents for different queries, or ensure certain documents get the visibility they deserve.
Prerequisites
To follow along, you should have the following prerequisites:
- An active AWS account.
- An Amazon Kendra index. For instructions, see Creating an index.
You can skip this step if you have a preexisting index to use for this demo.
Add a sample dataset to your index
Complete the following steps to add sample dataset to your index:
- On the Amazon Kendra console, go to your index and choose Data sources.
- Choose Add data source.
- Under Available data sources, select Sample AWS documentation and choose Add dataset.
- Enter a name for your Data source name (such as
sample-aws-data
) and choose Add data source.
Search without Featured Results
On the Amazon Kendra console, choose Search indexed content. In the query field, start with a query such as “Kendra S3 connectors”.
In search results, “DataSourceConfiguration – Amazon Kendra” is listed as the top search result based on the ranking process. But if you want to promote “Getting started with an Amazon S3 data source (Console) – Amazon Kendra,” you can bypass the Amazon Kendra ranking process to feature this result at the top of the search results page.
Create a Featured Results set
To feature certain results, you must specify an exact match of a full text query, not a partial match of a query using a keyword or phrase contained within a query. For example, if you only specify the query “Kendra” in a featured result set, queries such as “How does Kendra semantically rank results?” will not render the Featured Results. For more information on limits, see Quotas for Amazon Kendra. To create a Featured Results set, complete the following steps:
- In the navigation pane, choose Featured results, under Enrichments.
- Choose Create set.
- Enter a name for your set (such as
kendra_connector_feature
) and choose Next.
- Enter a keyword to find items to feature (
kendra s3 connectors
). - Select Getting started with an Amazon S3 data source (Console) – Amazon Kendra from the search results.
- Choose Next.
- Choose Add query.
- Enter a query string (such as
kendra s3 connectors
) and choose Add.
- Choose Next.
- On the Review and create page, choose Create.
Your Amazon Kendra index is now ready for natural language queries.
Search with Featured Results
On the Amazon Kendra console, choose Search indexed content. In the query field, enter the keyword used in the feature results set kendra s3 connectors
.Now, you should see Getting started with an Amazon S3 data source (Console) – Amazon Kendra featured as the top result on the search page
For more information about querying the index, see Querying an Index.
Clean up
To avoid incurring future charges and to clean out unused roles and policies, delete the resources you created:
- On the Amazon Kendra index, choose Indexes in the navigation pane.
- Select the index you created and on the Actions menu, choose Delete.
- To confirm deletion, enter
Delete
when prompted and choose Delete.
Wait until you get the confirmation message; the process can take up to 15 minutes.
Conclusion
In this post, you learned how to use Amazon Kendra Featured Results to promote content in an enterprise search solution.
There are many additional features that we didn’t cover. For example:
- You can enable user-based access control for your Amazon Kendra index, and restrict access to documents based on the access controls you have already configured.
- You can map object attributes to Amazon Kendra index attributes, and enable them for faceting, search, and display in the search results.
- You can quickly find information from webpages (HTML tables) using Amazon Kendra tabular search.
To learn more about Amazon Kendra, refer Amazon Kendra Developer Guide.
About the Authors
Maran Chandrasekaran is a Senior Solutions Architect at Amazon Web Services, working with our enterprise customers. Outside of work, he loves to travel.
Kartik Mittal is a Software Engineer at Amazon Web Services, working on Amazon Kendra, an enterprise search engine. Outside of work, he enjoys hiking and loves to travel.
Surya Ram is a Software Engineer at Amazon Web Services, working on Amazon Kendra. Outside of work, he enjoys chess, basketball and cricket.