---
title: AML / financial-crime monitoring with an investigator loop
url: https://gurkanozkan.ai/learn/design/mle-aml-financial-crime-monitoring-with-an-investigator-loop-10/
markdown: https://gurkanozkan.ai/learn/design/mle-aml-financial-crime-monitoring-with-an-investigator-loop-10.md
kind: design
role: ML engineering
json: https://gurkanozkan.ai/api/learn/design/mle-aml-financial-crime-monitoring-with-an-investigator-loop-10.json
---

# AML / financial-crime monitoring with an investigator loop

Detect money-laundering patterns across transfers and accounts, generate alerts for investigators, and learn from their outcomes.

## Constraints

- 10M customers
- 20M transfers/day
- investigator capacity 2k cases/day
- regulatory filing timelines

## What to cover

- **Requirements**: Detect money-laundering patterns across transfers and accounts, generate alerts for investigators, and learn from their outcomes.
- **Estimates**: 10M customers; 20M transfers/day; investigator capacity 2k cases/day; regulatory filing timelines.
- **API**
- **Data model**
- **Architecture**: Shared graph of customers, accounts, devices and counterparties with network features (PageRank, communities, label propagation).; Transaction-level and customer-level models; typology-specific detectors (structuring, mule networks).; Label platform with versioned, auditable ground truth and quality scores.; Alert prioritisation; investigator UI with explanations; active learning.; Shadow-mode path for new models; governance and model-risk documentation.
- **Deep dives**
- **Trade-offs**: recall vs investigator workload; explainability vs model power (GNNs); per-typology models vs one model; latency (real-time blocking vs batch monitoring).
- **Evaluation**: Offline: precision@capacity (top-k per day), recall on confirmed cases, per-typology precision drift.; Online: SAR conversion rate, time to alert, investigator hours per confirmed case.; Label-drift monitoring.

## Reference design

### Requirements

**Functional**: monitor transfers and account behaviour for money-laundering typologies (structuring, mule accounts and networks, rapid pass-through, funnel accounts); generate prioritised alerts and group them into cases per customer or network; give investigators explanations and a network view; record outcomes (SAR filed, no further action, exit relationship) as labels; learn from them.

**Regulatory constraints (UK)**: Money Laundering Regulations 2017 and POCA; SARs to the NCA, with defence-against-money-laundering requests subject to statutory notice periods; tipping-off rules; five-year record keeping; model risk management and explainability expectations; ability to justify why something was or was not alerted.

**Latency modes**: batch monitoring (daily) for most typologies; near-real-time scoring for outbound payments where a hold is justified — since 30 October 2024, UK payment providers may delay an outbound sterling push payment executed within the UK by up to four business days when they have reasonable grounds to suspect fraud or dishonesty by someone other than the payer (relevant to mule flows; suspected laundering itself goes through the SAR and DAML route).

**Assumptions to confirm**: 10M customers, 20M transfers/day, 2k investigator cases/day; existing rule-based system with a high false-positive rate; labels only exist for investigated alerts.


### Estimates

- **Transfers**: 20M/day ≈ 230/s average, ~1k/s peak — modest for streaming features.
- **Graph**: ~10M customers, ~15M accounts, ~20M devices, ~100M external counterparties; 90 days of transfers ≈ 1.8B edges, aggregated to ~500M weighted edges (per pair per window). PageRank, community detection and label propagation over this run nightly on a Spark/GraphFrames-scale cluster in a couple of hours.
- **Alert budget**: capacity is 2k cases/day. If legacy rules produce ~10k alerts/day at ~3% SAR conversion (~300 SARs), ranking those so the top 2k carry ~12% conversion yields ~240 SARs from a fifth of the work — or more SARs at the same workload. Precision at capacity is the metric.
- **Exploration budget**: reserve ~5% of capacity (~100 cases/day) for below-threshold and novel-pattern samples to measure recall and gather labels.
- **Labels**: ~2k dispositions/day ≈ 700k/year, heavily biased towards what the old rules flagged; confirmed laundering is rare (~a few % of cases).
- **Real-time path**: scoring an outbound payment with cached graph features and live velocity features takes < 50 ms; holds must be rare (target < 0.05% of payments) to avoid customer harm.


### API

```
Stream in:  transfer.created {transfer_id, from_account, to_account | counterparty, amount,
                              currency, channel, device_id, ts}
POST /v1/score/payment   {transfer_id, ...}  → {action: "allow"|"hold"|"alert", score,
                                                typology_scores, reasons[]}   (outbound, real time)
GET  /v1/alerts?queue=…&sort=priority     → [{alert_id, customer_id, priority, typologies[], sla_due}]
GET  /v1/cases/{id}  → {customers, accounts, linked entities graph, transactions, model scores,
                       explanations (top features, typology evidence), history}
POST /v1/cases/{id}/disposition {outcome: "sar"|"no_further_action"|"exit"|"rfi",
                                 typology, reason_code, notes, investigator}
POST /v1/models/{id}/shadow {start, end}   (governance-controlled)
```
Dispositions are append-only and versioned; corrections create a new label version rather than overwriting history.


