11 min read

Financial Document Classification: Invoices, Statements, Contracts

Automatically classify and route incoming financial documents by type. Sort invoices, statements, receipts, contracts, and tax forms without manual triage.


The document sorting problem

Every accounting department has an inbox problem. Documents arrive from dozens of sources -- email attachments, vendor portals, scanned mail, internal submissions -- in a continuous stream. Invoices, bank statements, receipts, contracts, tax forms, regulatory correspondence, internal memos. Each type needs to go to a different person, a different workflow, a different system.

In a typical mid-size company, the accounting department receives 200-500 documents per week. Someone -- usually a junior staff member or an administrative assistant -- opens each document, determines what it is, and routes it. Invoice goes to accounts payable. Bank statement goes to reconciliation. Contract goes to the controller for review. Tax notice goes to the tax team. Unidentifiable document goes into a growing pile of things to figure out later.

This manual triage is slow, inconsistent, and error-prone. A vendor invoice that gets misclassified as a statement sits unprocessed until someone notices, potentially causing a missed payment. A tax notice that gets buried in the general correspondence pile may not surface until after a deadline passes. And the person doing the sorting can only process documents as fast as they can open, read, and route them -- typically 30-60 seconds per document if the classification is obvious, several minutes if it requires reading and judgment.

The cost isn't just the triage labor. It's the downstream delay. Every document that sits in the wrong queue or waits in the sorting pile is a document that isn't being processed. In finance, processing delays translate directly to late payments, missed discounts, compliance gaps, and reporting delays.

Classification categories

Financial documents fall into well-defined categories, though the boundaries can be subtle.

Invoices. Bills from vendors requesting payment. Key indicators: invoice number, "amount due" or "balance due," payment terms, vendor banking details, line items with quantities and prices. Variations include pro-forma invoices, credit notes (negative invoices), debit notes, and self-billing invoices.

Statements. Account summaries showing activity over a period. Bank statements list transactions and balances. Vendor statements list invoices sent and payments received. Credit card statements list charges. Key indicators: statement period, opening and closing balance, transaction list, account number.

Receipts. Proof of payment for completed transactions. Key indicators: "paid" or "receipt" label, payment confirmation number, zero balance due. These overlap with invoices -- the difference is whether payment has already occurred.

Contracts and agreements. Legal documents establishing terms between parties. Key indicators: signature blocks, effective dates, terms and conditions sections, recitals or "whereas" clauses, defined terms. Variations include purchase orders, service agreements, NDAs, lease agreements, and amendments.

Tax forms and notices. Government-issued documents related to tax obligations. Key indicators: government agency letterhead, tax identification numbers, filing periods, assessment amounts. Includes 1099s, W-9s, VAT returns, and compliance notices.

Correspondence. Letters and emails that don't fit other categories: payment reminders, account change notifications, price increase announcements.

The challenge is that many documents share visual characteristics. A payment receipt from a vendor looks similar to an invoice. A statement of account can be confused with an invoice summary. A purchase order resembles a contract. Accurate classification requires reading the content, not just scanning the layout.

Multi-signal classification

Effective document classification uses multiple signals rather than relying on a single indicator.

Layout analysis. The physical structure of the document provides initial clues. Invoices tend to have a header with vendor details, a table of line items, and a summary with totals. Contracts tend to be multi-page with numbered paragraphs. Statements tend to have columnar transaction listings. Tax forms tend to have structured boxes and fields.

Content analysis. The text content is the strongest classification signal. Specific terminology ("invoice," "statement," "agreement," "notice of assessment") directly indicates document type. But terminology alone can mislead -- a letter discussing an invoice is correspondence, not an invoice.

Metadata. File names, email subjects, and sender addresses provide contextual signals. A file named "INV-2026-0412.pdf" from invoices@vendor.com is almost certainly an invoice. A file named "scan_20260705.pdf" from a shared scanner gives no useful signal.

Structural patterns. Signature blocks suggest a contract. A table with "debit" and "credit" columns suggests a statement. A barcode linking to a payment system suggests an invoice.

docrew uses all of these signals together. The agent reads each document completely, evaluates multiple classification signals, and assigns a category. When signals conflict (the document says "invoice" but has the structure of a statement), the agent weighs the signals and can flag the document for human review.

Confidence scoring

Not every document can be classified with certainty. A well-designed classification system must distinguish between confident classifications and uncertain ones.

docrew assigns each classification a confidence level based on signal strength and consistency.

High confidence. Multiple signals agree. A document labeled "Invoice" with an invoice number, line items, an amount due, and payment terms is unambiguously an invoice. Route it directly to accounts payable without human review.

Medium confidence. Most signals agree but there is some ambiguity. A document that looks like an invoice but is labeled "Pro-forma" might be a quote rather than a payable invoice. Route it to AP but flag it for verification of whether it's actually payable.

Low confidence. Signals conflict or are insufficient. A scanned document with poor image quality where the text is partially illegible. A document in a format the system hasn't encountered. A multi-purpose document that contains both an invoice and a contract amendment. Route it to a human for manual classification.

The goal is to handle 70-85% of incoming documents automatically (high confidence), route 10-20% with flags (medium confidence), and escalate 5-10% for manual classification (low confidence). Over time, as the classification instructions are refined based on edge cases encountered, the high-confidence rate increases.

