View Full Amazon AWS Certified Generative AI Developer – Professional AIP-C01 Exam Dumps and Practice Test Dumps
Question 341
A company wants to provide an AI assistant with access to customer-order information without allowing the foundation model to directly access the database. Which architecture is most appropriate?
- Expose the database password in the prompt
- Give the model administrator permissions
- Provide a controlled backend tool that retrieves authorized order data
- Place the entire database in the model context
Correct Answer: 3
Explanation
A controlled backend tool separates model reasoning from sensitive data access. The model can request specific order information through a defined interface, while the backend validates the request, verifies the user’s authorization, queries the database, and returns only permitted data. This architecture prevents the model from directly receiving database credentials or unrestricted database access. Tool inputs and outputs should also be validated and logged appropriately. Least-privilege permissions and authorization checks should remain enforced by trusted application infrastructure rather than relying solely on model instructions.
Question 342
A developer notices that a retrieval system returns many semantically similar passages that contain nearly identical information. Which improvement can reduce redundant context?
- Increase the temperature
- Apply diversity-aware retrieval or deduplication
- Increase the output token limit
- Disable metadata
Correct Answer: 2
Explanation
Retrieval systems can sometimes return several passages containing substantially overlapping information. Deduplication or diversity-aware retrieval can reduce redundant context and leave more room for distinct evidence. This can decrease token consumption and help the model focus on complementary information. Developers can compare similarity scores, document identifiers, metadata, or content overlap when determining whether results are duplicates. Simply increasing the context size may increase cost without improving answer quality. Retrieval optimization should be evaluated against representative questions to ensure that important evidence is not accidentally removed.
Question 343
An AI application stores sensitive prompts and generated responses for troubleshooting. Which practice provides the strongest protection against unnecessary exposure?
- Log everything indefinitely
- Store sensitive information in plaintext
- Apply appropriate redaction, access controls, encryption, and retention policies
- Give every developer unrestricted access
Correct Answer: 3
Explanation
AI logs can contain sensitive prompts, personal information, proprietary content, or model outputs. Developers should minimize what is logged and apply redaction where appropriate before storing sensitive information. Encryption, strict access controls, and defined retention periods further reduce exposure. Logging everything indefinitely increases privacy and compliance risks, while unrestricted developer access violates least-privilege principles. Organizations should establish clear logging policies that balance troubleshooting needs with data protection requirements and ensure that sensitive information is not unnecessarily propagated into monitoring systems.
Question 344
A company wants to process messages from an AI application’s event queue even when one message repeatedly fails. Which design prevents the failed message from blocking normal processing?
- Store failed messages in a dead-letter queue
- Increase the model temperature
- Delete all failed messages
- Disable retries
Correct Answer: 1
Explanation
A dead-letter queue can isolate messages that repeatedly fail processing after the configured retry policy is exhausted. This prevents a persistent poison message from continually interfering with normal workload processing. Developers can later inspect the failed message, determine the root cause, and replay it after correcting the problem when appropriate. Disabling retries can cause transient failures to become permanent, while deleting failed messages can result in data loss. Dead-letter handling should be combined with monitoring and alerting so that accumulated failures are investigated promptly.
Question 345
A developer wants an AI service to reject requests that exceed an approved input size before they reach the model. Which control is most appropriate?
- Input validation
- Increasing model temperature
- Larger vector dimensions
- Disabling API authentication
Correct Answer: 1
Explanation
Input validation allows an application to check request properties before invoking downstream services. The application can enforce maximum text length, permitted formats, required fields, and other constraints. Rejecting oversized requests early can protect model capacity, reduce unnecessary costs, and prevent malformed input from propagating through the system. Input validation should be implemented in trusted application infrastructure rather than relying on the foundation model to enforce limits. Authentication, authorization, and rate limiting should also be applied according to the application’s security requirements.
Question 346
An organization wants to determine whether retrieved passages are actually useful for answering user questions before the generation step. Which evaluation measure is most relevant?
- Retrieval relevance
- Network bandwidth
- S3 object count
- API hostname length
Correct Answer: 1
Explanation
Retrieval relevance measures how well retrieved documents or passages match the information needed to answer a query. Evaluating retrieval separately from generation helps developers determine whether poor responses originate from the retrieval layer or the model. Metrics such as precision, recall, ranking quality, or task-specific relevance judgments can be used depending on the evaluation design. If retrieval quality is poor, developers can investigate chunking, embeddings, metadata filters, indexing, query transformation, or reranking. Generation changes alone may not resolve a fundamentally weak retrieval pipeline.
Question 347
A developer is designing an agent that can call a payment service. Which additional control is most important before allowing the tool to execute financial transactions?
- Human approval or strong authorization controls
- Higher temperature
- Unlimited tool iterations
- Larger prompts
Correct Answer: 1
Explanation
Financial actions can have significant consequences, so the agent should not rely solely on its own reasoning to authorize transactions. Strong authorization controls should verify the user’s identity, permissions, transaction parameters, and applicable limits. Depending on risk, human approval may also be required before execution. Tool schemas should validate required fields, and the payment operation should use idempotency controls to prevent duplicate charges. These controls create trusted boundaries around the model and reduce the impact of hallucinations, prompt injection, or unintended agent behavior.
Question 348
A RAG application needs to identify exactly which source documents contributed to an answer. Which design feature is most useful?
- Preserve source metadata through retrieval and generation
- Remove document identifiers
- Randomize retrieved documents
- Store only generated text
Correct Answer: 1
Explanation
Preserving source metadata allows an application to associate retrieved passages with their originating documents. Metadata can include document identifiers, titles, URLs, timestamps, version information, or other provenance details. The application can then expose citations or source references alongside the generated answer when appropriate. Removing identifiers makes troubleshooting and verification harder. Provenance is particularly useful for enterprise applications where users need to validate claims or where organizations need to audit the source of generated information. Source tracking should remain consistent throughout ingestion, indexing, retrieval, and response generation.
Question 349
A company wants to ensure that only approved application components can invoke a sensitive internal AI service. Which security mechanism should be prioritized?
- Authentication and authorization
- Higher top-p values
- More retrieved documents
- Longer prompts
Correct Answer: 1
Explanation
Authentication verifies the identity of the calling application or user, while authorization determines whether that identity has permission to perform the requested operation. Together, these controls prevent unauthorized components from accessing sensitive AI services. AWS IAM roles and policies can provide identity-based authorization for many AWS resources, while API-level authentication mechanisms may be appropriate for application interfaces. Model parameters such as temperature and top-p do not provide security boundaries. Access should follow least-privilege principles and be supported by monitoring and audit logging.
Question 350
A developer changes the chunk size in a RAG ingestion pipeline. Which consequence should be evaluated carefully?
- Retrieval quality and context efficiency
- CloudTrail username formatting
- KMS key alias length
- DNS record propagation only
Correct Answer: 1
Explanation
Chunk size affects how information is represented and retrieved from a knowledge base. Very small chunks may lose useful context, while very large chunks can contain irrelevant information and consume more model context. Changing chunk boundaries can therefore affect retrieval precision, recall, grounding quality, latency, and cost. Developers should evaluate the modified configuration against representative queries rather than assuming a particular chunk size is universally optimal. Metadata, overlap, document structure, and embedding behavior should also be considered when optimizing a RAG ingestion pipeline.
Question 351
A company wants to detect unexpected changes to infrastructure used by its generative AI application. Which practice is most appropriate?
- Infrastructure drift detection
- Increasing model temperature
- Removing deployment logs
- Increasing vector dimensions
Correct Answer: 1
Explanation
Infrastructure drift occurs when deployed resources differ from the configuration defined in the organization’s infrastructure-as-code or approved configuration. Drift detection helps identify unauthorized or unexpected changes to resources such as IAM policies, networking components, APIs, or compute infrastructure. Detecting drift is important for security, reliability, and repeatable deployments. Developers can investigate the difference and either reconcile the infrastructure with the intended configuration or formally update the infrastructure definition. Model parameters and vector dimensions do not provide infrastructure configuration control.
Question 352
An AI application must perform a long-running document-processing workflow that may include several asynchronous tasks. Which architecture is most appropriate for coordinating these steps?
- A single synchronous API request with no timeout handling
- A workflow orchestration service
- One large model prompt containing every document
- Manual execution by operators
Correct Answer: 2
Explanation
A workflow orchestration service can coordinate multiple tasks, track execution state, handle retries, manage failures, and support asynchronous processing. AWS Step Functions is designed for orchestrating distributed application workflows and can coordinate services such as Lambda and other AWS components. This is preferable to forcing a long-running process into one synchronous API request, which may encounter timeout and reliability issues. Orchestration also provides clearer visibility into individual processing stages and allows developers to implement controlled error handling and recovery paths.
Question 353
A developer needs to ensure that a model-generated SQL statement cannot modify production data. Which approach is strongest?
- Rely only on a prompt saying “read only”
- Use a database identity with read-only permissions
- Increase the model size
- Increase the number of examples
Correct Answer: 2
Explanation
A database identity with read-only permissions provides an authoritative security boundary outside the model. Even if the model generates an unintended UPDATE or DELETE statement, the database authorization layer can reject the operation. Prompt instructions can help guide model behavior but should never be the only protection for high-impact actions. Additional SQL validation and allowlisting can provide defense in depth. Production AI applications should assume that generated content can occasionally be incorrect or maliciously manipulated and should enforce critical security requirements through trusted infrastructure.
Question 354
A developer wants to compare AI application performance before and after an infrastructure change. Which observability practice is most useful?
- Establish baseline metrics and compare them after the change
- Delete historical metrics
- Change multiple unrelated components simultaneously
- Disable logging during deployment
Correct Answer: 1
Explanation
A baseline provides a reference point for evaluating changes in latency, error rates, throughput, token usage, resource utilization, and other operational metrics. Developers can compare measurements before and after an infrastructure change to determine whether performance improved or degraded. Changing many unrelated components simultaneously makes attribution more difficult. Historical telemetry should therefore be retained according to appropriate policies, and monitoring should remain active during deployments. Baseline comparisons are particularly useful for AI applications because model, retrieval, infrastructure, and traffic changes can all influence observed performance.
Question 355
An AI application uses a queue between request ingestion and model processing. What is a major benefit of this architecture?
- It can absorb traffic bursts and decouple producers from consumers
- It guarantees that the model never fails
- It eliminates authentication requirements
- It removes the need for monitoring
Correct Answer: 1
Explanation
A queue can decouple request producers from downstream consumers and temporarily absorb traffic spikes. This allows processing capacity to scale independently and reduces the likelihood that sudden bursts will immediately overwhelm model or application resources. Queues can also support retries and dead-letter handling for failed messages. However, a queue does not guarantee that downstream processing will succeed and does not replace authentication, authorization, monitoring, or validation. Developers should design queue consumers with appropriate concurrency, visibility timeouts, retry behavior, and failure handling.
Question 356
A company wants to reduce the amount of irrelevant information sent to a foundation model after retrieval. Which technique is most appropriate?
- Reranking retrieved candidates
- Increasing the number of documents indefinitely
- Removing all metadata
- Increasing temperature
Correct Answer: 1
Explanation
Reranking can evaluate retrieved candidates using a more detailed relevance assessment and place the most useful passages at the top of the context. The application can then provide only the best results to the generation model, reducing irrelevant context and potentially lowering token consumption. Initial vector retrieval can provide a broader candidate set, while reranking refines the final selection. Developers should measure whether reranking improves answer quality enough to justify its additional latency and cost for the application’s workload.
Question 357
A developer wants to prevent a compromised AI workload from accessing unrelated AWS resources. Which IAM principle should be applied?
- Least privilege
- Maximum privilege
- Shared administrator credentials
- Anonymous access
Correct Answer: 1
Explanation
The principle of least privilege means granting a workload only the permissions required to perform its intended functions. For AI applications, this is especially important because models and agent workflows may process untrusted inputs or generate unexpected actions. Restricting IAM roles can limit the potential impact of a compromised application or manipulated agent. Permissions should be narrowly scoped to required resources and operations, and unused access should be removed. Monitoring and periodic permission reviews can further reduce security risk.
Question 358
A team wants to identify whether an AI model is producing unsafe outputs under unusual or malicious inputs. Which evaluation activity is most appropriate?
- Safety and adversarial evaluation
- Testing only average user questions
- Measuring storage capacity
- Checking DNS records
Correct Answer: 1
Explanation
Safety and adversarial evaluation intentionally examines model behavior under challenging, malicious, or unusual inputs. Test cases can target harmful content generation, prompt injection, policy bypass attempts, sensitive-information disclosure, unsafe tool use, and other application-specific risks. Testing only ordinary user questions may miss vulnerabilities that attackers deliberately exploit. Results should be used to improve guardrails, prompts, access controls, tool restrictions, and application logic. Safety testing should be repeated after significant changes to models, prompts, retrieval pipelines, tools, or other security-sensitive components.
Question 359
A company needs to ensure that an AI application can handle a temporary downstream service failure without immediately returning an error to every user. Which pattern is most appropriate?
- Retry with controlled exponential backoff
- Retry continuously without limits
- Increase model temperature
- Remove timeout settings
Correct Answer: 1
Explanation
Controlled retries with exponential backoff can help an application recover from temporary downstream failures while avoiding an immediate failure response. Exponential backoff gradually increases the delay between attempts, reducing pressure on an already struggling dependency. Retry limits should prevent endless execution, and the application should distinguish transient failures from permanent errors. Timeouts and circuit-breaking mechanisms can provide additional protection. Unlimited retries can create cascading failures and increase cost. Retry behavior should therefore be designed around the failure characteristics and service limits of each dependency.
Question 360
A company wants to ensure that an AI application’s production model, prompt, and configuration changes are reviewed before deployment. Which practice best supports this requirement?
- Controlled CI/CD pipeline with automated validation and approval gates
- Allow developers to modify production directly
- Disable version control
- Deploy every change immediately
Correct Answer: 1
Explanation
A controlled CI/CD pipeline can require changes to pass automated tests, security checks, evaluation suites, and approval gates before reaching production. Version control provides traceability for prompts, application code, infrastructure, and configuration, while deployment controls reduce the risk of unauthorized or untested changes. AI-specific validation can include regression testing, safety evaluation, groundedness checks, latency measurements, and cost analysis. Direct production modifications make changes harder to audit and roll back. Controlled deployment processes improve reliability, governance, and repeatability across AI application releases.