Fraud Detection with AI: Ensemble of AI Models Improve Precision & Speed
A detailed look at a multi-model AI architecture for fraud detection that combines the speed of predictive machine learning for structured data with the contextual understanding of encoder LLMs for unstructured data, enabling faster and more accurate real-time decisions.
Every financial transaction, from a payment transfer to a claim, must be evaluated for fraud in less than 200 milliseconds. This speed requirement necessitates the use of AI models that can analyze patterns, learn from historical data, and make decisions rapidly.
The Traditional Approach: Predictive Machine Learning
Historically, fraud detection platforms have relied on traditional machine learning models, referred to as “predictive ML.” These include algorithms like logistic regression, decision trees, random forests, and gradient boosting machines.
These models are trained on large, labeled datasets containing both fraudulent and legitimate past transactions. They analyze dozens of features from structured data—such as transaction amount, time, location, merchant category, and user spending history—to produce a risk score.
However, predictive ML has limitations:
- Novelty Blindness: New or subtle fraud tactics that don’t match known patterns can evade detection.
- Data Limitation: These models generally ignore unstructured information, such as free-form text descriptions, memos, and images.
Cases that are ambiguous or contain these attributes are typically escalated for manual human review, creating a bottleneck and delaying the decision-making process.
The Ensemble Approach: Combining Predictive ML with Encoder LLMs
A more advanced solution involves an ensemble of AI models, which pairs predictive ML with a transformer-based Large Language Model (LLM). Specifically, this approach uses an encoder LLM, a non-generative model focused on natural language understanding (NLU).
Unlike decoder LLMs (like chatbots) that generate content, encoder LLMs (such as BERT or RoBERTa) excel at tasks like text classification, named entity recognition, and sentiment analysis. They can grasp nuanced language patterns, detect contextual clues, and extract key information from unstructured data.
For example, an encoder LLM can:
- Analyze the text in an online funds transfer, such as “Refund for overpayment. Please rush,” and recognize the urgency and phrasing common in scams.
- Examine a merchant name and free-form address for signs of spoofing or association with known fraudulent entities.
- Identify linguistic patterns in a wire memo, like “urgent investment guaranteed 200% ROI,” that are clear indicators of a scam to a human but don’t fit neatly into a spreadsheet.
Comparing the Models
Predictive ML
- Pros: Microsecond latency, low compute requirements, simple scaling, and an easy-to-follow audit trail. It excels at spotting anomalies in structured data, like sudden spending spikes or impossible travel scenarios.
- Cons: It is “pattern-bound” and can be easily bypassed by new scam techniques that use clever wording.
Encoder LLM
- Pros: Highly context-aware and language-savvy. It can connect dots in unstructured data that humans might miss, significantly reducing false positives by understanding the context behind suspicious-looking transactions.
- Cons: More computationally intensive, with millions or billions of parameters that require significant processing power, often with GPU acceleration, to run inference.
A Two-Stage Workflow for Efficient Detection
To leverage the strengths of both models, a multi-model AI fraud detection workflow is implemented:
- Stage 1: Initial Screening with Predictive ML: All incoming transactions first pass through the predictive model. It analyzes the structured data and generates an initial fraud score and a confidence level.
- Decision Point:
- If the model has high confidence (the score is either well below or well above the risk threshold), the transaction is immediately routed for a final decision—auto-approved or flagged as fraud.
- If the model has low confidence (the score is in a borderline range), the transaction is escalated to the second stage.
- Stage 2: Deep Analysis with Encoder LLM: The ambiguous transaction, along with its structured features and any available unstructured data (e.g., transaction descriptions, customer profile notes), is sent to the encoder LLM.
- Final Decision Engine: The LLM performs a deeper, context-aware analysis. The final decision engine combines the LLM’s assessment with the original model’s score. A borderline transaction might be definitively flagged as fraud based on incriminating text or cleared because the context was found to be innocuous.
This architecture ensures that the computationally expensive LLM is only used when necessary, maintaining system efficiency. Straightforward cases are processed with minimal overhead, while trickier cases receive a “second look” from a more sophisticated AI, improving overall accuracy and reducing the need for human intervention.
The Critical Role of Infrastructure
Running a multi-model system in real-time requires specialized hardware. On-chip AI accelerators are crucial for handling low-latency inference at scale, allowing the fraud detection models to run directly where the data lives. This hardware makes it possible to catch fraud in milliseconds, not minutes.
By combining the predictive power of traditional ML with the contextual reasoning of LLMs, this multi-model architecture provides a smarter, more resilient defense against evolving fraud tactics.