How Ramp Fixes Merchant Matches with AI

Chami Lamelas, Anton Biryukov16 Jun 2025

Problem

Ramp maps each card transaction to a merchant record (name, website, category, logo). The input is the card acceptor name from the payment processor (for example PTI*BRYANTPARKWV), the merchant category code (MCC) and the location, which are often vague or misleading. A wrong match blocks the customer: a hotel classed as entertainment puts the expense out of policy for a lodging-only travel fund. Staff handled only 3% of correction requests in 2023 and 1.5% in 2024, each taking hours.

Example from the article: the acceptor name SERVICE FEE appears on transactions of many government agencies. The MCC is identical and the location unreliable, so only user context tells them apart.

Solution in brief

An LLM agent takes the user's correction (merchant name, website, category) and picks one action from a closed list: create a merchant, update one, or reassign the transaction. It sees the MCC, receipt data, memos and K related merchants retrieved by embeddings and by name. Guardrails limit allowed actions and reject hallucinated outputs.

Questions this case answers
  • How to resolve user-reported entity mismatches automatically when the source record is vague and user input alone cannot be trusted
  • How to constrain an LLM agent that edits a shared reference database so that it cannot take invalid or high-impact actions
  • How to evaluate an LLM agent in production when manual review does not scale and no ground truth exists
  • How to let customers correct a wrong merchant match on a card transaction without hours of support and engineering work?

Tools and methods

  • Multimodal RAG — builds context from receipts, memos and related merchants
  • Embedding similarity plus name matching — retrieves K candidate merchants
  • Guardrails — restrict actions, validate outputs, retry on invalid ones
  • LLM as a judge — scores actions at 100+ requests a day, also in shadow mode
  • Second LLM — rewrites rejection reasons in plain language
Continue reading — it's free

Google or a one-time email code. No password.