Quick Reference mode — designed for live customer calls. Scroll to the objection you need. For deeper context, switch to any other tab.
What is MuleSoft IDP?
One sentence
MuleSoft Intelligent Document Processing reads unstructured documents (PDFs, scanned forms, attachments) and uses AI to extract named fields, routing structured data directly into Salesforce without manual data entry.
98-99%
field accuracy after tuning
3
classification fallback layers
0
PHI reaching the LLM (Einstein filters first)
Platform position: IDP sits inside MuleSoft Anypoint Platform alongside API management and integration flows. The platform subscription is the toolbox. DataSkate is the builder who configures it.

Scope Boundary

In Scope (current SOW)
  • Document ingestion from agreed intake source (e.g., SharePoint)
  • Document classification across agreed doc type list
  • AI field extraction via prompt templates
  • Human review workflow in Salesforce
  • Audit trail for every correction
  • Structured data push to Salesforce objects
Out of Scope (needs separate SOW)
  • Portal or bridge UI development
  • New document types beyond agreed list
  • External-facing form builder or submission tool
  • Ongoing prompt maintenance post-handoff (unless retainer)
  • Training custom AI models

Objection Handler

Click any question to expand the answer. These come from real customer calls.
"Why are we paying a platform subscription before you've even built anything?"
COMMERCIAL

Think of it as toolbox vs. builder. The MuleSoft platform subscription is like buying a saw before hiring a carpenter -- the tool has to be there for the builder to work with. DataSkate is the builder who configures and deploys on top of it. The two run simultaneously because you need an active environment to build and test against.

Separate "platform subscription" from "one-time implementation fee" early. They are two different budget lines with two different purposes. One is ongoing infrastructure; one is a fixed project cost.

"Does the AI actually see our patient or member data? How is that secure?"
SECURITY

No raw PHI reaches the LLM. Salesforce's Einstein Trust Layer acts as a data firewall between your documents and any external AI model. It strips and masks sensitive fields before the extraction prompt is sent, then re-injects the values after the response comes back.

In addition, all LLM providers used by MuleSoft (OpenAI, Google, Anthropic) sign zero data retention agreements. They cannot log, store, or train on submitted data. This is a contractual obligation, not just a policy -- and it is fundamentally different from an employee pasting patient documents into personal ChatGPT.

"What happens when the AI extracts a field incorrectly?"
PROCESS

Every extracted record gets a review status in Salesforce before any downstream action fires. A team member reviews the extraction, corrects any issues, and marks it "processed." Only then does the system proceed -- no PO gets created, no notification goes out, nothing downstream triggers until a human approves.

Every correction is also logged in an audit table: which document, which field, who changed it, and to what. This log drives ongoing prompt improvements and gives you full accountability on what the system did versus what humans corrected.

"Will it learn from corrections over time and get smarter automatically?"
TECHNICAL

No -- and that is intentional. IDP uses prompt-based extraction, not model training. It does not adapt or self-learn from corrections. Improvements require deliberate prompt retuning by the implementation team.

From a compliance standpoint this is a feature: the system behaves predictably, every change to prompts is explicit and documented, and there is no invisible model drift that could change behavior in production without notice. The audit table is exactly the data you would use to decide when and how to retune.

"Carrier quote formats are all different. How does IDP handle that?"
TECHNICAL

Start with one canonical prompt per document type. If a carrier's layout is standard enough, that prompt handles it. If carrier-to-carrier variance is too high (different field positions, labels, page structures), we group carriers by similar formats and build prompt variants per group.

This adds some prompt management overhead but is standard practice. The more sample documents we have during the build phase, the better we can cluster formats and minimize the number of prompt variants needed.

"What happens when a carrier updates their form layout after we go live?"
MAINTENANCE

Minor changes (same fields, slightly repositioned, cosmetic updates) are typically addressed within days. Billed hourly -- usually a small engagement.

Major overhauls (new field set, completely different structure, brand new document type) require a new SOW. The audit table gives you early warning -- a spike in manual corrections for a specific doc type is usually the first sign of format drift.

"Can it handle handwritten documents?"
TECHNICAL

IDP handles typed and machine-generated text well. Handwriting support depends on OCR quality -- clean, consistent block-printed handwriting can work, but cursive or mixed-legibility handwriting is unreliable.

The honest answer: do not build a production workflow around handwritten documents without testing against a real sample set first. If handwriting is a significant portion of your volume, it deserves a scoping conversation of its own.

