Three-Way Match MCP

How an AI Agent Can Make Sure You Pay Only for What You Ordered and Received

Before paying a supplier, three documents should agree: what you ordered, what you received, and what you’re being billed. In real life, they rarely do.

A delivery arrives in two parts. One invoice covers three receipts. Two invoices come against one purchase order. The supplier bills by the box and your stores count in pieces. The price is a little above the PO, and there’s a freight line nobody ordered. Your ERP’s strict match fails on all of it, so clerks override it. Or the check is skipped, or done by hand, and you end up paying for goods that never arrived or at prices above the PO.

A Three-Way Match agent closes that gap. Not a chatbot that says an invoice “looks fine.” An agent that matches every invoice line to its receipt and PO lines, works out the quantity and price differences, and tells you how much is safe to pay now and why the rest is on hold. This isn’t a nice-to-have feature. It’s the difference between paying for what arrived and paying for what was billed.

Accounts Payable Controls

What This Agent Can Actually Do

Stop thinking of it as a strict ERP rule. Think of it as a standing AP controller that checks every invoice line against what was ordered and received, and shows its reasoning.

A Three-Way Match agent, built the right way, gives you:

A line-by-line match of invoice, receipt and purchase order

Each invoice line is matched to the receipt and PO lines it belongs to, by item code or, where there isn’t one, by description.

Partial deliveries and split documents handled

One invoice covering several receipts, several invoices against one PO, and partial deliveries are all matched, without using any received quantity twice.

Different units reconciled

“Box of 10” on the invoice and “pcs” on the receipt are converted using the factors you supply. If a conversion is missing, the line is held and listed, never assumed to be equal.

Quantity and price variances shown

Where the invoice differs from the PO or the receipt, you see exactly how much, in quantity and in price.

A verdict for every invoice

Match, within tolerance, or hold. Tolerances are your policy: you set how much price and quantity variance is acceptable.

The amount safe to pay now, and the amount on hold

Only the held part is held. The rest is ready for release, and each hold has a reason, such as over-billed quantity, price above the PO, no receipt or no PO.

A whole payment run checked at once

Check a full batch of invoices in one go, so no receipt is counted against two invoices.

Goods received but not yet invoiced

A list of receipts that haven’t been billed, useful for month-end accruals.

A variance report

Price and quantity differences by supplier and by item, so you can see where problems repeat.

This is what separates a three-way-match agent from an ERP’s strict check: it doesn’t just pass or fail an invoice. It works out what is payable, what isn’t, and why. It recommends. Your AP team releases or holds. Every unmatched payment is money that may not come back.

Who This Is For

This isn’t built for auditors only. It’s built for the people who decide whether an invoice gets paid.

If you’re on an AP Team

You match invoices to POs and receipts all day, and the awkward ones take the time. This gives you the answer for each invoice, with the payable and held amounts separated.

If you’re in Purchasing or Stores

You know what was ordered and what actually arrived. This makes sure the invoice reflects it, and shows you which receipts haven’t been billed.

If you’re a Finance Controller

You want to prevent overpayment, not recover it afterwards. This shows the variances by supplier and gives you the accrual list at month-end.

If you’re in Internal Audit

You want evidence for every payment. Each match shows which PO and receipt lines it relied on, and why.

If you work in Manufacturing, Distribution, Healthcare or Construction

Your purchasing is document-heavy and deliveries are often partial. This is built for exactly that kind of messy flow.

If you’re a Developer or Agent Builder

You’re building an AP agent that must not queue a payment it shouldn’t. This gives you a tool your agent can run on the whole payment run before anything is paid, and pass the holds to a person. It takes invoices, POs and receipts as input and returns matches, variances and payable and hold amounts. Setup takes minutes, not weeks.

If none of this is your job, but you manage someone whose job it is

This is the section to forward. The cost of not having it is the invoice paid in full for goods that were never received.

One thing this isn’t for

If you’re looking for a fully automated payables system that releases payments on its own, this isn’t that, and it won’t pretend to be. It never approves, releases or pays anything. It recommends, and your AP team releases or holds. The tolerances are your company’s policy, not ours. Lines with incompatible units and no conversion are held, never guessed. If there’s no PO or no receipt, the invoice is held with the reason. And it isn’t accounting advice. This is for people who want a defensible match with the working shown, and want to stay in control of the payment.

Why Teams Choose Us Over Other AI Agents

Generic AI Agents / Chatbots Us
Consistency Different answer each time you ask — probabilistic, hard to trust twice Deterministic — same input, same output, every time
Cost to run Re-processes your entire dataset through an LLM on every query Purpose-built models, minimal token usage — cheap enough to run on the open book; pipelines larger than 500 leads can score locally
Reliability A 0–100 score invented in the chat — confidently wrong when the closed sample is thin Fits conversion from your outcomes, shows a range when it should, and refuses to fit when there isn't enough data — honesty instead of a bluff
Data privacy Your data often leaves your systems, sits with a third party Full SOC 2 compliance — no data ever leaves your premises

In short: Other agents give you an answer. This gives you conversion probabilities, money at risk, and a daily queue you can defend, reproduce, and put in front of your security team without a fight.

The Math Behind the Match — Not Invented, Just Applied

We didn’t build new matching models and hope your documents behave. Everything underneath is operations research and record-linkage methods that have been used for decades.

What It Does Method In Use Since
Allocates received quantities across invoice lines so the total mismatch is smallest and no receipt is used twice Assignment problem (Hungarian algorithm) and min-cost flow 1955
Finds a split invoice, where several invoices or lines add up to what was received Subset-sum dynamic programming 1957
Matches items by description when there’s no item code, weighing several fields together Fellegi-Sunter record linkage 1969
Scores how alike two item descriptions are, even with typos or abbreviations Jaro-Winkler similarity 1990
Decides whether a difference is small enough to pay or large enough to hold Tolerance bands Established audit practice

