Skip to Content
Solution PlaysPlay 38: Play 38 β€” Document Understanding V2 πŸ“‘πŸ”

Play 38 β€” Document Understanding V2 πŸ“‘πŸ”

Advanced document processing with layout-aware extraction, cross-doc comparison, and auto-classification.

Beyond Play 06’s basic OCR: auto-classify documents by type, extract fields while preserving layout structure (sections, tables, columns), compare document versions to find changes, and route through automated workflows. Document intelligence meets AI reasoning.

Quick Start

cd solution-plays/38-document-understanding-v2 az deployment group create -g $RG -f infra/main.bicep -p infra/parameters.json code . # Use @builder for extraction/classification, @reviewer for accuracy audit, @tuner for model routing

How It Differs from Play 06 and Play 15

AspectPlay 06 (Doc Intel)Play 15 (Multi-Modal)Play 38 (Understanding V2)
ClassificationManual modelPage-type routingAuto-classify any doc
ComparisonNoneNoneCross-doc diff + risk
LayoutBasic fieldsPage-level visualSection/table-aware
WorkflowExtract onlyExtract onlyClassify β†’ extract β†’ route β†’ archive

Architecture

ServicePurpose
Document IntelligenceLayout + prebuilt extraction
Azure OpenAI (gpt-4o)Classification, comparison analysis
Cosmos DBClassification results, comparison logs
Azure FunctionsWorkflow orchestration

πŸ“ Full architecture details

Key Metrics

  • Classification: β‰₯92% Β· Layout F1: β‰₯88% Β· Comparison: β‰₯85% Β· PII recall: β‰₯99%

DevKit (Advanced Document-Focused)

PrimitiveWhat It Does
3 agentsBuilder (layout/comparison/classification), Reviewer (accuracy/PII/consistency), Tuner (models/thresholds/cost)
3 skillsDeploy (106 lines), Evaluate (107 lines), Tune (103 lines)
4 prompts/deploy (understanding pipeline), /test (extraction/workflow), /review (PII/accuracy), /evaluate (classification)

Cost

ServiceDevProdEnterprise
Document Intelligence$0 (Free)$150 (Standard S0)$600 (Standard S0)
Azure OpenAI$50 (PAYG)$350 (PAYG)$1,100 (PTU)
Cosmos DB$5 (Serverless)$80 (1000 RU/s)$400 (5000 RU/s)
Azure Functions$0 (Consumption)$120 (Premium EP1)$240 (Premium EP2)
Blob Storage$3 (Hot LRS)$30 (Hot LRS)$100 (Hot GRS+WORM)
Azure AI Search$0 (Free)$250 (Standard S1)$500 (Standard S2)
Key Vault$1 (Standard)$5 (Standard)$15 (Premium HSM)
Application Insights$0 (Free)$25 (Pay-per-GB)$100 (Pay-per-GB)
Total$59/mo$1,010/mo$3,055/mo

πŸ’° Full cost breakdown

πŸ“– Full docs Β· 🌐 frootai.dev/solution-plays/38-document-understanding-v2Β 

FAI Manifest

FieldValue
Play38-document-understanding-v2
Version1.0.0
KnowledgeF1-GenAI-Foundations, R2-RAG-Architecture, T3-Production-Patterns
WAF Pillarssecurity, reliability, responsible-ai, performance-efficiency
Groundednessβ‰₯ 85%
Safety0 violations max
Last updated on