Responsible LLM Adoption for Fraud Detection with RAG Architecture

mastercard · Finance · 2024 · source Agentic: no · promotional bias: low · source-backed · extracted with prompt 0.5.6 (schema v2)

Generated from extraction.json — do not edit by hand. Every claim cites verbatim source evidence; stated means the quote directly asserts the claim, implied means it supports it indirectly.

Problem

Domain: Responsible enterprise LLM adoption for fraud detection and unstructured financial data

Mastercard wanted to use LLMs and unstructured enterprise data for high-value use cases such as fraud detection, but needed to control hallucination, attribution, staleness, revision rights, access controls, scalable infrastructure, and responsible AI governance in a regulated financial environment.

Constraints:

Architecture

Mastercard's responsible LLM adoption strategy centers on RAG: a foundation model is coupled to external memory from domain-specific data so answers can be grounded, attributed, updated, revised, and access-controlled. Around that core sit scalable ML infrastructure, foundation-model access, tools to customize/contextualize LLMs, data pipelines, retriever/generator optimization, specialized models for specific tasks, responsible AI principles, a governing body, and safeguards for privacy, security, reliability, access controls, and bias.

Diagram confidence: reconstructed (reconstructed from prose).

flowchart LR
  A["Unstructured enterprise data"] --> B["Domain-specific data pipeline"]
  A --> C["Access-control layer"]
  B --> D["Retriever and vector index"]
  C --> D
  D --> E["Foundation model generator"]
  E --> F["Specialized task models"]
  E --> G["Application layer"]
  G --> H["Scalable ML infrastructure"]
  I["Responsible AI governance"] --> C
  I --> F
  I --> G
Drag to pan · scroll or use +/− to zoom · reconstructed from the source's described component topology

Components

Component Role Interacts with
Unstructured enterprise data Domain-specific documents and data sources that can contextualize LLM outputs. Domain-specific data pipeline, Access-control layer
Domain-specific data pipeline Collects, prepares, and indexes enterprise context for LLM applications. Unstructured enterprise data, Retriever and vector index
Access-control layer Preserves enterprise permissions so LLM systems cannot access all data globally. Unstructured enterprise data, Retriever and vector index, Responsible AI governance
Retriever and vector index External memory layer that retrieves relevant context for the foundation model. Domain-specific data pipeline, Access-control layer, Foundation model generator
Foundation model generator LLM that formulates answers using retrieved domain context. Retriever and vector index, Specialized task models, Application layer
Specialized task models Task-specific models or fine-tuned generators aligned to particular enterprise use cases. Foundation model generator, Responsible AI governance
Application layer End-user LLM applications and intelligence-augmentation workflows. Foundation model generator, Scalable ML infrastructure
Scalable ML infrastructure Infrastructure for model serving, scaling up/down, and production operations. Application layer, Foundation model generator
Responsible AI governance Principles, governing body, strategy, safeguards, and risk controls. Access-control layer, Specialized task models, Application layer

Data flow

Unstructured enterprise data is collected and secured under existing access controls. A retriever selects relevant domain-specific context or vector-index content and provides it as external memory to a foundation model/generator. The generator formulates an answer grounded in that context, with sources available for attribution and revision. Responsible-AI governance and safeguards constrain which data/model paths are available to which tasks and users, while scalable ML infrastructure supports production use.

3 supporting quotes
“have it to contextualize or customize the contextual language models. So you can easily have this as an extended memory to to your language model”transcript, stated
“the solution to all of these problems is really to couple the foundation model to an external memory, also known as the rag.”transcript, stated
“the original setup remains as it is, but we have added this additional context, which is coming from your domain-specific data.”transcript, stated

Why this architecture

Mastercard presents RAG as the practical way to make enterprise LLMs factual, attributable, up-to-date, revisable, and customizable while preserving data access controls. The architecture acknowledges that production LLM work is mostly the surrounding system: infrastructure, data pipelines, safeguards, and governance rather than only model code.

3 supporting quotes
“You can also do as part of this rack setup. So you you have access to the sources coming out of your retriever.”transcript, stated
“this kind of architectures really reduces the hallucination of the LM systems.”transcript, stated
“the surrounding boxes around the LLM code or the adoption of foundation model is is really you know, accounts for more than 90%”transcript, stated

Models used: Large Language Models · foundation models · retriever/generator RAG models

Scale

Alternatives considered (roads not taken)

Foundation model used as-is, zero-shot/few-shot, or fine-tuned alone

Rejected because: Enterprises have accuracy, hallucination, attribution, staleness, revision, and customization constraints that standalone models do not solve cleanly.

“you have a foundation model, you use it as it is, zero-shot or few-shot learning, or even fine-tune it with your domain-specific data.”transcript, stated
“We really have hard time operationalizing such models because we have certain accuracy constraints.”transcript, stated

Naive RAG with retriever and generator as separate brains

Rejected because: The speaker argues production RAG should optimize retriever and generator together, and open-source model parameters now make generator fine-tuning possible.

“mainstream kind of rag that most of the people are doing right now is really having the retriever and and the generator as two separate brains”transcript, stated
“you can fine tune the generator to generate factual information based on what it gets from the retriever.”transcript, stated

A global LLM system with access to all enterprise data

Rejected because: Mastercard emphasizes preserving existing access controls and using specialized models for certain tasks.