MuleSoft Intelligent Document Processing

IDP is MuleSoft's AI-powered document extraction product. It reads unstructured documents -- PDFs, scanned forms, faxes, email attachments -- and extracts defined data fields using prompt-based AI, then routes that structured data into Salesforce objects or downstream systems. No custom model training required.

Core Capabilities

OCR + AI Extraction
Combines optical character recognition with LLM-based prompting to pull structured fields from image and PDF documents.
Document Classification
Identifies document type using three fallback layers: folder path, filename convention, then AI-based content classification.
Prompt-Based Templates
Each document type gets its own extraction prompt. Prompts define what fields to pull, output format, and how to handle missing or ambiguous data.
Human-in-the-Loop Review
Extracted records receive a review status in Salesforce. No downstream action fires until a team member approves the extraction.
Audit Trail
Every manual correction is logged: document ID, field, user, and timestamp. Used to track extraction quality and guide prompt retuning.
Enterprise Security
Einstein Trust Layer filters PHI before it reaches any LLM. Zero data retention agreements with all LLM providers (OpenAI, Google, Anthropic).

Where IDP Sits in the MuleSoft Ecosystem

IDP is a capability within MuleSoft Anypoint Platform -- not a standalone product. The same platform license that covers IDP also covers integration flows, API management, and Salesforce connectivity. This is why the platform subscription is a prerequisite, not an add-on.

Common Document Types Handled

Highly Standardized
SBC Forms
Summary of Benefits and Coverage. Federally mandated format -- very consistent, excellent candidate for a single prompt template with high accuracy.
Medium Variance
Renewal & Invoice Docs
Generally consistent within a carrier but may need prompt variants across carriers. Renewals especially benefit from IDP when volumes are high.
High Variance
Carrier Quotes
Significant format variation by carrier. Requires grouping carriers by similar layouts and building prompt variants per cluster. Sample documents are critical during build.

Platform Capacity (Reference)

Standard Tier Capacity
IDP Pages / Year
300,000
Integration Flows
30 Flows
Message Volume
2M Messages / Year
Contract Term
12 Months (quarterly billing)

The 4-Step Processing Flow

01
Ingest
Document arrives from intake source (SharePoint, portal, email, SFTP)
02
Classify
IDP identifies document type using 3-layer fallback logic
03
Extract
AI prompt pulls named fields. Einstein Trust Layer filters PHI before reaching LLM
04
Route
Extracted data pushed to Salesforce objects. Record flagged for human review before downstream actions fire

Classification: 3-Layer Fallback

IDP tries each layer in order. If a layer produces a confident match, it stops. If all three fail, the document goes to manual review -- never force-fit.
1
Folder Path
The intake folder tells IDP what type of document to expect. Fastest and most reliable when intake is organized.
/invoices/ → Invoice type
2
Filename Convention
Filename patterns provide a secondary hint when folder structure alone is not enough.
SBC_2024_Carrier.pdf → SBC type
3
AI Content Classification
IDP reads document content to infer the document type when no external hints are available. Slower but handles unstructured intake sources.
AI reads first page → matches to Quote type
!
No Match → Manual Review Queue
If all three layers fail to produce a confident match, the document is flagged for human review. It is not processed or force-fit into an incorrect type. Bad data never silently enters Salesforce.

Prompt Architecture

Standard Approach
One Prompt Per Document Type
Start with a single canonical prompt per doc type. Define what fields to extract, expected output format, and how to handle missing or ambiguous fields. Works well for standardized formats (SBC, invoices).
High-Variance Approach
Prompt Variants Per Carrier Group
When carriers use significantly different layouts, group carriers by similar format clusters. Build one prompt per cluster. More prompt management, but necessary for accurate extraction across high-variance doc types like carrier quotes.
Prompt quality directly determines extraction accuracy. The more representative sample documents provided during build, the better the prompts can be calibrated. A minimum of 10-20 samples per document type is recommended before go-live testing.

Human-in-the-Loop Workflow

IDP Extracts
Fields pulled, confidence score assigned
Review Status Set
Salesforce record marked "review," assigned to team member
Human Reviews
Corrections made if needed, marked "processed"
Downstream Fires
PO creation, notifications, or other actions now trigger
Audit table: every manual correction is recorded -- opportunity ID, field changed, user, timestamp. This data identifies recurring problem fields and doc types, and guides prompt retuning decisions. It is also the evidence base for compliance audits.
These are the questions customers ask during proposal and scoping calls -- organized by category. Expand any question to see a full answer you can adapt in the moment.