Routing to appropriate workflows

Classification is only useful if it triggers the right downstream action. Each document type maps to a specific workflow.

Invoices route to accounts payable. The AP team processes the invoice: enters it into the accounting system, matches it to a PO, schedules payment. Priority routing can separate invoices by amount, by vendor, or by urgency (past-due invoices to the top of the queue).

Statements route to reconciliation. Bank statements go to treasury. Vendor statements go to AP for cross-referencing against recorded invoices and payments.

Contracts route to the controller or legal. Amendments need comparison against existing terms. Renewals need decision on continuation.

Tax documents route to the tax team or external tax advisor. Time-sensitive documents get priority routing with deadline tracking.

Correspondence routes based on content. Payment-related correspondence goes to AP. Price notifications go to procurement.

docrew handles this routing by organizing classified documents into designated output folders, each corresponding to a workflow destination. The agent can also generate a classification log -- a spreadsheet listing every document processed, its assigned category, confidence level, and destination.

The docrew workflow for document classification

Here is the concrete process for setting up automated document classification with docrew.

Step 1: Set up the folder structure. Create an input folder where all incoming documents are placed. Create output folders for each category: invoices, statements, receipts, contracts, tax-documents, correspondence, needs-review.

Step 2: Define classification rules. Tell the agent: "Classify each document in the input folder into one of these categories: invoice, statement, receipt, contract, tax document, correspondence. For each document, provide the classification, confidence level (high/medium/low), and a one-line reason. Move high-confidence documents to their output folders. Move medium and low-confidence documents to the needs-review folder with a note explaining the ambiguity."

Step 3: Run classification. The agent processes every document in the input folder. It reads each one, evaluates classification signals, assigns a category and confidence level, and moves the file to the appropriate output folder.

Step 4: Review exceptions. Open the needs-review folder and the classification log. Review the flagged documents, correct any misclassifications, and note patterns that could improve future classification instructions.

Step 5: Iterate. After the first batch, refine the classification rules based on what you observed. If the agent consistently misclassifies a particular vendor's credit notes as receipts, add a rule: "Documents from Vendor X with negative amounts are credit notes -- classify as invoices."

Practical scenario: incoming document triage for an accounting department

A regional manufacturing company receives approximately 300 financial documents per week from 80 vendors, government agencies, banks, and internal departments. Currently, a full-time administrative assistant opens every document, identifies the type, and forwards it to the appropriate person. This takes 15-20 hours per week.

With docrew, the workflow changes. All incoming documents are dropped into a single input folder (automated via email rules and scanner output). The agent runs classification daily.

Results after the first month of operation:

  • 78% of documents classified with high confidence and routed automatically
  • 15% classified with medium confidence and routed with review flags
  • 7% sent to needs-review for manual classification

The administrative assistant's role shifts from full-time document sorting to reviewing the 22% that needs attention. That takes 3-4 hours per week instead of 15-20. The remaining time is reallocated to higher-value work.

After three months of refining classification rules based on edge cases, the high-confidence rate reaches 85%. The needs-review rate drops to 4%. The weekly human time on document triage is under 2 hours.

Accuracy and error handling

Classification accuracy matters because misrouted documents cause downstream problems. An invoice classified as correspondence doesn't get paid. A tax notice classified as a statement doesn't get escalated.

Two types of errors occur in document classification.

False positives. A document is classified as category X when it should be category Y. A payment reminder (correspondence) classified as an invoice (payable document). This causes unnecessary processing and needs to be caught during AP review.

False negatives. A document in category X is classified as "unknown" and sent to needs-review. This is less harmful -- the document still gets human attention -- but it defeats the purpose of automation if it happens too often.

The cost of these errors is asymmetric. A false negative (sending to review) costs review time but prevents processing errors. A false positive (wrong category) can cause real financial harm: paying a non-payable document, missing a tax deadline, ignoring a contract obligation.

docrew's confidence scoring minimizes false positives. When signals are ambiguous, the agent errs toward lower confidence, routing the document to human review. Documents that are automatically routed can be trusted at a high rate, while uncertain documents always get human eyes.

For organizations where misclassification has significant consequences, classification rules can be tuned for maximum caution: any document from a government agency goes to needs-review regardless of confidence. The automation handles the routine bulk while humans handle the sensitive edge cases.

Scaling classification

Document classification becomes more valuable as volume increases. At 50 documents per week, manual sorting is feasible. At 500 per week, it's a full-time position. At 5,000 per week, it's a team.

docrew's classification scales linearly with volume and requires no additional configuration for higher throughput. The same classification instruction that handles 50 documents handles 5,000. Processing time increases proportionally, but since it runs unattended, the human time stays constant -- you only review the exceptions.

For organizations processing high volumes, the classification step can be combined with extraction. Classify each document and extract key metadata in the same pass: for invoices, extract the vendor and amount; for contracts, extract the parties and effective date; for tax notices, extract the deadline and assessment amount. This metadata appears in the classification log, giving the receiving team immediate context without opening the document.

This combined classify-and-extract approach turns the incoming document stream from an undifferentiated pile of PDFs into a structured, searchable, routable flow of categorized financial data. Every document is identified, every document is routed, and every document has its key data captured -- all without uploading a single file to a cloud service.

Back to all articles