Processing Documents Safely with AI Builder
Operations teams in UK financial services firms can receive large volumes of documents every day. Processing these documents manually is a repetitive workflow that can lead to human error, delayed response times, and poor outcomes for consumers. Microsoft Power Platform provides AI Builder (A Power Platform capability that lets makers embed governed document processing, extraction, and text classification into Power Apps and Power Automate flows.), a capability that allows you to use artificial intelligence to automate data extraction from structured and semi-structured documents. In this lesson, we will explore how to use AI Builder document processing to extract text from customer complaint forms accurately. Our goal is to improve record-keeping and automate the initial intake of data while operating safely inside proper governance.
Refresher Core Mental Model: Processing Documents Safely with AI Builder 1 min
In Power Platform Automation for Regulated Teams: Power Automate, Power Apps and AI Builder with Governance, Processing Documents Safely with AI Builder focuses on turning The Regulatory Context for Document Processing into a repeatable, governed practice. Rather than treating tools as black-box oracles, anchor every step to three questions: What approved data goes in? What structured draft comes out? And who verifies the result against primary evidence before action is taken?
The Regulatory Context for Document Processing
When automating the processing of customer complaints, we must carefully consider the UK regulatory environment. Under the Financial Conduct Authority Consumer Duty (The UK Financial Conduct Authority (FCA) regulatory standard requiring firms to act to deliver demonstrably good outcomes for retail customers across products and support.), firms must act to deliver good outcomes for retail customers. This includes acting quickly to resolve complaints and analysing complaint data to identify systemic root causes. Accurate automated data extraction supports these objectives by speeding up initial triage and ensuring that information is categorised correctly from the outset.

