How banks evaluate an LLM before production deployment
How a bank should evaluate an LLM before production deployment: a CI evaluation harness, expert-built test sets, calibrated judges and audit-grade evidence.
To evaluate an LLM before production deployment, a bank tests it on its own cases, not public benchmarks: expert-labelled test sets that mirror live traffic, deterministic checks for anything that can be stated as a rule, calibrated LLM judges for the rest, and human review for high-stakes outputs. The evaluation runs on every model, prompt or configuration change, blocks promotion below agreed thresholds, and stores evidence an auditor can replay.
Banks operate under strict expectations for accountability and evidence. The Bank of England and FCA's 2024 survey found that 75% of UK financial services firms already use AI and that a third of use cases are third-party implementations, so for many banks the model under evaluation is one they do not control. An LLM that scores well on public leaderboards can still breach policy or drift after release, and it may leave no reproducible record of how a decision was formed.
Human review stays in place throughout, and our field note on a model upgrade, covered below, shows why.
What LLM evaluation means in a regulated bank
LLM evaluation is the systematic measurement of an application's output quality against explicit criteria such as correctness, faithfulness, helpfulness, safety and compliance. Langfuse describes evals as a repeatable check of an application's behaviour that runs across the engineering loop, including in CI to catch regressions before they ship.
In banking the artefact under review is the decision plus the reproducible evidence that justifies it: the policy version in force, the inputs the agent saw, the documents it retrieved, the tools it called and what they returned, the final output, the model snapshot, prompt version and decoding settings, and the scores that gated release or escalation. If the model produces reasoning text, store it as model output, not as the explanation: Chen et al.'s 2025 paper 'Reasoning Models Don't Always Say What They Think' shows their stated reasoning often omits what actually drove the answer. For a third-party model the bank never sees the weights, so the evidence has to come from how the model behaves on the bank's own cases.
Evaluation must therefore cover two surfaces at once. Offline test sets catch regressions against known cases before a change ships. Online traces catch drift, novel user behaviour and failure modes that never appeared in the lab. Langfuse's November 2025 evaluation roadmap states that effective evaluation blends offline work on curated datasets with online work on live production traces, because each surface catches errors the other misses.
The framework must also support the spectrum from human-in-the-loop review to semi-autonomous operation. The same criteria, evidence schema and gate contracts apply at every point on that spectrum. What changes is how often a human must intervene; the decision stays auditable throughout.
In AI-native engineering this is the Validation stage: engineering pipelines continuously test system behaviour, enforce policy and evaluate AI components, while human engineers remain responsible for architecture, constraints and judgement. For the wider context, see Generative AI for regulated enterprises.
Why evaluating an LLM before production deployment belongs in the pipeline
Pre-deployment evaluations function as integration tests for probabilistic systems. They run automatically with every meaningful change to prompts, models, retrieval, tools or business logic, and they block promotion when scores fall below agreed thresholds. Without that integration, each model upgrade becomes a manual re-test event with uneven coverage and slow sign-off.
LLM outputs vary between runs, even at temperature 0, so one run proves little. Thinking Machines Lab (September 2025) traces most of that variation to inference kernels that are not batch-invariant, running under varying server load. Run each case several times and report the pass rate with its spread, compare the candidate with the incumbent on the same cases, and size the test set for the smallest regression that matters at each risk tier. For example, with 200 cases at 90% accuracy the 95% confidence interval is roughly plus or minus 4 points, so a 2-point drop sits inside the noise. Pin the model snapshot and decoding settings in the evidence package so that a rerun tests the same thing.
GitHub's August 2026 guidance on evaluating LLMs before production treats offline evaluation like end-to-end integration testing: rerun it whenever the prompt, model, input construction or surrounding system logic changes, and keep results comparable against a known baseline. That discipline is what makes evaluation a release control.
For UK banks, building societies and PRA-designated investment firms with internal model approval for regulatory capital, PRA SS1/23 (in force since 17 May 2024) expects development testing that shows a model works as intended, testing of material model changes that compares outputs before and after, and vendor models validated to the same standard as in-house ones; other firms may find the principles useful. Where an LLM is part of a high-risk system under the EU AI Act, such as assessing the creditworthiness of individuals, the Act requires testing before it is put into service (high-risk obligations apply from 2 December 2027), against metrics and probabilistic thresholds defined in advance. That duty falls on the provider, which is the bank when it builds the system itself. Ad-hoc testing outside the pipeline cannot show that every candidate passed the same checks. Pipeline-bound evals produce that proof as a side effect of shipping.
Continuous evaluation also creates the data flywheel that keeps semi-autonomous systems aligned with policy. Offline failures become new cases, online failures become new offline cases, and thresholds tighten as the organisation learns which failure modes matter. When evaluation sits outside the pipeline, that flywheel never starts, and model upgrades remain high-risk events rather than routine, gated releases.
For engineering leaders, the operational test is simple. If a prompt change can reach production without an automatic eval run and a recorded verdict, the bank does not yet have production-grade control over the LLM path.
When the model itself changes
In a bank, a new LLM usually arrives as a provider release or a deprecation under an existing application. Pin explicit model versions and treat every upgrade as a change with its own test cycle, using the repeated-run comparison above. In our field note on a model upgrade that broke production, a fraud investigation AI service moved from a preview to the GA release of Gemini 2.5 Pro. The GA release improved on published benchmarks and latency, yet structured findings degraded into generic alerts that were still schema-valid and passed threshold checks. Domain specialists caught it. The fix was a domain harness of more than 200 real production inputs in CI and a canary on 10% of traffic for 24 hours before promotion.
The lesson applies to any provider. An upgrade can regress a specific task whichever vendor ships it, so a better benchmark score is a reason to run the harness, never a reason to skip it.
Building the evaluation foundation: traces, datasets and ground truth
Structured traces are the primary evidence artefact. Each trace should record the intent, the agent and tool steps (each tool call and what it returned), the documents retrieved, the model snapshot, prompt version and decoding settings, the policy version and the final output, in a form that can be replayed. Without that structure, scores cannot be reproduced, and an auditor cannot verify that the policy applied at decision time was the policy the bank believed was in force.
Ground-truth datasets must be created by domain experts. Correctness in regulated workflows often depends on policy interpretation, product rules and jurisdictional nuance rather than statistical pattern match. An LLM can draft candidate pairs and surface edge cases, but human review remains mandatory before those pairs enter the harness. Synthetic labels without expert sign-off are directional only; they are not audit evidence.
Offline datasets should mirror real production traffic distributions. GitHub's guidance puts it directly: "The closer the offline pipeline is to the production pipeline, the more useful the evaluation becomes." In a bank that means sampling live intents, stratifying by product, channel, risk tier and language, and refreshing the set on the same cadence as model or policy updates. Those samples are customer data held for a new purpose, so pseudonymise them, minimise them to the fields the test needs, control access, and retain them only as long as the dataset version is in use. A static golden set that no longer resembles live traffic creates false confidence.
Evidence storage must be audit-grade. Every score, dataset revision, policy version, reviewer identity and timestamp should be immutable and queryable for as long as the bank's record-keeping obligations require. An evaluation harness is a programmatic test suite that runs the system against fixed inputs and grades the outputs; in a regulated bank the harness also emits the evidence package that gates the change. If the package cannot be reconstructed six months later, the evaluation did not finish its job.
Evaluation metrics and methods, and when each applies
Measure seven dimensions, each against the incumbent model on the same cases. Thresholds are set per bank and per risk tier, so the table names what to measure and how, not a target value.
| Dimension | What to measure | Method |
| Correctness | Field-level precision and recall; exact match on extracted values | Code evaluators against the expert set |
| Grounding | Share of claims supported by the cited source; source attribution accuracy | Calibrated judge plus a human sample |
| Policy compliance | Pass rate on disclosure and prohibited-content rules | Code evaluators |
| Security | Attack success rate for prompt injection and data leakage (OWASP LLM01, LLM02) | Red-team suite |
| Refusal behaviour | Wrong refusals on in-scope requests; answers given to out-of-scope ones | Labelled set |
| Stability | Pass-rate spread across repeated runs; confidence distribution against baseline | Repeated runs |
| Operations | p95 latency, cost per 1,000 requests, error rate | Load test at expected volume |
The field-level measures in the Correctness, Grounding and Stability rows follow our field note on the model upgrade, which tracked entity precision and recall, evidence type accuracy, confidence distribution and source paragraph attribution. Each method in the table is described below.
Code evaluators provide deterministic checks: exact match, regex, schema validation, allow-lists, deny-lists and explicit policy rules encoded as tests. Langfuse positions code evaluators as compact, deterministic checks that run quickly across many observations, including in production. Use them first for anything that can be stated as a rule. Format failures, missing mandatory disclosures and schema breaks should never wait for a human or an LLM judge.
LLM-as-judge scores subjective criteria such as helpfulness, faithfulness and tone at scale. Langfuse advises calibrating an LLM judge against a small set of human-annotated examples, and NVIDIA warns that judges can carry biases from their own training data. Treat the judge as a dependency: pin its version, recalibrate when it changes, and do not let a model judge its own family. Known judge biases include favouring the first answer shown, longer answers and outputs from their own model family, so randomise answer order in pairwise comparisons. Zheng et al. ('Judging LLM-as-a-Judge', 2023) found that strong judges reached over 80% agreement with human preferences on general chat quality, the same level humans reach with each other; banking tasks need their own measurement. Judge scores should gate a release only once agreement with expert labels, measured with a chance-corrected statistic such as Cohen's kappa, clears a minimum the bank sets.
Reference-based metrics such as BLEU and ROUGE compare outputs to predefined references. Reference-free metrics assess intrinsic qualities such as toxicity and coherence without a single gold answer. Databricks' October 2025 note on LLM evaluation methods draws that distinction. For narrow answers such as a product fact or a regulatory citation, extract the value and check it with exact or normalised match. Overlap metrics such as BLEU and ROUGE score "Article 26(5)" and "Article 26(6)" as near-identical, so they have little place in bank evaluation; G-Eval (Liu et al., 2023) also reports that they correlate poorly with human judgement. Reference-free metrics help for safety screens. Neither replaces domain ground truth for high-stakes decisions.
Red-team testing runs a maintained suite of attacks against the full application, including direct and indirect prompt injection and attempts to extract sensitive data, and reports the share that succeed. Load testing replays traffic at expected volume to measure p95 latency, cost per 1,000 requests and error rate before go-live.
Human annotation remains necessary for high-stakes or ambiguous cases: credit exceptions, sanctions edge cases, complaint handling and any output that could create customer harm or regulatory exposure. User feedback and implicit signals (thumbs, re-asks, escalations, correction rates) then detect drift after deployment and feed new cases into the offline set.
Map methods to risk. Deterministic rules and calibrated judges can clear low-risk bulk traffic. Human review owns the tail where uncertainty or impact is high.
Decision framework: release gate, runtime checks and online monitoring
A bank LLM needs three control points, each with its own job. The release gate decides whether a model, prompt or configuration version may be promoted: the offline harness runs in CI and blocks promotion on failure. Runtime checks decide whether one request and its response may proceed: a policy check on the request before the agent plans, and a deterministic validator on every model output and tool call before anything acts on it. Online monitoring checks that production behaviour still matches what the release gate approved. Before production, the harness tests the runtime checks too: how often they block legitimate requests and how often they let a bad output through.
Release gate. Run the full harness on every candidate version and block promotion when any dimension falls below its threshold. Engineering owns the harness and risk owns the thresholds, which are explicit and versioned. An independent validation function, separate from the team that built the system, should review both before a material change is promoted. SS1/23 expects firms in its scope to tier their models and scale the depth of independent review to the tier and to the materiality of the change, so a minor prompt edit and a model swap do not get the same review.
Request check. Evaluate the incoming request against policy before the agent plans or calls tools. Check jurisdiction, product eligibility, data-residency constraints, prohibited intents and risk score. Requests that fail are rejected or routed to a human path with a durable record. A request check cannot see what the model will produce, which is why it never stands alone.
Output validator. Check the completed decision artefact against safety, faithfulness, schema and compliance thresholds before it takes effect. The artefact includes the final answer, the supporting evidence the agent claims and the trace that produced it. Our field note on putting the guardrail in the validator describes moving a guardrail out of the prompt and into a small piece of deterministic code.
Online monitoring. Track the same dimensions on sampled production traffic, alert when they move outside the range the release gate approved, and promote failures into the offline set.
Escalation. When a risk score, judge disagreement or an uncertainty signal (disagreement across repeated samples, a failed verifier check, or claims not supported by retrieved evidence) exceeds defined bounds, the workflow escalates to a human reviewer with the full trace attached. Escalation is the control that keeps autonomy bounded. Define who reviews, under what SLA, and how the human decision writes back into ground truth; the human-in-the-loop guide covers the routing.
Evidence contract. Every control point (pass, fail or escalate) emits the policy version, dataset or rule version, scores, actor identity and timestamp. That package is what audit queries, and a gate that writes no record cannot be shown to have run.
Change thresholds through the same pipeline controls as prompts and models, so they live in versioned release configuration. Many bank LLM uses, such as summarisation, extraction and drafting, involve no agent at all; the same three control points apply, with the request check reduced to input policy. For agentic workflows the control points stay the same, and moving from human-in-the-loop to semi-autonomous operation means widening what the runtime checks may clear on their own while the release gate and monitoring stay in place.
Common pitfalls and how to avoid them
Treating public model benchmarks as production guarantees. Leaderboard scores measure general capability on public tasks. They do not measure your policy, your product language or your escalation rules, and our field note shows a GA release that beat its preview on published benchmarks while degrading a production task. Use benchmarks to shortlist models. Use the pipeline harness to decide whether a model may serve customers.
Relying solely on LLM-as-judge without human calibration. Judge models are convenient and scalable, but they carry biases from their training data, and their agreement with experts degrades when the judge model or the traffic changes. Maintain calibration samples, track agreement with expert labels, and keep humans on the high-stakes tail. A judge score with no measured agreement behind it gives the validation function nothing to review.
Allowing test sets to drift from live traffic. A golden set frozen at pilot time slowly stops representing production. Audit dataset coverage on the same cadence as model and prompt changes. Promote pseudonymised production failures into offline cases, and retire cases the product no longer serves.
Relying on one control point. A release gate cannot see an instruction injected through a retrieved document; a request check cannot see a wrong figure in the answer. Each point catches failures the others miss. The OWASP Top 10 for LLM Applications 2025 lists indirect injection through external content under LLM01 and outputs passed downstream unchecked under LLM05.
Skipping audit-grade storage. Scores that live only in a chat log or a notebook cannot be reconstructed under regulatory timelines. Persist traces, scores and versions in immutable, queryable form from day one.
Where to start
Start with an inventory of every LLM path already in production. For each one, find where a failed evaluation stops promotion and where an output can take effect without a check, and close those gaps first. Pin model versions, and require an evidence package on every promotion.
Further reading
Frequently asked questions
Q01What is the difference between offline and online LLM evaluation?
Q02Why can't we rely on LLM-as-judge alone for banking use cases?
Q03How do we create ground-truth data for regulated workflows?
Q04Where should the evaluation gate sit in an agentic workflow?
Q05What evidence must be stored for audit?
Q06How often should we re-evaluate after deployment?

Principal · AI Native Platform Engineering
Principal for AI-native platform engineering at Bugni Labs. GCP-native architecture, GitOps, and DevSecOps, including HYPER, the internal platform for automated GCP environment setup. 18 years in technical architecture, around nine in UK financial services.
The Engineering Notebook
Once a month, a long read on what we're learning building governed AI for regulated enterprises. No hot takes, no roundups.