Swaran Soft
Enterprise AI

Intelligent Document Processing: Automating Procure to Pay

November 19, 20267 min readBy Yogesh Huja, Founder & CEO
Intelligent Document Processing: Automating Procure to Pay

Within India, AP processes are usually very similar. Invoices can be emailed, shared via WhatsApp and received via couriers – all in various physical and digital forms. They are then downloaded, data manually entered onto an ERP, cross-referenced with a purchase order and goods receipt note and GST numbers confirmed. Approvals are sought and payments organised.

Whilst there is often manual entry and cross-referencing involved, this is time-consuming and error-prone. Towards the end of quarters invoice volumes can increase and suppliers frequently contact businesses to enquire about payments. Businesses also often miss early payment discounts.

Intelligent document processing (or IDP) utilises artificial intelligence to analyse documents for example, invoices and purchase orders. Relevant data is extracted, cross-referenced against business rules and systems and then either posted or approved. Here we explain how IDP is applied to procure to pay and how best to implement it.

IDP versus OCR

Optical character recognition (OCR) has been in use for many years and allows text to be recognised from a scanned image. However, it does not comprehend the content. For example, although it can recognise the figure ‘18,450.00’ on an invoice it will not know if this relates to taxable value, IGST or net payables.

IDP builds on OCR and adds comprehension. Alongside OCR, AI identifies the structure of a document and analyses data points such as supplier details, GSTIN, invoice reference, date and line items together with HSN/SAC codes, taxes and totals. Layout variation can also be analysed and there is no requirement for individual supplier templates. Furthermore, newer IDP solutions use large language models which can analyse atypical layout, handwriting and multiple languages.

Whilst data extraction is an important function, it is the automatic validation, cross-referencing and distribution of information which involves the majority of manual intervention at present.

Procure to pay process

Capture

An AP mailbox, supplier portals, paper and even WhatsApp are all automatically sourced for documents. These are analysed to determine if they are an invoice, credit note, purchase order, delivery challan or other type of document and then directed along the appropriate process route.

Extraction

The header and detail sections of a document are analysed. For Indian invoices this will typically include both supplier and customer GSTINs, place of supply, HSN/SAC codes, tax rates and CGST, SGST and/or IGST values. Information such as e-invoice IRN and QR codes will also be analysed if applicable. A confidence rating is allocated to each data point.

Validation

The extracted data is then analysed and validated against business rules. Is the sum of invoice line items equal to the overall invoice value? Have taxes been correctly calculated for the place of supply? Is the supplier’s GSTIN both valid and current? Has an invoice reference already been used? Is the invoice date in an appropriate period? Issues are highlighted instantly rather than during a reconciliation process.

Matching

An invoice is cross-referenced with a purchase order and goods receipt note within an ERP. Quantities, values and product must all align. Tolerance levels can be defined so minor variances are accepted but more significant ones are directed to a person for analysis.

Approval and posting

Once fully validated, invoices can then be automatically posted into an ERP. Those requiring approval are forwarded to the correct person together with clear information regarding why approval is required (for example, “line item unit price 4% higher than that shown on the PO” or “GRN quantity short by 20 units”). Following approval, an invoice is posted and payments organised.

Purchase orders and other documents

Purchase orders can also be similarly automated on the sales side. Customers often send POs in differing formats and sales colleagues frequently manually enter these into an order system. IDP can analyse products, quantities and delivery dates. It can then validate this information against price lists and inventory levels and generate a sales order for review.

Further documents such as delivery challans, e-way bills and credit/debit notes can also be similarly analysed. This allows finance to holistically view transactions.

Benefits to expect

BenefitExpected benefit
Data entryManual data entry for standard invoices is greatly reduced.
Process speedPreviously week(s) long invoice processes are reduced to days or even hours.
AccuracyPrevention of double payments and value miscalculations prior to posting.
Supplier relationsReduced supplier contact regarding payments. Payment patterns become more regular.
Cash controlIncreased likelihood of benefiting from early payment discounts.
Audit preparednessAll documents, together with extraction and approval actions, are recorded and traceable.

The specific benefits will vary according to factors such as business volume, supplier base and ERP master data quality. It is advisable to analyse present invoice costs and timescales in order to effectively demonstrate future improvements.

Factors for successful implementation

Good quality master data is even more crucial than a good AI model. Even if extraction is functioning well, if a supplier’s GSTIN or vendor code in an ERP is incorrect or duplicated then matching will not be successful. As part of your project therefore, establish a plan to tidy up master vendor data.

As with the automated process, careful thought should go into defining how exceptions are dealt with. Consider who will address which exception, how swiftly and on which screen. Should exceptions end up in somebody’s email, again the process will suffer from re-introducing manual intervention.

Low confidence data should also be manually reviewed. Gradually, AP colleagues can refine IDP models and so continually increase the proportion of invoices which are automatically processed.

ERP integration is vital. Whether your business operates on SAP, Oracle, Microsoft Dynamics, Tally or a bespoke solution, postings should be made using suitable APIs or connectors. Screen scraping should not be used.

Data security and regulation

Invoices contain highly-sensitive data, for instance supplier pricing, banking details, volumes and margins. Many finance heads are uneasy about submitting such information to third party cloud AI services. IDP can operate fully on-premise or within a private Indian cloud. Open source OCR and language models can be used, so data remains in-house. This simplifies compliance with the DPDP Act together with internal audit procedures. Our financial compliance service also complies with requirements set by the RBI and DPDP in this manner.

Implementation stages

StageTimeframeActions
BaselineWeeks 1-2Analyse invoice volumes and timescales together with error levels. Obtain example invoices for key suppliers. Assess master vendor data.
BuildWeeks 3-5Configure capture, extraction, validation and ERP three-way matching functionality.
TestWeeks 6-7Test alongside the current process. Compare outcomes and refine validation and confidence settings.
Go liveWeek 8Automatically process invoices for the initial supplier cohort. Monitor exceptions on a daily basis.

Generally, the greatest initial impact is seen by focusing on those suppliers who supply the greatest number of invoices. Additional suppliers can then be included in subsequent waves.

Deciding which documents to automate

Whilst all document types could in theory be automated, initially it is best to target documents which are high-volume, have common formats and for which the subsequent process is well-defined. Supplier invoices generally comply with these criteria and can thus be well-suited for automation. Secondary documents such as utility and professional charges are generally better introduced at a later stage as they require additional time to define approval process rules.

Consider also where late payments result in supplier fines and/or early payment discounts are frequently lost. Focus on these suppliers as they will benefit most from automation. Associating the initial implementation with clear financial benefits greatly aids gaining agreement to roll-out further.

Actions to take

Review invoice data from last quarter to establish how many were issued by your top twenty suppliers. Should these account for a high level of volume then it makes sense to initially implement IDP for them.

Swaran Soft has been implementing enterprise solutions for over 25 years. We develop document automation, based on open source technology, within your environment. ERP integration is available and there is no vendor dependency.

Want to talk it through with us? We run a free 45-minute AI Pilot Assessment. Drop a line to info@swaransoft.com, or ring +91 9220-313-650 (India) | +971-50-9292-650 (UAE). You'll find more at www.swaransoft.com

Common queries

Free 45-minute AI Pilot Assessment

Share this article:
Yogesh Huja — Founder & CEO, Swaran Soft
Yogesh HujaFounder & CEO

AI Architect and Entrepreneur building India's Edge AI ecosystem. 25+ years in enterprise technology. Founder of Swaran Soft, Gignaati, and Copilots.in.

Published: ⏱ 7 min read