Azure AI search using Azure Document Intelligences Layout Model

Manos 0 Reputation points
2024-07-29T08:28:08.7133333+00:00

Hey all,

as the title says, I want to make my Azure AI Search index better by using a pre-built layout model from the Azure Document Intelligences.

The Microsoft tutorial shows an example of adding a custom model as a custom skill, but the layout model is a pre-built one. Does anyone have a more direct example?

Thank you!

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.
868 questions
Azure AI Document Intelligence
Azure AI Document Intelligence
An Azure service that turns documents into usable data. Previously known as Azure Form Recognizer.
1,541 questions
{count} votes

1 answer

Sort by: Most helpful
  1. AzureAce 27 Reputation points
    2024-07-29T12:55:08.8133333+00:00

    You are very welcome!

    Here are the detail steps.
    1. Direct Integration with Document Intelligence API:

    • This approach involves calling the Document Intelligence API directly within your indexing pipeline. Here's the step-by-step breakdown:
      1. Preprocess documents: Format your documents for analysis by the Document Intelligence API. This might involve converting them to a supported format (e.g., PDF, PNG, JPG).
      2. Call the Document Intelligence API: Use the Azure SDK or REST API to call the appropriate endpoint (e.g., "analyzeLayout" for layout extraction). Pass the preprocessed document as input.
      3. Parse the response: Extract the relevant information from the API response. This might include key-value pairs for identified fields, bounding boxes, or other layout elements.
      4. Enrich index: Add the extracted information as new fields to your Azure AI Search index using the Search SDK or REST API.
      **2.**Custom Skill with External Service Call:
      This method involves creating a custom skill that acts as a wrapper for the Document Intelligence API call.
      1. Develop a custom skill:
        • This can be implemented as an Azure Function.
        • The skill receives the document as input from the Azure AI Search pipeline.
      2. Call the Document Intelligence API: Inside the custom skill, call the Document Intelligence API using the same process as described in option 1 (steps 2 and 3).
      3. Process and return output: Parse the API response within the skill.
      4. Enrich index: The skill should format the extracted information according to the Azure AI Search expected format and then return it. Azure AI Search subsequently adds this information to the index.

    Document Extraction with Azure AI Document Intelligence:

    https://techcommunity.microsoft.com/t5/azure-architecture-blog/enhancing-document-extraction-with-azure-ai-document/ba-p/4187387

    Hope this resources will be helpful to you.

    Please accept as "Yes" if the answer is helpful, so that it can help others in the community.

    0 comments No comments