Technical

Architecture & Functionality
What document formats does IDP support?

IDP processes PDFs (both digital-native and scanned), images (JPG, PNG, TIFF), and common office formats. OCR handles image-based and scanned inputs. Best accuracy comes from machine-generated PDFs where the text layer is already present. Scanned documents depend on scan quality -- 300 DPI or better is the baseline for reliable OCR.

Password-protected or encrypted PDFs require unlocking as a pre-processing step before IDP can read them.

Can we train the AI model on our specific documents?

IDP uses prompt-based extraction, not model training. You define what to extract through prompt templates, not by training a custom neural network. This means:

Setup is faster (weeks not months), changes are transparent (a readable prompt vs. a black-box model), and behavior is predictable and auditable. The tradeoff is that accuracy improvements require deliberate prompt retuning, not automatic learning.

Which AI model does MuleSoft IDP use under the hood?

IDP is model-agnostic -- it can be configured to use OpenAI (GPT-4), Google Vertex AI (Gemini), Anthropic (Claude), or Salesforce Einstein. The LLM used for extraction is configurable per Document Action.

All options operate under enterprise agreements with zero data retention. Customers can select the model that best fits their existing vendor relationships or compliance requirements.

How does it handle multi-page documents?

IDP handles multi-page documents natively. Extraction prompts can target specific pages, sections, or field positions, or search across the full document. For documents where data spans multiple pages (like long carrier quotes), the prompt is designed to account for that structure.

What is the confidence score, and what's considered acceptable?

IDP returns a per-field confidence score (0-100%) for each extraction. A high score means the model is certain about the extracted value; a low score flags the field for human review.

After proper prompt tuning on a representative sample set, 98-99% field-level accuracy is achievable for well-structured document types. Low-confidence extractions are automatically routed to the review queue rather than committed as-is.

What intake sources does MuleSoft IDP support?

MuleSoft Anypoint Platform has connectors for SharePoint, OneDrive, email (IMAP/SMTP), SFTP, AWS S3, Google Drive, and many others. Documents can be ingested from any source that MuleSoft can connect to -- which is most enterprise systems.

The intake source for a given implementation is confirmed during the discovery phase. SharePoint is the most common starting point for insurance and healthcare clients.

Commercial & Scope

Budget & Engagement
What does a typical IDP implementation include?

Standard scope covers: intake source configuration, document type definitions, prompt development per doc type, classification logic setup, human review workflow in Salesforce, audit table, go-live testing, and handoff documentation.

Out of scope by default: portal or bridge UI development, new document types added after SOW is signed, ongoing prompt maintenance (separate retainer), and custom model training.

How long does implementation take?

A standard implementation covering extraction, Salesforce integration, review workflow, and go-live typically runs 8-10 weeks. Complexity increases with the number of document types and the degree of variance within each type.

The most common delays: slow delivery of sample documents, undefined Salesforce field targets, and intake source access issues. A dedicated internal point of contact on the client side makes a significant difference.

What do we need to provide to get started?

Four things needed before build can begin:

1. Sample documents -- minimum 10-20 per document type (more is better for high-variance types)
2. Salesforce field map -- which object/field each extracted value should land in
3. Intake source access -- credentials or guest access to SharePoint / portal
4. Internal reviewer -- a designated team member who understands the documents and can validate test extractions

What if we add more document types after we go live?

Each new document type requires its own prompt development, testing cycle, and classification logic. Adding document types after initial go-live is treated as a separate SOW item -- it is not included in the original engagement.

This is important to communicate upfront: the initial SOW covers the agreed document type list. Scope creep through doc type additions is one of the most common project expansion vectors.

How is ongoing maintenance billed?

Minor prompt updates (format drift, small layout changes): hourly, typically resolved in days. Cost is minimal for isolated changes.

New document types or major format overhauls: require a new SOW. Treated as a separate project.

Operational support: DataSkate can provide ongoing monitoring and maintenance via a retainer agreement, or we train an internal technical resource during handoff.

Compliance & Security

HIPAA & Data Security
Is MuleSoft IDP HIPAA compliant?

