Skip to content
Integriti
Integriti

Case study: AI document processing

AI document processing, from pilot to production

For a workers' compensation pharmacy claims administrator, we built AI document processing into their claims platform. It reads the correspondence, pulls out the data and sends anything uncertain to a person. Piloted in August 2026, it has been live in production since mid-November 2026.

  • About 40,000pages processed in a single day
  • Over 9 in 10fields extracted correctly so far, with anything uncertain sent to a person
  • Minuteson demand, or a few hours when batched at lower cost

The challenge

The client processes US workers' compensation pharmacy correspondence from insurance carriers and bill review companies: EOBs (explanations of benefits), EORs (explanations of review), remittances, denial letters and general correspondence.

Their operations team handled it by hand. Correspondence arrives in batches received through the bank. A batch can hold many files, and a single file can run to 50 or 100+ pages. Associates allocated pages to the right claims one by one, so a batch could take weeks, and a large backlog built up.

How it works

Each batch runs through a pipeline of stages, with specialised models for each stage. Every value is scored and traced to its pages, and nothing uncertain is guessed.

  1. Bank batches

    In the claims platform's storage

    • EOBs, EORs, remittances, denial letters and general correspondence
    • Files of 50 to 100+ pages
  2. Document AI pipeline

    Specialised models for each stage

    • Segmentation and classification
    • OCR, with a second engine as a fallback
    • Extraction with confidence scores and page numbers
    • Anything uncertain goes to a person
  3. Claims platform

    Database and correspondence allocator

    • Drug lines matched to existing claims
    • The batch allocated automatically
Illustration of how the data flows.
  1. Read from storage

    Documents are read from the claims platform's own storage.

  2. Segmentation

    Each file is separated into the documents it holds.

  3. Classification

    Each document is classified by its type, such as an EOB, an EOR, a remittance or a denial letter.

  4. OCR

    Pages are read by OCR, with a second OCR engine as a fallback for the rare pages where the first result doesn't hold up.

  5. Extraction, scored and traced

    Extraction pulls out the 18 fields, and every claimant and every line gets a confidence score and the page numbers it came from.

  6. Human review

    Anything uncertain goes to a person instead of being guessed.

  7. Saved and matched

    Results are saved to the claims platform's database, and the platform is notified when the batch finishes. It matches each drug line to an existing claim automatically.

  8. Allocated automatically

    The platform then triggers its correspondence allocator, which allocates the batch automatically.

What it extracts

The 18 fields cover the claimant and each drug line.

Claimant

  • First name
  • Last name
  • Date of birth
  • Social Security number
  • Date of injury
  • Venue state

Each drug line

  • Drug description
  • NDC
  • Rx date
  • Rx number
  • Invoice number
  • Quantity
  • Amount billed
  • Allowance amount
  • Response or denial codes
  • Code descriptions

Some files label the invoice number “Account #”, and both are handled.

From pilot to production

  1. August 2026

    Pilot (MVP)

    Tested on 212 real documents (820 pages) before the full build.

  2. September 2026

    Production build

    About two and a half months of building for production.

  3. Mid-November 2026

    Live in production

    Running inside the claims platform since mid-November 2026.

The results

About 40,000 pages processed in a single day. So far, more than 9 in 10 fields are extracted correctly, and anything uncertain is sent to a person.

Before

Manual allocation

Reading
Associates went through every page by hand
Allocation
Pages allocated to the right claims one by one
Turnaround
A batch could take weeks, and a large backlog built up
After

AI document processing

Reading
OCR and AI extraction, with a confidence score and source pages for every claimant and line
Allocation
Drug lines matched to existing claims, and the batch allocated automatically
Turnaround
On demand within minutes, or batched at lower cost within a few hours

What we learned

Odd documents, such as blank pages or an account number where an invoice number was expected, went to human review instead of being guessed. They are being added to the system.

Security and privacy

The documents carry claimant data. This is where that data goes at each stage, and how it is protected.

  • Run by the claims platform

    The pipeline is run by the claims platform's own API service. Documents are read from the platform's S3 storage, and extracted data is stored in its database.

  • Segmentation and extraction within AWS

    Segmentation and extraction run on Amazon Bedrock, within AWS.

  • OCR, deleted after reading

    Pages go straight to Mistral's OCR endpoint, and our own system deletes the files sent for OCR right after reading.

  • Classification over an authenticated API

    Classification calls an external decision model service directly over an authenticated API. Under our account terms, the service doesn't retain any data sent to it.

  • Page images deleted

    Page images are deleted once a document finishes.

  • Keys kept out of the code

    API keys live in the platform's configuration store, not in code, and calls between the platform and the document processing service require an API key.

  • The same permissions as the platform

    Access to documents and extracted data follows the platform's existing user permissions.

  • Our AI providers

    Built on Amazon Bedrock and Amazon Textract, with Mistral's OCR service. AWS holds ISO 27001 certification and SOC 2 attestation reports, and Amazon Bedrock and Amazon Textract are on AWS's list of HIPAA eligible services. Mistral holds ISO 27001 certification and a SOC 2 Type II attestation report.

See it on documents like yours

In a 30-minute demo with our CEO or CTO, we'll walk through the process on de-identified sample documents and talk about what a pilot on your documents would look like.

  • Extraction on de-identified samples, step by step
  • Confidence scores, page citations and the review queue
  • What a pilot on your own documents would involve
Document types

Please don't send documents that contain patient or claimant information through this form.

We'll use your details to respond to your enquiry. See our privacy policy.