Preprocessing conversations to protect privacy before fine-tuning
Privacy-preserving data pipelines for training.
Detect and redact PII with NER plus regex, choose redaction versus pseudonymization, and validate recall.
WHAT THIS TESTS Whether you understand that conversational data is dense with sensitive information and that scrubbing requires layered detection plus a validation loop, not a one-shot filter.
A GOOD ANSWER COVERS Start with categorization. Direct identifiers include full names, email addresses, phone numbers, postal addresses, government IDs such as SSN or passport numbers, payment card and bank account numbers, IP and MAC addresses, device and account IDs, dates of birth, and health, financial, or biometric data. Quasi-identifiers such as employer plus city plus age can re-identify someone in combination, so they matter too. For detection, layer techniques: regex with checksum validators for structured items like cards and SSNs, and a trained NER model for names, locations, and organizations that regex misses. Decide a strategy per type: irreversible redaction with placeholder tokens, or consistent pseudonymization that maps a person to a stable surrogate so conversational coherence survives. Add minimization by dropping unneeded fields and deduplicating. Finally measure detection recall on a hand-labeled holdout, because a missed identifier can be memorized and regurgitated.
COMMON WRONG ANSWERS Listing only emails and phone numbers. Assuming a single regex catches everything. Ignoring quasi-identifiers and contextual leakage. Forgetting that the model can memorize and reproduce rare strings, so high recall matters more than precision here.
LIKELY FOLLOW-UPS How do you handle false negatives that leak into training? Redaction versus pseudonymization tradeoffs for downstream utility? How does differential privacy or deduplication complement scrubbing? How do you handle PII embedded mid-sentence?
ONE CONCRETE EXAMPLE A support log reads, contact me at jane.doe@acme.com or 555-0100, card 4111 1111 1111 1111. The pipeline runs Luhn-validated card regex, an email and phone regex, and an NER pass that tags Jane Doe as a person. It rewrites the line with stable surrogates so any later mention of Jane maps to the same token. You then audit a labeled sample to confirm recall above a target threshold before training.
Read the original → arxiv.org
Get five bites like this every day.
Tezvyn delivers a daily feed of 60-second tech bites with quizzes to lock in what you learn.