Yes. MuleSoft and Salesforce maintain HIPAA Business Associate Agreements (BAAs). Einstein Trust Layer filters PHI before it reaches any external LLM. LLM providers operating under enterprise agreements with Salesforce have signed zero data retention agreements -- no patient data is stored or used for model training.

MuleSoft operates as a transport and orchestration layer, not a document store. Documents are processed in-flight; PHI does not persist in MuleSoft.

Who actually sees our data? What organizations have access?

The data flow is: your intake source → MuleSoft (transport) → Einstein Trust Layer (PHI filtered) → LLM provider (receives filtered prompt, no raw PHI) → extracted fields back to MuleSoft → Salesforce.

The LLM provider receives a processed prompt with PHI replaced by tokens. The raw document or raw PHI values never leave Salesforce's trust boundary. All LLM providers are enterprise-contracted with zero data retention obligations.

How is this different from someone using personal ChatGPT?

Personal / consumer ChatGPT: no zero retention agreement by default, data may be used to train future models, no audit trail, no enterprise controls, no HIPAA BAA.

MuleSoft IDP: enterprise-grade contractual protections, Einstein Trust Layer PHI filtering, full audit trail, zero training on submitted data, all processing within the Salesforce trust boundary. The comparison an IT or legal team needs: this is an enterprise API call under a BAA, not a chat session.

Does MuleSoft store our documents?

No. MuleSoft is an integration middleware -- it moves data, it does not store it. Documents flow through MuleSoft during processing and are not persisted there. The structured data extracted from documents is stored in Salesforce, which is already part of your existing data governance.

Post Go-Live & Maintenance

After Handoff
What happens after DataSkate hands off?

Handoff includes: documented prompt templates, extraction logic documentation, a trained super user (internal technical contact), and an audit baseline (so you know what good looks like from day one). DataSkate reviews the first 2-3 weeks post-launch as part of go-live support.

Ongoing support beyond that is either a DataSkate retainer or internal -- your choice. The prompts are readable text, not proprietary code, so a competent internal admin can maintain them with proper documentation.

How do we know when accuracy is degrading?

The audit table is the early warning system. A spike in manual corrections for a specific document type or field is the first signal of drift. Setting a baseline correction rate at go-live gives you a benchmark -- anything significantly above baseline warrants investigation.

DataSkate can set up periodic reporting from the audit table as part of a maintenance retainer, or the internal super user can monitor it directly in Salesforce.

Who can update the prompts internally?

Prompt updates do not require deep AI expertise. A Salesforce admin or an internal technical resource who understands the document types can maintain prompts with the documentation DataSkate provides at handoff. The prompts are plain-language instructions -- you do not need to understand neural network architecture to update them.

For major structural changes (new doc types, large format overhauls), DataSkate involvement is recommended.

Einstein Trust Layer

Salesforce's native AI security architecture. Think of it as a data firewall between your documents and any external AI model.
PHI / PII Masking
Before an extraction prompt is sent to the LLM, Einstein Trust Layer replaces sensitive fields (names, member IDs, dates of birth, SSNs) with tokens. The LLM receives a sanitized version of the document. After the response comes back, values are re-injected. Raw PHI never leaves Salesforce's environment.
Audit & Toxicity Filters
Einstein Trust Layer also runs toxicity filtering and maintains an audit log of all AI interactions. Every extraction request -- what was sent, what came back -- is logged for compliance review. This is part of the Salesforce platform, not an add-on.
Zero Data Retention (ZDR)
Salesforce holds enterprise agreements with LLM providers (OpenAI, Google, Anthropic) stipulating that submitted data is not stored, logged, or used for model training. ZDR is applied at the API level -- it is a contractual obligation backed by audit rights, not just a policy statement.
HIPAA BAA
MuleSoft and Salesforce maintain HIPAA Business Associate Agreements. This makes them eligible to handle Protected Health Information under HIPAA. The BAA covers the platform -- DataSkate's implementation must also follow HIPAA-compliant design practices, which we build in by default.

Data Flow Map

How PHI moves through the IDP pipeline
Source (SharePoint)
MuleSoft Anypoint
Transport layer only -- no persistent storage of documents
MuleSoft Anypoint
Einstein Trust Layer
PHI / PII is masked and tokenized here
Einstein Trust Layer
LLM Provider
Receives tokenized prompt only -- no raw PHI reaches here
LLM Provider
Einstein Trust Layer
Tokens re-hydrated with real values
Einstein Trust Layer
Salesforce
Structured extracted fields stored in objects -- governed by your existing Salesforce data policies

