This post has been republished via RSS; it originally appeared at: New blog articles in Microsoft Community Hub.
Last week, we announced our partnership with Cohere, enabling customers to easily leverage Cohere models via Azure AI Studio Model Catalog, including Cohere’s latest LLM - Command R+. Today, we are thrilled to announce that you can store and search over Cohere's latest Embed V3 int8 embeddings using Azure AI Search. This capability offers significant memory cost reductions while often maintaining high search quality, making it an ideal solution for semantic search over large datasets powering your Generative AI applications.
"With int8 Cohere embeddings available in Azure AI Search, Cohere and Azure users alike can now run advanced RAG using a memory-optimized embedding model and a state-of-the-art retrieval system.” - Nils Reimers, Cohere's Director of Machine Learning,
With int8 embeddings, customers can achieve a 4x memory saving and about a 30% speed-up in search, while keeping 99.99% of the search quality. Read the full announcement from Cohere here: Cohere int8 & binary Embeddings - Scale Your Vector Database to Large Datasets.
Here's a step-by-step guide on how to use Cohere Embed V3 int8 embeddings with Azure AI Search:
Install required libraries
Install the necessary libraries, including the Azure Search Python SDK and Cohere Python SDK. Note, ensure you use our latest 2024-03-01-Preview API Version.
Set up Cohere and Azure AI Search credentials
Set up your credentials for both Cohere and Azure AI Search. Set up your credentials for both Cohere and Azure AI Search. You can find these in the Cohere Dashboard and on the Keys blade of the Azure Portal in your Azure AI Search service.
Generate Embeddings Function
Use the Cohere Embed API to generate int8 embeddings for a list of documents.
Create Azure AI Search Index
Create or update an Azure AI Search index to include a vector field for storing the document embeddings.
Index Documents and their Embeddings
Index the documents along with their int8 embeddings into Azure AI Search.
Run the workflow
Run the above steps to generate the embeddings, create the search index, and upload the documents.
Perform a vector search
Use the Azure AI Search client to perform a vector search using the generated embeddings.
Find the full notebook here: azure-search-vector-samples/demo-python/code/community-integration/cohere/azure-search-cohere-embed-v3-sample.ipynb at main · Azure/azure-search-vector-samples (github.com)
Getting started with Azure AI Search
- Read more about Command R+ in the Cohere blog. Go to AI Studio model catalog to get started on Command R+.
- Learn more about vector quantization and narrow data type enhancements
- Learn more about Azure AI Search and more about all the latest features
- Start creating a search service in the Azure Portal, Azure CLI, the Management REST API, ARM template, or a Bicep file.
- Go from zero to hero with our RAG Solution Accelerator
- Read the blog: Outperforming vector search with hybrid retrieval and ranking capabilities
- Watch a video on Microsoft Mechanics: How vector search and semantic ranking improve your AI prompts