Why this matters to you: every layer here has been published, cited, and used on real data for decades before we ever touched it. We didn’t ask an LLM to “see if this invoice looks right.” We match your documents line by line the way an AP controller would: reproducible, defensible, and the same result every time you ask.

That’s what “deterministic” actually means. Not a marketing word. A math word.

What’s the difference between using ChatGPT (or another LLM) and using this Three-Way Match agent?

ChatGPT and other LLMs are built to talk. Ask them whether an invoice matches your PO and receipts and they generate the most plausible-sounding answer, which is exactly why they’re brilliant at explaining three-way matching and unreliable at doing it across a whole payment run.

Here’s the practical difference:

  • An LLM guesses. This agent matches. Ask ChatGPT “can we pay this invoice?” and you get a reasonable-sounding opinion, not a line-by-line match to your PO and goods receipt. Ask twice, get two different opinions.
  • An LLM can’t allocate quantities reliably. When one receipt is shared across several invoices, or one invoice spans several receipts, the quantities have to add up exactly and no receipt can be used twice. That takes a proper allocation method, not a chat reply.
  • An LLM can’t audit itself. If it says “pay this,” there’s no evidence of which PO and receipt lines it relied on. This agent shows the match line by line and the reason for any hold.
  • An LLM is a general-purpose tool wearing a controller’s hat. This is a purpose-built system that uses AI where it helps (conversation, explanation) and hands the part that has to be right, the matching, to methods built for exactly this problem.

The short version: ChatGPT can explain what a three-way match is. It can’t reliably tell you how much of this invoice is safe to pay today. That’s the gap this agent exists to close.

What will the Three-Way Match agent actually do?

In plain terms, it takes your purchase orders, goods receipts and supplier invoices, and does three things:

  1. Matches every invoice line to the receipt and PO lines it belongs to, converting units where you’ve given it the factors.
  2. Works out the variances in quantity and price, and applies your tolerances.
  3. Tells you what is payable and what isn’t, and why. Not a pass or fail, but a clear result: “Pay for the quantity received at the PO price now. Hold the difference: part of the quantity wasn’t received, and the unit price is above the PO.”

That’s the whole point of the agent: it turns a manual check into a payable amount with reasons.

Is this too complicated to set up?

No, this isn’t an engineering project. If you can export your purchase orders, goods receipts and supplier invoices from your accounting software or ERP, such as Tally, you already have everything the agent needs. Add your tolerances, and unit conversions if suppliers bill in different units.

Just follow the step-by-step tutorials we provide, and you’re up and running in minutes: no models to train yourself, no code to write. There’s a free tier you can try without a sales call.

The short version: if you can export your documents, you can match your first invoice today. Follow the step-by-step tutorial.

Is my data safe?

Yes. This is built to be fully SOC 2 compliant, and your data never leaves your premises.

The agent is stateless: your data is processed in the request and never stored, and each user signs in with their own OAuth login. There’s no export to a third-party cloud and no black-box vendor holding your records. Purchase orders, receipts and invoices are business data, but this was built with data protection as a requirement from day one, not an afterthought.

The short version: you get the intelligence, not the exposure.

What are the matches based on?

They’re based on operations-research and record-linkage methods that have been researched, tested, and used in production for decades, not a new algorithm hoped to work.

The agent looks at three things: whether the item is the same (by code, or by description where there’s no code), whether the quantities and units line up across the PO, receipt and invoice, and whether the price is within your tolerance. From that it allocates quantities across the documents and works out what is payable.

The short version: it isn’t guessing from patterns in text, like a general AI chatbot would. It’s calculating, using methods that have had decades to prove themselves.

What’s the difference between deterministic and non-deterministic results, and which one are we using?

Non-deterministic means: ask the same question twice, get two different answers. This is how most general AI chatbots work. They generate the most likely-sounding response each time, even when nothing about your documents changed. Fine for drafting a note to a supplier. Risky when the answer decides how much gets paid.

Deterministic means: same data in, same answer out, every single time. If a verdict changes, it’s because your documents or your tolerances changed, not because the model rolled different dice.

What we use: deterministic, every time. The matches this agent gives you come from fixed methods, not a language model guessing at what looks right. That’s what lets you show an auditor why part of an invoice was held and know it holds up if someone re-runs it tomorrow.

The short version: we don’t give you a verdict you have to hope is right. We give you the same, defensible verdict, every time you ask.

What happens when units differ, such as “box of 10” and “pcs”?

You supply the conversion factors, and the agent applies them. They’re shown so they can be confirmed per supplier, because a wrong conversion can change the result. If a line has incompatible units and no conversion, the agent doesn’t assume they’re equal. It holds the line and lists it for someone to resolve.

The short version: it never guesses a unit conversion to make a match work.

Does it release payments automatically?

No. It never approves, releases or pays anything. It gives a verdict for each invoice (match, within tolerance or hold) and the amount safe to pay now, and your AP team releases or holds. The tolerances are your company’s policy, which you set. It isn’t a fully automated payables system, and it isn’t accounting advice.

The short version: it recommends. Your team decides.

Ready to Stop Paying for What You Didn’t Receive?

You already have the data. Your POs, goods receipts and invoices have everything this agent needs; you just need to know how to connect it. We’ll walk you through exactly how, step by step.

How to Build an AI Agent →

No credit card. No AP-system replacement. Just your document exports and a few minutes.

AI Text
  • Coming Soon
Download the app
playstore-button applestore-button windows-button
Company
Join Us