Lesson 2 of 5 Information Extraction with Content Understanding

Extracting Fields from Documents and Forms

This lesson explains what document analysis returns, and how prebuilt and custom analyzers handle invoices, forms and other business documents, the most common input to Content Understanding.

Learning outcomes

After completing this lesson, you will be able to:

  • Describe what document analysis returns.
  • Identify the fields the prebuilt invoice analyzer returns.
  • Explain how confidence scores and thresholds route values to human review.
  • Choose between a prebuilt and a custom analyzer.

What document analysis returns

For a document, Content Understanding runs OCR and layout analysis and returns Markdown that keeps headings, paragraphs and tables, together with page numbers and, depending on options, figures and their descriptions. Supported inputs include PDFs, images of documents such as photos and scans, Office documents and text files. The Markdown representation is useful in its own right: it can be chunked at headings and indexed for search or retrieval-augmented generation.

Fields from invoices and forms

The prebuilt-invoice analyzer returns invoice fields such as vendor name, customer name, invoice ID, invoice date, due date, subtotal, tax, total and an array of line items, each with its own description, quantity, unit price and amount. For other forms, such as application forms, delivery notes or inspection reports, a custom analyzer based on the document analyzer defines the fields. Typed values are normalized, so a date printed as 3 March 2026 is returned as 2026-03-03.

Confidence and review

Every field has a confidence score between 0 and 1 and a reference to where it was found. A business process sets a threshold: values above it flow straight into the system of record, and values below it go to a person, who can see the highlighted source and correct the value. This human-in-the-loop design supports both reliability and accountability.

The following diagram shows fields routed by their confidence.

Confidence and human review. Every extracted field has a confidence score between 0 and 1 and a reference to where it was found. A business process sets a threshold: values above it flow straight into the system of record, and values below it go to a person, who sees the highlighted source and corrects the value. This human-in-the-loop design supports both reliability and accountability.
Confidence values are illustrative.
Scenario questions

Route the fields

Exam skills 2.4.1

Decide what a document pipeline should do with each extracted field. The review threshold is 0.80.

Log in to try this activity Interactive activities are free with an account.

Prebuilt or custom analyzer?

The choice between a prebuilt and a custom analyzer depends on the document type. Common business documents, such as invoices and receipts, have prebuilt analyzers that already know the standard fields, so they need no setup. Documents specific to an organization, such as its own application forms or inspection reports, need a custom analyzer whose schema names the fields to extract.

For example, an accounts team can process supplier invoices with prebuilt-invoice immediately. The same team's internal expense claim form, which has fields such as cost centre and approver, needs a custom analyzer. Both can run in the same pipeline, with each document sent to the analyzer that matches its type.

Sort into groups

Prebuilt or custom analyzer?

Exam skills 2.4.1

Decide whether each document needs the prebuilt invoice analyzer or a custom analyzer.

Log in to try this activity Interactive activities are free with an account.
Worked example

Varied invoice layouts

A company receives invoices from 300 suppliers, each with its own layout. It wants vendor, invoice number, due date and total in its finance system with the least development effort, and wants questionable values checked by a clerk.

The prebuilt-invoice analyzer extracts these fields across layouts without training per supplier, and a confidence threshold routes low-confidence values to the clerk. OCR with text search would need rules for each layout, and a chat prompt would not provide consistent confidence scores.

Check yourself

Which analyzer handles invoices with many different layouts?

Show answer

The prebuilt invoice analyzer (prebuilt-invoice). Custom analyzers handle other forms.

Exam Tips

Remember for the exam

  • Document analysis returns Markdown with structure plus typed fields.
  • prebuilt-invoice handles varied invoice layouts; custom analyzers handle other forms.
  • Route low-confidence fields to human review.