Furthermore, handling complaint forms inherently involves processing personal and potentially sensitive data. You must adhere strictly to UK GDPR (Data protection legislation requiring lawful processing, data minimization, purpose limitation, and strict security controls over personal data.) principles, specifically data minimisation and security. Operational resilience and stringent record-keeping rules also apply to these workflows. The automated process must be reliable, secure, and auditable. Operational resilience requires that important business services can stay within impact tolerances during disruptions. By standardising the intake of documents through AI Builder, you reduce reliance on fragile manual data entry. However, you must also plan for downtime. If the AI service is temporarily unavailable, your system must still safely queue the incoming complaints so that no records are lost. Please note that this regulatory context is provided as a framework for good technical practice and does not constitute legal advice.
Ensuring Safe Implementation and Governance
Automating data extraction with AI requires strict adherence to your Power Platform Centre of Excellence guidelines. You must establish named human ownership and accountability for the AI model. Under the principles of the Senior Managers and Certification Regime (The UK financial regulatory framework establishing personal, non-delegable accountability for senior managers over the operational processes and automations in their area.), a named individual must be accountable for the automated process and its business outcomes. The AI is a tool to assist staff, not a substitute for human responsibility.
You must also apply least-privilege permissions at every step. The cloud flow and the AI model should only have access to the specific data necessary to perform the task. We must protect confidential and personal data through a robust environment strategy and data policies (Tenant-level technical policies that classify connectors into Business, Non-Business, and Blocked groups to prevent unauthorized data exfiltration.) (formerly DLP policies), ensuring that extracted complaint data cannot be routed to unapproved external services. Finally, you must enforce testing before release. You should build the AI model in a dedicated development environment, test it thoroughly in a separate test environment, and deploy it to production only as a managed solution.
Choosing the Right Document Processing Model
AI Builder offers different ways to process incoming documents. The choice depends entirely on the structure of your forms and the specific fields you need to extract for your records.
| Model Type | Best Use Case | Training Data Required | Governance Consideration |
|---|---|---|---|
| Prebuilt Models | Standard industry documents such as invoices or receipts. | None. The model is ready to use immediately. | Data is processed by a standard Microsoft model that extracts a fixed set of fields. To extract extra invoice fields, you can build a custom invoices model on top of the prebuilt one. |
| Custom Document Processing | Specific business forms, such as a proprietary customer complaint form. | Yes. Requires a minimum of five sample documents per layout. | You must manage the training data carefully and retrain the model if the form layout changes significantly over time. |
Plain-text version
Model Type | Best Use Case | Training Data Required | Governance Consideration Prebuilt Models | Standard industry documents such as invoices or receipts. | None. The model is ready to use immediately. | Data is processed by a standard Microsoft model that extracts a fixed set of fields. To extract extra invoice fields, you can build a custom invoices model on top of the prebuilt one. Custom Document Processing | Specific business forms, such as a proprietary customer complaint form. | Yes. Requires a minimum of five sample documents per layout. | You must manage the training data carefully and retrain the model if the form layout changes significantly over time.
Worked Example: Extracting Text from Complaint Forms
In this exercise, we will build a custom document processing model to extract data from a standard PDF customer complaint form used by a retail bank. To ensure we protect confidential and personal data, all training and testing must use synthetic data. You must never use real customer or confidential data when training AI models or building solutions in development environments.
The first step is to define the information we want to extract. For our regulatory record-keeping process, we need four specific fields: the customer reference number, the date of the complaint, the product type, and the description of the issue.
Next, we must gather synthetic training documents. We require at least five synthetic complaint forms that share the exact same layout as the real production forms. These synthetic forms must contain realistic but entirely fake names, reference numbers, and complaint descriptions. Once you have uploaded these synthetic documents to AI Builder, you will tag the data manually. Tagging involves drawing digital boxes around the text on the synthetic form and assigning those boxes to the fields you defined earlier. This teaches the AI model where to look for specific information on the page.
After tagging the synthetic documents, you will command AI Builder to train the model. The training process generates an accuracy score based on the provided samples. If the score is low, you must provide more synthetic examples to improve the model before you can rely on it in a business process.
Integrating the Model with Power Automate
Once the custom AI Builder model is trained and published, you can use it inside a Power Automate cloud flow. A common architectural pattern is to trigger the flow when a new email containing a PDF attachment arrives in a designated shared mailbox managed by the complaints team.
The flow will retrieve the attachment and pass it to the AI Builder action named Process documents (called Extract information from documents before May 2025). You will select your newly trained custom model from the dropdown menu. The AI Builder action will read the PDF and output the text it has found for the customer reference number, date, product type, and description.
Enforcing Human Oversight and Audit Trails
AI models are probabilistic, meaning they calculate the likelihood that they have extracted the correct text. They will occasionally make mistakes, especially if a form is poorly scanned or contains unexpected handwriting. To avoid shadow IT and support compliance, you must build comprehensive logging, audit capabilities, and human oversight into your cloud flow.
Every piece of extracted data comes with a confidence score provided by AI Builder. You must use conditional logic in your Power Automate flow to evaluate this score. A strong governance practice is to set a threshold, for example 0.85, because AI Builder reports confidence scores as values between 0 and 1.
- High Confidence: If the confidence score is above the threshold, the flow can automatically write the extracted data into a secure Dataverse table to update your record-keeping system.
- Low Confidence: If the confidence score falls below the threshold, the flow must not update the core system automatically. Instead, it should route the extracted text and the original document to a named human worker for manual review. This is easily achieved using the Approvals connector in Power Automate.
Comprehensive logging is not just a technical requirement; it is a regulatory expectation. Within Dataverse, you should turn on auditing for the table and use column-level security for sensitive columns. With auditing on, if a human reviewer subsequently edits the data initially extracted by AI Builder, Dataverse records the original AI value, the new manual value, the timestamp and the identity of the user making the change, for as long as your audit retention settings keep it. This creates a transparent audit trail that can be presented to internal risk teams or external supervisors upon request. This approach keeps a human in the loop for complex documents and reinforces the principle of named human accountability.
Securing the Solution and Preparing for Deployment
Before you consider this automation complete, you must verify your security configurations. The service account running the Power Automate flow must operate under least-privilege permissions. It should only have permission to read from the specific complaints shared mailbox and permission to write to the specific Dataverse table. It must never have administrative access to the wider environment.
Your Power Platform administrators must enforce data policies on the environment hosting this solution. When consumer email services and unapproved cloud storage connectors are classified as Blocked or Non-Business, the cloud flow cannot combine them with the business connectors that handle the extracted complaint data, which greatly reduces the risk of a data breach. Your environment strategy plays a critical role here. Managed environments should be used to give administrators greater visibility of usage, through weekly usage insights, and to enforce stricter sharing limits, preventing staff from bypassing governance controls.
Finally, you must adhere strictly to application lifecycle management principles. Because you have built this solution using synthetic data in a development environment, you must now package the custom AI Builder model, the Power Automate flow, and the Dataverse table schema into a single solution. You will export this as a managed solution and import it into a secure test environment. In the test environment, business users will conduct user acceptance testing using a fresh set of synthetic data. Only when the testing proves the extraction is highly accurate and the human-in-the-loop routing works correctly should the managed solution be promoted to your production environment for real operational use.

Go deeper Architectural & Governance Trade-Offs in Processing Documents Safely with AI Builder 1 min · optional
When scaling Ensuring Safe Implementation and Governance across a team or regulated workflow, the primary bottleneck is rarely generation speed—it is verification overhead and drift. High-performing teams track two operational metrics alongside throughput: Edit-to-Approval Time (how many minutes a human reviewer spends correcting outputs) and Source-Traceability Rate (whether 100% of material numbers and claims link back to an audited record). If edit time exceeds manual drafting baseline across two cycles, tighten your input schema and negative constraints before expanding scope.
Enterprise AI Strategy & Implementation Discovery Call
Scope practical AI workflows, human-in-the-loop governance, and measurable delivery milestones with Tesseract Consulting.