“how do we make sure that we don't have a global LLM system that can really have access to all of the data that we have behind the scene.”transcript, stated
“we need to maintain the same access controls and and have certain specialized models that can work for certain tasks.”transcript, stated

Patterns

rag-retrieval (architecture)

Mastercard uses RAG/external memory to ground LLM answers in domain-specific enterprise data and enable attribution, revision, and freshness.

“couple the foundation model to an external memory, also known as the rag.”transcript, stated
“we have added this additional context, which is coming from your domain-specific data.”transcript, stated

safety-policy-enforcement (governance)

The adoption strategy is constrained by responsible-AI principles, a governing body, privacy/security/reliability safeguards, and bias controls.

“we have the seven the seven core principle of building responsible AI.”transcript, stated
“we we we also have this governing body and clear strategy that really enforces these core principles”transcript, stated

privacy-preserving-processing (security)

Access controls from enterprise systems must be preserved in LLM/RAG ecosystems so models do not see unauthorized data.

“how do we how do we preserve the access controls within our enterprises into their into these ecosystems.”transcript, stated
“we need to maintain the same access controls”transcript, stated

fine-tuning-adaptation (model-adaptation)

The talk identifies fine-tuning the generator on retrieved context as a way to make RAG more factual than naive separated retriever/generator designs.

“you can fine tune the generator to generate factual information based on what it gets from the retriever.”transcript, stated

observability-tracing (operations)

RAG sources provide attribution so teams can understand why the model generated certain text or decisions.

“you have access to the sources coming out of your retriever.”transcript, stated
“understand the why the model generated certain certain text or certain decisions.”transcript, stated

Tradeoffs

LLM grounding strategy

Chose RAG/external memory over foundation model alone or fine-tuning alone.

Rationale: RAG addresses hallucination, attribution, staleness, revision, and customization while keeping domain data swappable and source-backed.

“you can easily swap in out vector indices. So you can do the revision, you can do attribution”transcript, stated
“You can also do as part of this rack setup.”transcript, stated

AI strategy focus

Chose intelligence augmentation and current-risk mitigation over speculation about AGI replacement/doomsday.

Rationale: Mastercard frames generative AI as augmenting human productivity and urges focus on risks posed by current AI systems.

“it's really augmenting human productivity.”transcript, stated
“stop doing speculation about what AI will become tomorrow and what kind of risks that that will have tomorrow and really focus about the the current risks that it poses today.”transcript, stated

Production investment

Chose surrounding LLM pipeline, safeguards, infrastructure, and governance over model/LLM code only.

Rationale: The speaker argues the surrounding system accounts for more than 90-95% of production LLM application work.

“building this end-to-end pipeline, which is accounts for more than 95% of the work.”transcript, stated
“accounts for more than 90% of what goes into building such application.”transcript, stated

Gotchas (what bit them)

Standalone LLMs are hard to operationalize in enterprise settings.

Root cause: They create accuracy, hallucination, attribution, staleness, revision, and customization problems.

Resolution: Use RAG/external memory and surrounding production infrastructure rather than relying on the model alone.

“So, basically, the hallucination, and they do it very, you know, confidently.”transcript, stated
“Attribution, you know, we can't really understand why the models are saying what they are saying.”transcript, stated

RAG is not just attaching a separate retriever to a generator.

Root cause: Naive RAG leaves retriever and generator as disconnected brains, which may not optimize factual generation.

Resolution: Optimize or fine-tune the generator to use retrieved context, enabled by open-source model parameters.

“the retriever and and the generator as two separate brains that don't that none of them knows that each other exist.”transcript, stated
“you can fine tune the generator to generate factual information based on what it gets from the retriever.”transcript, stated

Access control is a production RAG problem, not only an enterprise data problem.

Root cause: A global LLM/RAG system could accidentally see data beyond a user's/system's authorization.

Resolution: Preserve existing access controls and use specialized models for certain tasks.

“I'm sure most of the organizations that you work with have access controls that you you can have access to certain systems but not the others.”transcript, stated
“we need to maintain the same access controls and and have certain specialized models that can work for certain tasks.”transcript, stated

Evaluation

The source reports a high-level production outcome for fraud detection and discusses evaluation/design concerns for LLM production systems: hallucination reduction, attribution, access controls, retriever/generator optimization, scalable infrastructure, and responsible AI safeguards.

Metrics: Up to 300% boost in fraud detection in some cases · More than 80% of organizational data is unstructured · 71% of organizations struggle managing/securing unstructured data · LLM/ML code less than 5% of the end-to-end pipeline · Surrounding LLM application boxes more than 90% of the build

3 supporting quotes
“used LLMs, generative AI specifically, to boost fraud detection in some cases by 300%.”transcript, stated
“most of the organizations data is unstructured.”transcript, stated
“accounts for more than 90% of what goes into building such application.”transcript, stated

Outcomes

The source gives one headline fraud-detection result and broad enterprise data statistics, but not a detailed benchmark or deployment architecture for the fraud model itself.

3 supporting quotes
“used LLMs, generative AI specifically, to boost fraud detection in some cases by 300%.”transcript, stated
“You can't really use this kind of transformative technology in your business without really being a challenged in so many ways.”transcript, stated
“It's all about putting the AI in production and and the whole other boxes around ML code or the LLM”transcript, stated