Statement
medium
Masking PII in a response
`redact_pii(text)` masks emails and phone numbers in a model response:
- email → `[email]`;
- phone → `[phone]`;
- the rest of the text is unchanged.
Write tests: email, phone, both at once, safe text. Check that exactly the right
things are masked and nothing extra is touched.
AI mentor
The AI mentor is available after you log in: it sees your attempt history and does not spend resources on anonymous requests.
Log in and ask
Hints
1 of 3 unlocked · attempts: 0
Hint 1
What exactly counts as PII in this filter? Start with one email and one phone
number.
Hint 2 — unlocks after 1 attempt
Hint 3 — unlocks after 3 attempts