179 questions
No questions match those filters.
How do you prevent sensitive data from leaking through...
This is one of the questions in the full AI/ML interview bank. Pro unlocks all 1789 questions; Premium includes the same bank plus the highest daily Practice limit.
See plansSensitive data can leak at either end of a request — a user can phrase a query to extract data they shouldn’t have, or a model can surface something sensitive in its answer even from an innocent-looking prompt — so the defense has to cover both directions rather than just one. On the input side, scan queries for patterns that look like an attempt to pull out restricted information before the request ever reaches the model.
On the context side, mask sensitive fields like account numbers or identifiers in whatever documents get retrieved and fed to the model, so the model itself never sees the raw sensitive value in the first place. And on the output side, run a regex-plus-classifier check on whatever the model generates before it goes back to the user, catching anything that slipped through despite the earlier filters. Every interaction should also be logged, since the audit trail is what lets you investigate a near-miss later even when the live filters caught it.
A bank chatbot asked to list its highest-loan customers by name is the clean example: with input filtering in place, that query gets blocked outright as a privacy violation and the bot declines rather than dutifully answering. Tools like Microsoft Presidio for detecting PII and Guardrails AI for validating output are the standard building blocks for this kind of layered defense.