Elasticsearch: Set up vector search
Overview
Introduction to Elasticsearch
Get familiar with Elasticsearch with an overview on how to ingest, and view your data with Elastic Cloud.
As you ramp up on Elastic, you'll use the Elasticsearch Relevance Engine™ (ESRE), designed to power AI search applications. With ESRE, you can take advantage of a suite of developer tools including Elastic's textual search, vector database, and our proprietary transformer model for semantic search.
Elastic offers a variety of search techniques, starting with BM25, the industry standard for textual search. It provides precise matching for specific searches, matching exact keywords, and it improves with tuning.
As you get started on vector search, keep in mind there are two forms of vector search: "dense" (aka, kNN vector search) and "sparse" such as Elastic's Learned Sparse Encoder (ELSER).
In addition, Elastic also supports kNN vectors to implement similarity search on unstructured data beyond text, such as videos, images, and audio.
In this guide, we'll demonstrate how to get started with leveraging Elasticsearch as a vector database, which enables vector search use cases.
Let's get started
Create an Elastic Cloud deployment
Get started with a 14-day trial. Once you go to cloud.elastic.co and create an account, follow the steps below to learn how to launch your first Elastic stack in any one of our 50+ supported regions globally.
If you click on Edit settings you can choose a cloud provider, including AWS, Microsoft Azure, or Google Cloud. Once you select your cloud provider you’ll be able to select the relevant region. Next, you have the option to choose between a few different hardware profiles so you can better customize the deployment to suit your needs. Plus, the latest version of Elastic has already been preselected for you.
While your deployment is being created, you'll be given a username and password. Be sure to copy or download this as you'll need it when you install your integrations.
Get started with vector search
Now that you've created your deployment it's time to get data into Elastic. First, under the Search tab, you'll select the tile, Set up vector search.
Next, you'll be brought to a set up guide where you'll begin by creating an index.
We've made it easy for you to try it out. Simply select Try in console and a flyout will appear with the console. You'll see the code on the left. When you click the Send request button ▶, you'll see the executed code on the right.
Now, it's time to ingest your data. You'll repeat this process by clicking Try in console then select the Send request button ▶, you'll see the executed code on the right.
Working with Elasticsearch
Build your vector search query
Finally, let's build your vector search query. This final step allows you to explore your data with searches and aggregations. Leverage Try in Console then select the Send request button ▶, you'll see the executed code on the right.
Next steps
Thanks for taking the time to set up vector search for your data with Elastic Cloud. As you begin your journey with Elastic, understand some operational, security, and data components you should manage as a user when you deploy across your environment.
Ready to get started? Spin up a free 14-day trial on Elastic Cloud.
Additional resources
- Get started with Elasticsearch
- Build an AI-powered search experience
- Search across business systems and software
- Add search to your website
- Build an application on top of Elasticsearch
- Connect to the Elasticsearch API