Which Amazon Comprehend filtering design meets privacy and latency requirements?
Short answer
D Run Amazon Comprehend toxicity detection, prompt safety classification, and PII redaction in parallel before the Bedrock FM so all filters finish first.
Question
The company wants to use Amazon Comprehend to implement layered content filtering. The layered content filtering must prevent sharing of offensive content, protect customer privacy, and detect potential inappropriate advice solicitation. Inappropriate advice solicitation includes requests for unethical practices, harmful activities, or manipulative behaviors. The solution must maintain acceptable overall response times, so all pre-processing filters must finish before the content reaches the FM.
Which solution will meet these requirements?
Key Takeaways
The question tests Amazon Comprehend's layered moderation capabilities and latency trade-off; the trap is choosing parallel latency in option A while ignoring that PII detection without redaction does not protect customer privacy.
Amazon Comprehend layered content filtering for a Bedrock-powered assistant requires toxicity detection, prompt safety classification, and PII redaction to run before inference. This page establishes why option D satisfies all three checks with parallel pre-processing while option A leaves PII unredacted.
Common mistake: The most common wrong answer is A: it runs the Comprehend filters in parallel, but PII detection without redaction still lets sensitive customer data reach the Bedrock FM, so the privacy requirement is not met.
Expert Analysis
Why the Answer Is Correct
Option D is the only choice that combines the three Amazon Comprehend capabilities the scenario requires: toxicity detection for offensive content, prompt safety classification for inappropriate advice solicitation, and PII detection with entity redaction for customer privacy. Running the independent checks in parallel is the right latency pattern because the requirement says every pre-processing filter must finish before the draft request reaches the Bedrock FM. Redaction is essential: merely detecting PII does not stop sensitive data from being included in the FM prompt. The 0.5 toxicity threshold is a tuning detail, not a disqualifier in a question that does not specify per-category thresholds, and CloudWatch alarms add useful visibility into filter behavior.
Why the Other Options Are Wrong
Option A has the right parallel latency idea and covers toxicity and prompt safety, but its PII detection is without redaction, so customer data can still reach the FM and the privacy requirement fails. Option B misuses Comprehend custom classification as if it could build an FM and gates PII detection behind the custom classifier, so not every message receives the privacy filter and the design is not a clean layered pre-processing pipeline. Option C is the serial version: prompt safety, then toxicity, then PII in streaming mode adds cumulative latency and EventBridge human review without clearly redacting PII before inference. Option D's fixed 0.5 threshold is less flexible than a tuned threshold, but it still supplies all three filters plus redaction and parallel execution.
Community Comment Notes
The comments show the main split in the thread. Naaser supports A for "Lowest Latency" and complete coverage, but OlaFemi points out the fatal gap: "a redaction is needed" for PII, which A omits. Chibuzo1 backs D because it pairs toxicity, prompt safety, and PII with redaction and parallel execution, while mosun and jyrajan69 object to D's fixed 0.5 threshold; that is a tuning concern, not a failure of the privacy requirement. dbcert87 argues that "layered filtering which rules our parellel processing" favors C, but the latency requirement and the need to finish all filters before the Bedrock FM make the parallel design more defensible. The comments are useful for spotting the redaction trap, but the exam's decisive criterion is complete pre-processing with PII protection.
Official Reference
- https://docs.aws.amazon.com/comprehend/latest/APIReference/API_DetectToxicContent.html
- https://docs.aws.amazon.com/comprehend/latest/APIReference/API_DetectPiiEntities.html
- https://docs.aws.amazon.com/comprehend/latest/dg/how-pii.html
These links open the official vendor documentation in a new tab.
Exam Strategy
Read the privacy requirement as a binary control: detecting PII is not the same as preventing it from reaching the Bedrock FM. When the question says all filters must finish before inference, prefer parallel independent checks that include redaction, and treat fixed thresholds as secondary tuning details.
Frequently Asked Questions
Why is PII detection without redaction insufficient in option A?
Does layered content filtering require sequential Comprehend calls?
Discussion 7 contributions
Compiled from public community threads and reader submissions, lightly edited for clarity. Handles and vote tallies are shown as recorded, and comments reflect the views of individual contributors.
From public community threads 7
-
Naaser 👍 3 Answered ALowest Latency: Using parallel processing with asynchronous API calls ensures that all three Amazon Comprehend filters (Toxicity, Prompt Safety, and PII) run simultaneously. This prevents cumulative "sequential" latency, meeting the requirement for acceptable response times.Complete Coverage:Toxicity Detection: Directly addresses the requirement to filter offensive content.Prompt Safety Classification: Specifically designed to detect inappropriate advice solicitation (unethical, harmful, or manipulative requests).PII Detection: Protects customer privacy by identifying sensitive data before it reaches the foundation model.
-
Chibuzo1 👍 2 Answered DThe answer is D because it correctly pairs all three required Comprehend capabilities with the right configurations — toxicity detection with a calibrated threshold, prompt safety classification, and PII detection with entity redaction — running in parallel to minimize pre-processing latency, ensuring all filters complete before the FM receives any content, and maintaining operational visibility through CloudWatch alarms.
-
OlaFemi 👍 2 Answered DA is not correct, it says Use personally identifiable information (PII) detection without redaction. and a redaction is needed
-
dbcert87 👍 1 Answered C1/ Question asked layered filtering which rules our parellel processing 2/ Hard coding .5 for all categories is not sage and AWS best practice 3/Sequential filtering is best if complete before inference.
-
jyrajan69 👍 1 Answered AOption D is not the right answer as it required hard coding the 0.5 as toxicity thresh hold, better option is A
Show 2 more comments
-
mosun 👍 1 Answered AAnswer is A, because option D has fixed value - 0.5 for all categories
-
de1612d 👍 1 Answered DAnswer is D
Reader comments & corrections
No reader corrections yet — spotted an error or have a note? Share it below.
Related Analysis
Practice All AIP-C01 Questions
Access 110 questions with complete answers and detailed explanations.
View Full AIP-C01 Practice Test →