Enterprise vs. Consumer AI: The Comparison Legal Wants

Protection MuleSoft IDP (Enterprise) Consumer ChatGPT
HIPAA BAA MuleSoft / Salesforce signed BAA Not available on consumer tier
Zero Data Retention Contractually required of all LLM providers Data may be used for training by default
PHI Filtering Einstein Trust Layer masks before LLM Raw input goes directly to model
Audit Trail Full log of every AI interaction No enterprise audit logging
Access Control Salesforce role-based permissions Account-level only
How to explain it to legal or IT: "MuleSoft is the integration middleware -- a secure pipe that moves data. The AI extraction happens within Salesforce's trust boundary. External LLM providers have signed data processing agreements that prohibit storage or training on submitted data. PHI is masked before it ever reaches the AI model. The entire flow is logged and audited."
These are real limitations worth knowing before a call. Knowing them makes you credible -- trying to hide them makes you a liability. Most have workarounds; a few are hard stops.
IDP Does Not Self-Learn
IDP does not adapt automatically from corrections. Every accuracy improvement requires deliberate prompt retuning by the implementation team. The audit table identifies which fields and document types need attention, but a human has to make the update.
Why this is actually a feature for enterprise: predictable behavior, no invisible drift, every change is explicit and auditable.
High Document Variance Increases Complexity
Documents where every carrier uses a different layout (field names, positions, page structure) require multiple prompt variants -- one per carrier format cluster. This works, but it adds prompt management overhead and requires more sample documents upfront. Do not underestimate this for carrier quote processing.
Mitigation: collect at least 10-20 samples per carrier before build. More samples = better clustering = fewer prompt variants needed.
Handwriting Support Is Unreliable
OCR-based handwriting extraction is significantly less accurate than typed or digital text. Clean, consistent block printing can work, but cursive or mixed-quality handwriting is not production-ready without extensive testing. Do not promise handwriting support without validating against the client's actual document samples first.
Mitigation: test before committing. If handwriting is a major volume, scope a separate evaluation sprint.
Encrypted / Password-Protected PDFs Require Pre-Processing
IDP cannot read a document it cannot open. Password-protected PDFs need to be decrypted before ingestion. If a client's document workflow produces locked PDFs, a pre-processing step (unlock, then ingest) needs to be scoped in.
Cloud-Only Deployment
MuleSoft IDP runs as a cloud service within the Anypoint Platform. There is no on-premises deployment option for IDP. Organizations with strict on-premises data requirements need to verify their policies support cloud processing before this engagement can move forward.
New Document Types Are Not Free Additions
Each new document type requires prompt development, classification logic, and testing. Adding a new type after the SOW is signed is a scope change -- it will need its own timeline and budget conversation. This is not a platform limitation per se, but it is the most common scope creep vector in IDP engagements.
Establish the document type list with the client before signing. Add a change-order clause for additions.
98-99% Accuracy Is Not 100%
After tuning, expect 1-2% of extracted fields to need correction. For a high-volume workflow processing thousands of documents per month, that is still a meaningful number of manual reviews. The human-in-the-loop workflow handles this by design -- but clients should understand that IDP reduces manual work dramatically, it does not eliminate it entirely.
Frame this correctly in the proposal: "reduce from 100% manual to roughly 1-2% manual" is the right benchmark, not "zero manual work forever."
Anypoint Platform MuleSoft
The broader MuleSoft integration platform that IDP sits within. Includes API management, integration flows, connectors, and monitoring. IDP is one capability within Anypoint, not a standalone product. The platform subscription covers IDP plus these other tools.
Audit Table
A log maintained in Salesforce that records every manual correction made to an IDP-extracted record. Stores: document ID, field name, original value, corrected value, user, and timestamp. Used to identify recurring extraction errors and to guide prompt retuning decisions.
BAA Business Associate Agreement
A HIPAA-required contract between a covered entity (health plan, provider) and a vendor that handles Protected Health Information on their behalf. Salesforce and MuleSoft maintain BAAs, making them eligible to process PHI. A BAA must be in place before any PHI can flow through the platform.
Classification Layer
One of three methods IDP uses to identify what type of document it is processing: (1) folder path, (2) filename convention, (3) AI-based content classification. Each layer is tried in order; if all fail, the document goes to manual review.
Confidence Score
A 0-100% rating returned for each extracted field, indicating how certain the AI model is about the extracted value. Low-confidence fields can be automatically flagged for human review before the record is committed. After prompt tuning, 98-99% field accuracy is achievable for well-structured documents.
Document Action
A named processing pipeline configured in MuleSoft IDP for a specific document type. Each Document Action contains: the classification rules for that doc type, the extraction prompt, output field mapping, and routing logic for what happens after extraction.
Document Variance
Variation in layout, field positioning, label names, or page structure across documents of the same conceptual type. Example: different insurance carriers all produce "quote" documents but with completely different formats. High variance requires multiple prompt variants rather than one canonical prompt.
Drift
Gradual degradation in extraction accuracy that occurs when source document formats change over time. A carrier that updates their quote template mid-year causes drift because the existing prompt was calibrated for the old format. The audit table's correction rate is the early indicator of drift.
Einstein Trust Layer Salesforce
Salesforce's native AI security architecture. Sits between your data and external LLMs. Masks PII/PHI by replacing sensitive values with tokens before sending the prompt to the AI model, then re-injects values after the response returns. Ensures raw patient or member data never reaches the LLM provider.
Human-in-the-Loop (HITL)
A review mechanism where extracted records must be approved by a human before downstream actions fire. In the MuleSoft IDP implementation: extracted records receive a "review" status in Salesforce, are assigned to a team member, and no downstream action (like PO creation) triggers until the record is marked "processed."
IDP Intelligent Document Processing
MuleSoft's AI-powered document extraction product within Anypoint Platform. Reads unstructured documents (PDFs, scanned forms, images), uses OCR plus LLM-based prompting to extract defined fields, and routes structured data to Salesforce or other downstream systems.
LLM Large Language Model
The AI model that processes the extraction prompts and returns field values. MuleSoft IDP supports multiple LLM providers: OpenAI (GPT-4), Google (Gemini / Vertex AI), Anthropic (Claude), and Salesforce Einstein. The model used is configurable per Document Action.
OCR Optical Character Recognition
Converts image-based text (scanned PDFs, photos of documents) into machine-readable characters. IDP uses OCR as the first step for image-format inputs. Quality of OCR output depends on scan resolution (300 DPI or higher recommended) and document legibility.
Prompt Template
The instruction set that tells the AI what fields to extract from a specific document type, how to format the output, and how to handle missing or ambiguous fields. One prompt per document type is the starting point. High-variance types may need multiple prompt variants per carrier format cluster. Prompts are readable plain text -- not code.
Prompt Retuning
The process of updating extraction prompts to restore or improve accuracy. Required when document formats change (drift), when a new carrier is added to an existing doc type, or when the audit table reveals a systematic extraction error. IDP does not self-tune -- retuning is always a deliberate human action.
Review Queue
The Salesforce-based interface where extracted records await human approval. Records arrive with status "review" and are assigned to a team member. Until a human marks the record "processed," no downstream action fires. This is the human-in-the-loop checkpoint.
SBC Summary of Benefits and Coverage
A standardized 2-4 page insurance document required under the Affordable Care Act. Because the format is federally regulated, SBC documents are highly consistent across issuers -- making them an ideal starting point for IDP. A single prompt template typically handles all carriers for SBC extraction.
Zero Data Retention (ZDR)
A contractual agreement with LLM providers (OpenAI, Google, Anthropic) specifying that data submitted for processing is not logged, stored, or used for model training. Salesforce holds enterprise agreements with ZDR terms for all supported LLM providers. This is not the default for consumer AI products -- it requires an enterprise contract.

