Edit

Share via


Java samples for Azure AI Search

Learn about Java code samples that demonstrate the functionality and workflow of an Azure AI Search solution. These samples use the Azure AI Search client library for the Azure SDK for Java, which you can explore through the following links.

Target Link
Package download search.maven.org/artifact/com.azure/azure-search-documents
API reference com.azure.search.documents
API test cases github.com/Azure/azure-sdk-for-java/tree/main/sdk/search/azure-search-documents/src/test
Source code github.com/Azure/azure-sdk-for-java/tree/main/sdk/search/azure-search-documents
Change log github.com/Azure/azure-sdk-for-java/blob/main/sdk/search/azure-search-documents/CHANGELOG.md

SDK samples

Code samples from the Azure SDK development team demonstrate API usage. You can find these samples in Azure/azure-sdk-for-java/tree/main/sdk/search/azure-search-documents/src/samples on GitHub.

Sample Description
Index creation Create an index.
Indexer creation Create an indexer.
Data source creation Create a data source connection, which is required for indexer-based indexing of supported data sources.
Skillset creation Create a skillset that's attached to an indexer and perform AI-based enrichment during indexing.
Synonym creation Create a synonym map.
Load documents Upload or merge documents into an index in a data import operation.
Query syntax Send a basic query.
Vector search Create a vector field and send a vector query.

Doc samples

Code samples from the Azure AI Search team demonstrate features and workflows. The following samples are referenced in tutorials, quickstarts, and how-to articles that explain the code in detail. You can find these samples in Azure-Samples/azure-search-java-samples on GitHub.

Sample Article Description
quickstart Quickstart: Full-text search Create, load, and query an index using sample data.

Tip

Use the samples browser to search for Microsoft code samples on GitHub. You can filter your search by product, service, and language.