Is Azure AI Search Service support array of vector

Mattanapol Konguthaikul (TH) 20 Reputation points
2025-06-17T06:21:35.0966667+00:00

I have multiple document and each document split into multiple chunk.

I want to store vector of each chunk in one document, the end goal is, when I search for document, if any chunk match, show the document in result only once, while still able to apply pagination.

How can I configure the search index?

Azure AI Search
Azure AI Search
An Azure search service with built-in artificial intelligence capabilities that enrich information to help identify and explore relevant content at scale.
1,339 questions
0 comments No comments
{count} votes

Accepted answer
  1. Bhargavi Naragani 5,270 Reputation points Microsoft External Staff Moderator
    2025-06-17T07:40:38.63+00:00

    Hi @Mattanapol Konguthaikul (TH),

    As of now, Azure AI Search does NOT support storing or querying an array of vectors (vector arrays) in a single document. Each document can only contain one vector field for each configured vector search field. This means you cannot natively store multiple vectors (i.e., one per chunk) inside a single document and run a vector similarity search across all of them.

    To achieve your goal, follow this design pattern:

    1. Store each chunk as an individual document in the search index. Each chunk will have:
      • Its own vector embedding
      • A field like documentId to indicate the parent document it belongs to
      • Any other metadata (e.g., title, page number)
    2. At query time, run a vector similarity search across the chunk documents. This will return the most relevant chunks, each tied to their parent document via documentId.
    3. Use code (either in your app backend or Azure Cognitive Search enrichment pipeline) to group results by documentId, ensuring:
      • You only return each document once.
      • You can implement pagination over unique document-level results.
    4. Use scoring profiles or filters to prioritize certain metadata fields if needed.

    Reference:
    https://learn.microsoft.com/en-us/azure/search/vector-search-overview
    https://learn.microsoft.com/en-us/azure/search/index-add-scoring-profiles
    https://learn.microsoft.com/en-us/azure/search/vector-search-how-to-configure-vectorizer

    If the answer is helpful, please click Accept Answer and kindly upvote it so that other people who faces similar issue may get benefitted from it.

    Let me know if you have any further Queries.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.