Sub topic 14
Worked examples: simple detection rules for structuring and pass-through activity
This chapter assumes you know how cash deposits, wire transfers, and account statements work. It also assumes you have read the earlier chapters on placement, layering, and the controls that monitor them. You need basic Python (functions, loops, tuples) to follow the code.
Why start with simple rules
Transaction monitoring systems often begin as rules: fixed conditions that an analyst can read and explain. A rule turns a red flag from the earlier chapters into a test on data. Rules are easy to audit and to justify to a regulator. They are also blunt, so every rule below needs tuning against real customer behavior.
Each rule maps to one stage.
| Stage | Red flag | Rule in this chapter |
|---|---|---|
| Placement | Several cash deposits just under a reporting threshold | Structuring check |
| Layering | Money received and sent on almost unchanged | Pass-through check |
Rule 1: structuring at the placement stage
Structuring means splitting cash deposits into amounts below a reporting threshold to avoid a report. The rule looks for deposits in a band just under the threshold (here 80% to 100% of it), then checks whether enough of them fall inside a short window.
from datetime import date, timedelta
REPORTING_THRESHOLD = 10_000 # example cash reporting threshold
def looks_like_structuring(deposits, window_days=3, near_ratio=0.8, min_count=3):
"""Return True if several cash deposits just under the threshold
occur within a short window.
deposits: list of (date, amount) tuples for one account.
"""
lower = near_ratio * REPORTING_THRESHOLD
near = sorted((d, a) for d, a in deposits if lower <= a < REPORTING_THRESHOLD)
for i, (start, _) in enumerate(near):
count = sum(1 for d, _ in near[i:] if d - start <= timedelta(days=window_days))
if count >= min_count:
return True
return False
deposits = [
(date(2026, 3, 2), 9_500),
(date(2026, 3, 3), 9_200),
(date(2026, 3, 4), 9_800),
(date(2026, 3, 20), 1_200),
]
print(looks_like_structuring(deposits)) # TrueThe three deposits of 9,500, 9,200, and 9,800 fall within two days and all sit between 8,000 and 10,000. The 1,200 deposit is ignored because it is far below the band.
Rule 2: pass-through activity at the layering stage
A pass-through account receives a large amount and sends almost all of it onward, which suggests a conduit instead of normal business use.
def is_pass_through(total_in, total_out, min_in=50_000, out_ratio=0.9):
"""Flag an account that receives a large amount and sends almost all of it
onward within the same review period, a common layering pattern.
"""
if total_in < min_in:
return False
return total_out / total_in >= out_ratio
print(is_pass_through(total_in=120_000, total_out=117_500)) # True
print(is_pass_through(total_in=120_000, total_out=40_000)) # FalseThe first account sends on about 98% of what it received. The second sends on about 33%, which looks like ordinary spending or saving. The min_in guard prevents small accounts from generating noise.
Common errors
- Exact-threshold thinking. Checking only for amounts equal to the threshold misses structuring. The band approach catches amounts that are near it.
- Single-account view. The structuring rule sees one account. Launderers also spread deposits across accounts and branches, so real systems group by customer or related parties.
- Fixed parameters. A payroll processor or a payment platform passes most funds through legitimately. Without segment-specific thresholds, the pass-through rule produces many false positives.
- Window cost. The nested loop is fine for a few records. For large volumes, use a sliding window over sorted data.
- Alert is not proof. A match only prompts review. The suspicion decision belongs to an analyst, who documents the reasoning.
Exercise
An account receives 80,000 over a month and sends out 70,000 in the same month. With the default parameters, does ispassthrough flag it? What single change to out_ratio would make it flag?
Show answer
No. The ratio is 70,000 / 80,000 = 0.875, which is below 0.9. Setting out_ratio to 0.85 or lower would flag it, but that also increases false positives for legitimate accounts.
Exercise
Why does lookslikestructuring ignore a deposit of exactly 10,000?
Show answer
The band uses the condition lower <= a < REPORTING_THRESHOLD, so 10,000 is excluded. A deposit at the threshold would already trigger the normal threshold report, so the rule targets amounts that stay just below it.