[ ABORT TO HUD ]
SEQ. 1
SEQ. 2
SEQ. 3
SEQ. 4
SEQ. 5

Document Intelligence

🔧 Foundry Tools (AI Services) 8 min 70 BASE XP⌨ HANDS-ON LAB

Extracting Structure from Documents

Document Intelligence (formerly Form Recognizer) uses AI to extract text, tables, key-value pairs, and structure from PDFs, images, and scanned documents.

Pre-Built Models

ModelExtractsUse Case
ReadText and structure from any documentGeneral OCR, digitization
LayoutTables, figures, sections, paragraphsComplex document parsing
InvoiceVendor, amounts, line items, datesAccounts payable automation
ReceiptMerchant, total, items, taxExpense management
ID DocumentName, DOB, document numberIdentity verification
CustomYour defined fieldsIndustry-specific forms

Integration with RAG

Document Intelligence is crucial for RAG pipelines - it converts unstructured PDFs into structured text that can be chunked, embedded, and indexed in Azure AI Search.

💡 Key Insight: For RAG systems, use the Layout model rather than the Read model. Layout preserves table structure and section hierarchy, producing much better chunks for embedding.
⌨ HANDS-ON LABExtract an Invoice with prebuilt Models
⭐ +150 XP

Accounts payable drowns in PDFs. Submit an invoice to the prebuilt-invoice model - Document Intelligence is async, so you submit, then poll the operation for structured fields.

1Submit the invoice URL to prebuilt-invoice:analyze - note the async 202 + Operation-Location header.
2Poll the Operation-Location URL until status is succeeded and read the extracted fields.
lab-sandbox — simulated environment
INFINITY LAB SANDBOX v2.6 — simulated shell
Type the command for the current objective. Helpers: "hint", "solution", "clear".
$
OBJECTIVE 1 / 2 — type "hint" if stuck
FOUNDRY VERIFICATION
QUERY 1 // 2
Why should you use the Layout model instead of Read for RAG pipelines?
Layout is cheaper
Layout preserves table structure and section hierarchy for better chunking
Read doesn't support PDFs
Layout is faster