AIP-C01 · LESSON 3
AI Safety, Security, and Governance20% · 4 topics
Learn input and output safety controls, data security and privacy, AI governance and compliance, and implementing responsible AI principles.
3.1Input and output safety controls
3.1 Implement input and output safety controls.
Concept
Bedrock Guardrails apply content filters (hate, insults, sexual, violence, misconduct, prompt attacks), denied topics, word filters, sensitive information filters (blocking and masking PII), contextual grounding checks (detecting hallucinations by checking grounding and relevance) and Automated Reasoning checks (rule-based logical verification) to input and output. They can also be used independently of model invocation via the ApplyGuardrail API.
How it works / steps
- Decide the needed filters and strengths from the use case's risks
- Detect jailbreaks and injection with the prompt attack filter
- Define denied topics (such as investment advice)
- In RAG, stop ungrounded answers with grounding checks
- Apply guardrails to input and output of non-Bedrock models with ApplyGuardrail
Workplace example
In an insurance consultation chat, set individual investment advice as a denied topic, and block answers with grounding checks when they stray from the knowledge base sources.
Common confusions and exam tips
- Apply the prompt attack filter to input
- Grounding checks require RAG sources (reference documents)
- Automated Reasoning checks formalize rules and verify logically (not a probabilistic judgment)
Mini quiz
Q1. You want to verify that answers to HR policy questions do not logically contradict the policy rules. Which feature is most appropriate?
- Limit answers to a short length so there is no room for contradictions
- Lower the temperature to mathematically guarantee answers never contradict the policy rules
- Use Guardrails Automated Reasoning checks to verify answers against a policy built from the rules
- Set content filter strength to maximum to stop answers that contradict the policy
Show answer and explanation
Answer: C Use Guardrails Automated Reasoning checks to verify answers against a policy built from the rules
Automated Reasoning checks formally verify answer correctness using a logical policy built from documents.
Q2. You want to keep competitors' product names and words your company does not use out of answers. Which setting is most appropriate?
- Register each product name letter by letter as separate denied topics
- Register a list of words to block in the guardrail word filter
- Set the hate category of the content filter to maximum to block the words
- List the product names in the system prompt so the model memorizes them
Show answer and explanation
Answer: B Register a list of words to block in the guardrail word filter
The word filter blocks inputs and outputs containing specified words or profanity.
Reference links
3.2Data security and privacy controls
3.2 Implement data security and privacy controls.
Concept
In Bedrock, prompts and responses are not shared with model providers and are not used to train foundation models. Customers protect data with encryption using KMS customer managed keys (custom models, knowledge bases, agents), VPC endpoints, restricting model use with IAM condition keys, detecting sensitive information in training data with Macie, and masking PII with guardrails.
How it works / steps
- Classify data and decide which models and Regions may handle it
- Limit usable models with IAM policies
- Encrypt stored data with customer managed keys
- Call through VPC endpoints without going over the internet
- Detect and mask PII and keep it out of logs too
Workplace example
For summaries of customer inquiries, mask phone numbers and email addresses with guardrails, and encrypt custom models and knowledge bases with customer managed keys.
Common confusions and exam tips
- Model invocation logs keep prompt content. Encrypt the destination and control access
- With cross-Region inference, check data residency requirements
- Macie discovers data in S3; it does not inspect prompts in real time
Mini quiz
Q1. Before embedding chat text, you want to detect and remove personal information in real time. Which service is most appropriate?
- AWS Glue crawler
- Amazon Rekognition image label detection
- Amazon Comprehend PII detection
- Amazon Polly speech synthesis
Show answer and explanation
Answer: C Amazon Comprehend PII detection
Amazon Comprehend detects the type and location of PII in text.
Q2. Which statement about data protection and governance for generative AI is incorrect?
- An interface VPC endpoint lets you call Bedrock without going over the internet
- A KMS customer managed key can encrypt custom models
- CloudTrail can record Bedrock API operations
- Prompts sent to Bedrock are shared with model providers by default and used for training
Show answer and explanation
Answer: D Prompts sent to Bedrock are shared with model providers by default and used for training
Bedrock does not share prompts or responses with model providers and does not use them to train foundation models.
Reference links
3.3AI governance and compliance mechanisms
3.3 Implement AI governance and compliance mechanisms.
Concept
Governance mechanisms include model invocation logging (recording prompts and responses to S3 or CloudWatch Logs), CloudTrail (recording API operations), controlling usable models with SCPs and IAM, tags and cost allocation, version and approval management for models and prompts, and documentation (such as Model Cards).
How it works / steps
- Enable model invocation logging and decide the retention period
- Allow only models approved by the organization with SCPs
- Manage prompt and model versions and record change approvals
- Make usage and cost visible per department with tags
- Audit regularly and confirm regulatory requirements are met
Workplace example
To meet audit requirements, keep model invocation logs in encrypted S3 for one year, and deny InvokeModel for unapproved models with an SCP.
Common confusions and exam tips
- Invocation logging is disabled by default. Enable it explicitly
- CloudTrail records API operations and does not include prompt content
- Governance includes approval processes, not just technology
Mini quiz
Q1. You want to prevent every account in the organization from calling any model other than approved ones. Which method is most appropriate?
- Check invocation logs once a month and warn violators
- Ask in the system prompt that unapproved models not be used
- Email users in each account a list of approved models
- Use an AWS Organizations SCP to deny calls to models other than approved ones
Show answer and explanation
Answer: D Use an AWS Organizations SCP to deny calls to models other than approved ones
An SCP sets the maximum permissions available across all accounts in an organization. You can deny with conditions on the model ARN.
Q2. You want every model call to use a specified guardrail, even if a developer forgets to add it. Which method is most appropriate?
- Deny calls without the specified guardrail with the IAM condition key bedrock:GuardrailIdentifier
- Attach the guardrail on every call through a shared SDK wrapper
- Check CloudTrail logs and notify about calls without guardrails
- Share the guardrail ID with all teams and document how to attach it
Show answer and explanation
Answer: A Deny calls without the specified guardrail with the IAM condition key bedrock:GuardrailIdentifier
With the IAM condition key bedrock:GuardrailIdentifier, you can allow only inference that uses a specific guardrail. [Other options] Direct calls that skip the wrapper aren't stopped. CloudTrail checks detect after the fact. Sharing and documentation don't prevent omissions.
Reference links
3.4Implement responsible AI principles
3.4 Implement responsible AI principles.
Concept
Implement the AWS dimensions of responsible AI (fairness, explainability, privacy and security, safety, controllability, veracity and robustness, governance, transparency) through evaluation (bias and harmfulness testing), guardrails, human review, disclosure to users and continuous monitoring.
How it works / steps
- Identify the use case's risks and the people affected
- Evaluate quality differences across attributes and harmful outputs
- Mitigate risks with guardrails and human review
- Disclose AI use and its limitations to users
- Monitor production complaints and feedback and improve
Workplace example
For summaries of job application documents, evaluate whether summary quality changes with applicant attributes, and state clearly that a person always makes the final decision.
Common confusions and exam tips
- Responsible AI is not a one-time effort; it continues across the whole lifecycle
- Do not leave high-risk decisions to AI alone
- Transparency includes indicating that content is AI-generated
Mini quiz
Q1. You want to increase transparency in a chat for external customers. Which response is most appropriate?
- Indicate that answers are AI-generated, and show source documents and how to switch to a human agent
- Make switching to a human agent impossible and handle everything with AI only
- Treat answer sources as internal secrets and never show them to users even when citable documents exist
- Hide that AI is answering and make it look as if a human agent is responding
Show answer and explanation
Answer: A Indicate that answers are AI-generated, and show source documents and how to switch to a human agent
For transparency, show that it is AI, show the basis, and leave a path to consult a human.
Q2. For an assistant that summarizes job application documents, you want to check whether summaries change based on applicants' gender or age. Which method is most appropriate?
- Compare outputs on input pairs that differ only in attributes, and keep tracking the gap as a metric
- Remove gender and age columns before summarizing, and evaluate before launch
- Have developers compare sample résumés and call it fair if no bias appears
- Register discriminatory expressions as guardrail denied topics
Show answer and explanation
Answer: A Compare outputs on input pairs that differ only in attributes, and keep tracking the gap as a metric
Comparing outputs for input pairs that differ only in attributes makes bias easier to find. Evaluate continuously. [Other options] Removed attributes can still be inferred from names, and there's no ongoing evaluation. Guardrails stop harmful content but don't measure summary differences. A few manual reads aren't reproducible.
Reference links
Lessons are written by this site based on public information and do not guarantee exam content. Product specifications change, so check the latest information at the reference links.
Notes (unofficial, original questions, no pass guarantee)
- The questions on this site are original practice questions written by this site based on publicly available skills outlines and exam guides. They are not actual exam questions.
- Amazon Web Services, AWS and related marks are trademarks of Amazon.com, Inc. or its affiliates. This site is not affiliated with or endorsed by AWS.
- This content is a study aid and does not guarantee a pass. Exam content, format and prerequisites may change without notice; always check the latest information on the official page before taking the exam.
- Your accuracy on the mock exam cannot be converted to the official (scaled) score and does not predict a pass or fail.
- Progress is saved only in this browser (localStorage) unless you sign in with Google to sync it. You can delete it from the Cookie & storage settings page (Japanese).