System Architecture

End-to-end view of how a document moves from source to Salesforce. Every box in this diagram corresponds to a real configured component.
Intake Sources
SharePoint
Web Portal
Email Inbox
SFTP
Direct Upload API
File event / webhook / poll trigger fires Mule flow
MuleSoft Anypoint Platform
Flow Engine / Runtime Orchestrator
Anypoint Runtime · Mule 4
Intake Flow
Classification Flow
Extraction Flow
Review Flow
Error Flow
document bytes + metadata routed to IDP Engine
IDP Engine
Intelligent Document Processing
OCR / Parse
Doc Classifier
Field Extractor
Confidence Score
extraction prompt built and passed to trust layer
Einstein Trust Layer Security gateway between IDP and external LLM
Detect PII / PHI fields
Replace with tokens
Send sanitized prompt to LLM
Receive extracted values
Re-inject real values
Audit log entry created
tokenized prompt sent (no raw PHI leaves Salesforce boundary)
LLM Provider (configurable per Document Action)
Zero Data Retention agreements on all
OpenAI GPT-4
Google Gemini
Anthropic Claude
Salesforce Einstein
extracted fields + confidence scores written via DataWeave transform
Output Layer
Salesforce Objects
Review Queue (status = "review")
Audit Table
Downstream Triggers (post-approval)