### Data model

- **Entity graph**: Customer, Account, Device, Counterparty, Address nodes; edges for ownership, shared device or address, and transfers (aggregated per window with count, sum, first/last seen).
- **Transfer**: id, parties, amount, currency, channel, device, timestamp, payment scheme.
- **FeatureSnapshot**: entity, as-of date, transaction aggregates, velocity, network features (PageRank, community id and size, distance to known mules, label-propagation score).
- **Alert**: id, entity, model and rule versions, score, typology scores, explanations, created_at, status.
- **Case**: grouping of alerts by customer or network, investigator, SLA dates, outcome.
- **Label** (versioned, auditable): case or entity, outcome, typology, source (investigator, QA second review, law-enforcement feedback, account closure), quality score (e.g. agreement on double review), label version.
- **ModelRecord**: version, training data snapshot, validation report, approvals, shadow results, monitoring thresholds.


### Architecture

```
Core banking + payments ─► Kafka ─┬─► real-time path (outbound payments):
                                  │     live velocity + cached graph features
                                  │     ─► payment model ─► allow | hold | alert
                                  └─► lake ─► nightly batch:
   Graph build (customers, accounts, devices, counterparties) ─► network features
   (PageRank, communities, label propagation from confirmed mules)
   ─► Models: transaction-level, customer-level, typology detectors
      (structuring, mule networks, pass-through)  +  legacy rules
   ─► Alert prioritisation (calibrated risk × severity) ─► cases (by network)
   ─► Investigator UI: explanations, timeline, graph view, evidence export
   ─► Dispositions ─► Label platform (versioned, quality-scored)
   ─► Active learning sampler + retraining ─► shadow mode ─► approval ─► live
Governance: model inventory, validation, model-risk documentation, audit log
```


### Deep dives

**Labels are biased and noisy.** Only alerted customers get labels, investigators differ, and "no SAR" does not mean innocent. Hence the label platform: versioned outcomes, reason codes, quality scores from double-reviewed samples, and weighting of labels by quality. Active learning spends part of capacity on uncertain and below-threshold cases, giving labels outside the old rules' blind spots and an estimate of recall.

**Mule networks need the graph.** A single mule account looks like a student receiving transfers; the network shows fan-in from many unrelated senders, rapid fan-out to crypto exchanges, shared devices and new accounts. Graph features fed to a GBDT give most of the lift and stay explainable; GNNs can be a challenger in shadow.

**Shadow mode before replacing anything.** A new model runs beside the incumbent for weeks, producing would-be alerts; investigators review a blind sample of alerts that only the new model raises. Promotion needs higher precision at capacity, no typology losing recall, and model-risk sign-off.


### Trade-offs

- **Recall vs investigator workload**: lower thresholds find more laundering but bury investigators; optimise precision at the fixed capacity, and argue for more capacity with evidence of what is being missed.
- **Explainability vs model power (GNNs)**: GNNs can capture subtle network structure but are hard to explain to investigators and regulators; prefer engineered graph features with a GBDT and attribution, and use a GNN to propose features or as a shadow challenger.
- **Per-typology models vs one model**: typology detectors are interpretable and map to how investigators work and how SARs are written; one model ranks better overall. Use per-typology scores as inputs and explanations, and one prioritisation model on top.
- **Latency (real-time blocking vs batch monitoring)**: real-time holds stop money leaving but harm customers when wrong and must be rare and fast to resolve; most typologies need days of behaviour, so batch is the right default.


### Evaluation

- **Offline**: precision@capacity (top-k per day against later dispositions), recall on confirmed cases (including those found by other routes, such as law-enforcement requests), per-typology precision and its drift, calibration of risk scores; time-based splits only.
- **Online**: SAR conversion rate of alerts, time from first suspicious activity to alert, investigator hours per confirmed case, backlog age vs SLA, real-time hold rate and false-hold rate.
- **Label-drift monitoring**: shifts in disposition mix per typology, investigator agreement on double-reviewed samples, changes in label sources; retraining paused if label quality drops.
- **Governance**: shadow results, validation reports and approvals stored per model; periodic independent review; fairness checks on alert rates across customer segments, avoiding protected characteristics and proxies.


## What a strong design shows

- Optimises precision at investigator capacity and reserves budget for exploration to estimate recall.
- Uses a shared entity graph with network features to catch mule networks, while keeping explanations investigators can use.
- Treats labels as a versioned, quality-scored platform, aware of selection bias and investigator noise.
- Ships new models through shadow mode, validation and model-risk governance.
- Distinguishes batch monitoring from rare, fast real-time holds, grounded in UK rules and filing timelines.

---

*Study material compiled with AI: drafted by a local model (Inkling 2 Mini) from public sources, then checked against those sources by independent AI reviewers (Claude) in November 2026. Not reviewed line by line by a person.*
