A small medical fine-tune leaks verbatim credit-card snippets under red-teaming: identify the failure mode and the standard mitigation
Same topic, related formats. Practice these next.
Same topic, related formats. Practice these next.
A red-teamer probes a 7B medical assistant that was fine-tuned on roughly 8,000 internal records. With targeted prompts ("continue this clinical note...") the model emits verbatim credit-card numbers, names, and dates of birth drawn from the training set. Name the failure mode, explain why it shows up so cleanly on a small dataset, and lay out the standard mitigation stack a serious team would deploy before the next training run.
Training-data memorization: small dataset gives each example outsized gradient influence, so rare PII gets memorized; fix with PII scrub, fewer epochs, lower LR, optional DP-SGD, and a red-team gate.
Imagine teaching someone a song by playing it only ten times instead of a thousand times. The few repetitions land hard, and the student remembers the exact wording of the choruses verbatim, including the strange lyrics they would normally forget. Now imagine one of those choruses contains a real credit-card number that someone slipped in. The student can recite it back when prompted with the opening line. The cure is not to make the student smarter; it is to clean the songbook before practice begins, sing each song fewer times, sing more softly, and have a friend probe the student afterward to check they have not memorised anything sensitive. The model behaves the same way. Small data plus many passes equals verbatim recall of whatever you forgot to scrub.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example.
Everything important, quickly.
7 min: name memorisation as the mode, explain small-dataset amplification of per-example influence, prescribe the four-layer stack (PII scrub + dedup, conservative hyperparameters, DP-SGD when needed, extraction red-team gate), and call out RAG as an alternative architecture.
Real products, models, and research that use this idea.
What an interviewer would ask next. Try answering before peeking at the approach.
Red flags and common mistakes that signal junior thinking. Click to expand.
Blaming the model architecture and proposing 'add a safety filter at inference'. The leak originates in training and any inference-time filter is a band-aid; the real fix is upstream of training.
The night-before-the-interview bullets. Scan these on the way to the call.
Primary sources. Skim if you want the original framing.