Component Reference

What each component in the diagram actually does, and what gets configured during implementation.
Flow Engine
Anypoint Runtime Orchestrator
The Mule Runtime Engine is the execution environment for all integration flows. Each flow is a named, independently deployable processing pipeline. The runtime handles triggering (file events, schedules, webhooks), error handling, logging, and routing between flows. All IDP logic runs inside flows managed by the runtime. Deployed and monitored from Anypoint Platform's Runtime Manager.
IDP Engine
OCR, Classifier, and Field Extractor
Three sequential operations: (1) OCR converts image or scanned input to machine-readable text. (2) The Classifier applies the 3-layer fallback (folder, filename, AI) to identify document type and route to the correct Document Action. (3) The Field Extractor runs the prompt template against the document text via the configured LLM and returns a structured JSON response with field values and confidence scores per field.
Einstein Trust Layer
PHI Masking and Compliance Gateway
Sits between the IDP extraction engine and the external LLM provider. Before the prompt is sent outbound, the Trust Layer scans for PII/PHI patterns (names, member IDs, SSNs, dates of birth, addresses) and replaces them with unique tokens. After the LLM returns extracted values, the Trust Layer re-injects the real values. The LLM provider only ever sees tokenized data. Every interaction is logged for compliance audit.
LLM Provider
Extraction Intelligence Layer
Receives the tokenized extraction prompt and returns a structured JSON response with extracted field values. The model does not store or learn from submitted data (zero data retention agreement). The LLM is selected per Document Action -- different doc types can use different models if accuracy or cost considerations warrant it. The IDP platform abstracts the model API, so switching providers does not require flow changes.
DataWeave Transform
Field Mapping to Salesforce
DataWeave is MuleSoft's data transformation language. After extraction, a DataWeave script maps each extracted JSON field to the corresponding Salesforce object field. This is also where default values, type coercions (string to number, date formatting), and conditional logic live. One DataWeave script per document type, maintained alongside the prompt template.
Audit and Review System
Human-in-the-Loop + Correction Logging
After writing to Salesforce, the flow sets IDP_Review_Status__c = "review" and assigns the record to a reviewer. A Process Builder or Flow in Salesforce handles reviewer assignment logic. After the reviewer corrects and approves, a correction event writes to the audit object: doc ID, field, original value, corrected value, user, timestamp. This audit object drives prompt retuning decisions.

Mule Flow Breakdown

The five flows built during a standard IDP implementation. Each is a separately named, independently logged processing pipeline inside Anypoint Studio.
Intake Flow
Trigger
File Listener
Read Bytes
Extract Metadata
Route to Classification Flow
Listens for new documents on the configured intake source (SharePoint, SFTP, etc.). Reads the file into a byte stream, extracts available metadata (filename, folder path, MIME type, upload timestamp), and passes the payload to the Classification Flow. No document-specific logic lives here -- this flow is source-agnostic by design so intake source can be swapped without touching extraction logic.
Classification Flow
Routing
Folder Hint Check
Filename Hint Check
AI Classification
Route to Extract
|
Route to Manual Queue
A Choice Router applies the 3-layer fallback: (1) check folder path against known type mappings, (2) check filename against regex patterns, (3) call IDP's AI classifier on the document text. If all three layers fail to produce a match above the confidence threshold, the document is routed to the manual review queue with a "classification failed" status. A matched document is routed to the appropriate named Extraction Flow based on its identified doc type.
Extraction Flow
Per Doc Type
Load Prompt Template
Call IDP via Trust Layer
Parse JSON Response
Score Fields
Route to Salesforce Write
One named flow exists per document type (e.g., sbc-extraction-flow, quote-extraction-flow). Loads the prompt template for that doc type, constructs the extraction request, and calls IDP which routes through the Einstein Trust Layer to the LLM. The JSON response is parsed: field values are extracted, confidence scores are evaluated per field, and any field below the threshold is flagged. The enriched payload is passed to the Salesforce Write Flow.
Salesforce Write Flow
Output
DataWeave Transform
Salesforce Upsert
Set Review Status
Assign Reviewer
Write Audit Entry
The extracted JSON payload is transformed by a DataWeave script that maps each field to its Salesforce object and field API name. The Salesforce connector performs an upsert (create or update) on the target object. After writing, the flow sets IDP_Review_Status__c = "review", populates the confidence score field, flags any low-confidence fields for reviewer attention, and assigns the record to the reviewer using configured assignment logic. An initial audit entry is created to mark the extraction event.
Error & Exception Flow
Catch-All
Catch Exception
Log Error Details
Create Error Record in SF
Notify Reviewer
A global error handler catches any exception from any flow -- network timeout, LLM provider error, OCR failure, Salesforce write error. Logs the full stack trace to Anypoint's CloudHub logging, creates an error record in Salesforce with the document metadata and error type, and notifies the configured reviewer. Documents that fail error handling are quarantined (not deleted) so they can be reprocessed manually once the root cause is resolved.

DataWeave Field Mapping

DataWeave is MuleSoft's transformation language. After IDP extracts fields, a DataWeave script maps the raw JSON to the correct Salesforce object fields. One script per document type.
IDP Raw Output (JSON)
// What IDP returns after extraction { "doc_type": "carrier_quote", "confidence": { "overall": 0.97, "per_field": { "group_number": 0.99, "annual_premium": 0.94, "effective_date": 0.98 } }, "extracted": { "insured_name": "Acme Corp", "group_number": "GRP-00421", "carrier_name": "United Health", "annual_premium": "142800.00", "effective_date": "2025-01-01", "plan_type": "PPO" } }
DataWeave Transform (to Salesforce)
// Carrier Quote extraction mapping %dw 2.0 output application/json --- { Name: payload.extracted.insured_name, Group_Number__c: payload.extracted.group_number default "", Carrier__c: payload.extracted.carrier_name, Annual_Premium__c: payload.extracted.annual_premium as Number default 0, Effective_Date__c: payload.extracted.effective_date as Date, Plan_Type__c: payload.extracted.plan_type, IDP_Review_Status__c: "review", IDP_Confidence__c: payload.confidence.overall * 100, IDP_Doc_Type__c: payload.doc_type }
DataWeave is the integration layer, not the AI. The AI handles extraction from unstructured text. DataWeave handles what happens after -- type coercions, default values, conditional field mapping, and writing to the right Salesforce API field names. A DataWeave error means a mapping issue, not an AI issue -- they are debugged separately.

Document Action Configuration

What gets configured in MuleSoft IDP for each document type. This is the full setup checklist per doc type during implementation.
SBC (Summary of Benefits and Coverage)
Classification
Folder: /sbc/ OR filename regex SBC_*.pdf
Prompt variants
1 (format is federally mandated, highly consistent across carriers)
Key fields
Plan name, deductible, OOP max, copays, coinsurance, network type
Confidence target
>99% achievable — most standardized doc type
Complexity
Low — good starting point for first IDP engagement
Carrier Quote
Classification
Folder: /quotes/ OR AI classifier (no filename convention possible)
Prompt variants
3-6 typical (grouped by carrier format cluster, not per carrier)
Key fields
Group number, carrier, effective date, annual premium, plan type, employee/dependent counts
Confidence target
95-98% after clustering — variance drives lower baseline than SBC
Complexity
High — requires significant sample docs and prompt iteration
Renewal Document
Classification
Folder: /renewals/ OR filename contains "renewal" OR "ren"
Prompt variants
2-3 (by carrier family — more consistent than quotes)
Key fields
Current premium, renewal premium, rate change %, effective date, plan continuation details
Confidence target
97-99% after tuning on representative set
Complexity
Medium — seasonal volume spikes during renewal season
Invoice
Classification
Folder: /invoices/ OR filename regex INV-*.pdf
Prompt variants
1-2 (carrier invoices reasonably consistent within a carrier)
Key fields
Invoice number, billing period, total due, due date, line items, carrier
Confidence target
98-99% — structured format with consistent field positions
Complexity
Low-Medium — line item extraction adds complexity for multi-line invoices
Sample documents are the single biggest driver of prompt quality. Ten samples per doc type is the minimum; twenty or more allows proper format clustering for high-variance types. Ask for sample docs -- ideally real production examples with any PHI removed -- as the first deliverable in the project kickoff checklist.