Topic 04 Practice Test 2 covers Prompt Engineering, Prompt Management, Context, Prompt Flows, and Governance in Domain 1 (Task 1.6). For broader exam preparation, review the AIP-C01 Exam Dumps. Every option includes focused technical reasoning tied to the tested decision.
Question 1
A financial assistant may discuss budgeting but must refuse any request for insider-trading instructions, regardless of how the user phrases it. Which Amazon Bedrock Guardrails capability best expresses that policy? Choose ONE.
- Lower the prompt temperature to change sampling randomness during generation
- Store the conversation in DynamoDB to persist application state across requests
- Define insider trading as a denied topic
- Create a word filter containing the phrase insider trading
Correct Answer: C
Correct Answer
Answer C is correct because Define insider trading as a denied topic matches the need. Denied topics let an application specify subject areas that Guardrails should detect and block in user inputs or model responses. Specifically, The restriction is semantic and should apply across many phrasings, so a topic-level policy matches the governance requirement. Deciding constraint: must block insider-trading instructions.
Incorrect Answers
Answer A is incorrect because Lower the prompt temperature to change sampling randomness during generation does not solve this control. Temperature affects output randomness. In this scenario, It cannot detect whether a user is asking for a prohibited subject and therefore does not enforce the policy boundary. It fails: must block insider-trading instructions.
Answer B is incorrect because Store the conversation in DynamoDB to persist application state across requests serves another purpose: Persistent history can help preserve user context. Here, Remembering prior turns does not block a prohibited topic or prevent the model from generating restricted instructions. It misses this constraint: must block insider-trading instructions.
Answer D is incorrect because Word filters match configured words or phrases. Create a word filter containing the phrase insider trading can help elsewhere, but here An exact phrase list is easy to evade through synonyms or paraphrases, while the requirement explicitly says the prohibition must survive rewording. Unmet condition: must block insider-trading instructions.
Question 2
A public chatbot must block a newly prohibited company codename whenever that exact token appears in user input or model output. No broader semantic category needs to be blocked. Which control is most precise? Choose ONE.
- Add the codename to a Guardrails custom word filter
- Set maxTokens to one to change the maximum generated-response length
- Create a denied topic named confidential projects
- Use a condition node after generation to route flow execution by evaluated conditions
Correct Answer: A
Correct Answer
Answer A is correct because Add the codename to a Guardrails custom word filter provides the needed capability. Guardrails word filters can block configured custom words or phrases by exact match in interactions. For this workload, The policy concerns one literal token rather than a broader meaning, making the custom word list the narrowest suitable control. Constraint met: exact codename match only.
Incorrect Answers
Answer B is incorrect because Set maxTokens to one to change the maximum generated-response length does not solve this control. maxTokens only limits response length. In this scenario, A one-token output still does not inspect the user input for the prohibited codename and would destroy legitimate chatbot responses. It fails: exact codename match only.
Answer C is incorrect because Create a denied topic named confidential projects serves another purpose: Denied topics use semantic detection for subject areas. Here, That would likely block a wider range of legitimate discussions than the exact-token requirement calls for. It misses this constraint: exact codename match only.
Answer D is incorrect because Use a condition node after generation to route flow execution by evaluated conditions is adjacent but not sufficient. A flow condition node routes data based on explicit values or comparisons. Here, It could support custom logic, but Guardrails already provides a purpose-built exact word filter that covers both input and output. The unmet need is: exact codename match only.
Question 3
A RAG assistant must flag answers that introduce claims unsupported by the retrieved source passages. Which Guardrails feature most directly evaluates that quality problem? Choose ONE.
- Sensitive-information filters as a different governance mechanism
- Custom word filters to match configured words or phrases
- Prompt Management versions as a separate configuration change
- Contextual grounding checks
Correct Answer: D
Correct Answer
Answer D is correct because Contextual grounding checks: Guardrails contextual grounding checks can evaluate whether a generated response is grounded in provided source material and relevant to the user query. Here, The defect is unsupported generation relative to retrieved evidence, which is exactly the relationship grounding checks are designed to assess. This meets the case constraint: generated claims must be supported by retrieved passages.
Incorrect Answers
Answer A is incorrect because Sensitive-information filters detect and block or mask PII and configured patterns. Sensitive-information filters as a different governance mechanism can help elsewhere, but here They address privacy leakage, not whether a factual claim is supported by the retrieved context. Unmet condition: generated claims must be supported by retrieved passages.
Answer B is incorrect because Custom word filters to match configured words or phrases has a different function. Word filters block specified literal terms or phrases. Under these conditions, Unsupported claims cannot be reliably characterized by a static word list because the problem is evidence alignment rather than vocabulary. It does not meet: generated claims must be supported by retrieved passages.
Answer C is incorrect because Prompt Management versions as a separate configuration change does not solve this control. Prompt versions create point-in-time snapshots for controlled deployment. In this scenario, Versioning supports governance and rollback but does not inspect an individual generated answer for factual grounding against sources. It fails: generated claims must be supported by retrieved passages.
Question 4
An application wants to screen raw user text with a Bedrock guardrail before deciding whether any foundation-model call is necessary. Which API pattern best supports that requirement? Choose ONE.
- Create a Prompt Management version as a different governance mechanism
- Call ApplyGuardrail directly on the user input
- Write the input to CloudWatch Logs
- Invoke a model and inspect the stop reason only
Correct Answer: B
Correct Answer
Answer B is correct because The ApplyGuardrail API evaluates content against a configured guardrail without requiring a foundation-model invocation. In this case, Call ApplyGuardrail directly on the user input fits because It lets the application make a safety decision before spending tokens or sending the request to a model. Required condition: screen before any FM call.
Incorrect Answers
Answer A is incorrect because Create a Prompt Management version as a different governance mechanism is adjacent but not sufficient. A prompt version is a deployment snapshot of prompt configuration. Here, It does not independently evaluate user text and therefore cannot serve as the requested pre-inference safety gate. The unmet need is: screen before any FM call.
Answer C is incorrect because Write the input to CloudWatch Logs has a different function. Logging records data for later operations and analysis. Under these conditions, A log write does not apply content policies or return a guardrail decision that can gate the model call. It does not meet: screen before any FM call.
Answer D is incorrect because Invoke a model and inspect the stop reason only does not solve this control. A model invocation performs generation before the application gets its response metadata. In this scenario, That is too late for a requirement that explicitly needs guardrail evaluation before any foundation-model call. It fails: screen before any FM call.
Question 5
A contact-center summary may include a caller’s phone number internally, but the external transcript API must return a redacted value rather than reject the whole response. What Guardrails configuration best fits? Choose ONE.
- Mask the phone-number PII entity in a sensitive-information filter
- Set topP to a lower value to change nucleus-sampling diversity during generation
- Block every response containing a phone number
- Use a denied topic for telephone support
Correct Answer: A
Correct Answer
Answer A is correct because Mask the phone-number PII entity in a sensitive-information filter: Guardrails sensitive-information policies can identify supported PII such as phone numbers and mask detected values. Here, Masking meets the requirement to keep the rest of the transcript available while replacing the sensitive field in the external output. This meets the case constraint: external API must return redacted transcript.
Incorrect Answers
Answer B is incorrect because Set topP to a lower value to change nucleus-sampling diversity during generation is adjacent but not sufficient. topP adjusts the candidate-token probability mass used during generation. Here, Sampling configuration cannot guarantee that a phone number is detected and redacted from the final output. The unmet need is: external API must return redacted transcript.
Answer C is incorrect because A sensitive-information policy can also be configured to block content. Block every response containing a phone number can help elsewhere, but here Blocking would suppress the entire response, which is stricter than the stated requirement to return a usable redacted transcript. Unmet condition: external API must return redacted transcript.
Answer D is incorrect because Use a denied topic for telephone support has a different function. Denied topics block semantic subject areas. Under these conditions, Telephone support is legitimate content; the policy concerns one PII field inside that content, not the topic itself. It does not meet: external API must return redacted transcript.
Question 6
A prompt owner wants to compare the same instructions on two different models with different inference settings before selecting a production configuration. Which Prompt Management construct should be used? Choose ONE.
- Create a separate DynamoDB table for each model
- Use Guardrails versions as model variants to apply a configured model-interaction safeguard
- Create prompt variants with the alternative model and inference configurations
- Add multiple flow output nodes to return selected data from the workflow
Correct Answer: C
Correct Answer
Answer C is correct because Create prompt variants with the alternative model and inference configurations matches the need. A prompt variant can differ in message content, selected model, or inference configuration and can be tested against the same variables. Specifically, Variants make the alternatives directly comparable while keeping them associated with the same governed prompt. Deciding constraint: same instructions.
Incorrect Answers
Answer A is incorrect because Create a separate DynamoDB table for each model does not solve this control. DynamoDB tables store application data. In this scenario, Separate tables do not express alternative prompt configurations or provide a native way to compare model outputs during prompt testing. It fails: same instructions.
Answer B is incorrect because Use Guardrails versions as model variants to apply a configured model-interaction safeguard serves another purpose: Guardrail versions snapshot safety configurations. Here, They govern content filters, not the model and inference settings attached to a Prompt Management prompt. It misses this constraint: same instructions.
Answer D is incorrect because Multiple output nodes let different flow branches return results. Add multiple flow output nodes to return selected data from the workflow can help elsewhere, but here They do not define or compare alternative model configurations for one managed prompt. Unmet condition: same instructions.
Question 7
Production uses prompt version 7. A newly deployed version 8 causes a measurable quality regression, and no application code change should be required to restore the previous prompt configuration. What should the team do? Choose ONE.
- Increase maxTokens on version 8 to change the maximum generated-response length
- Point the application back to the previously approved prompt version 7
- Move conversation state to S3 to retain governed artifacts in object storage
- Delete all prompt versions and rebuild the draft to create an immutable governed prompt snapshot
Correct Answer: B
Correct Answer
Answer B is correct because Point the application back to the previously approved prompt version 7 is appropriate because prompt Management versions are deployable snapshots that let applications switch between known prompt configurations. Here, Returning to the prior approved snapshot restores the former prompt behavior without reconstructing the draft or rewriting the prompt text. This satisfies: version 8 regressed.
Incorrect Answers
Answer A is incorrect because Increase maxTokens on version 8 to change the maximum generated-response length has a different function. maxTokens only changes the response-length ceiling. Under these conditions, A general quality regression is not necessarily caused by truncation, and changing another parameter creates a new unvalidated configuration rather than rolling back. It does not meet: version 8 regressed.
Answer C is incorrect because Move conversation state to S3 to retain governed artifacts in object storage serves another purpose: S3 can store application or template artifacts. Here, Changing session-state storage does not restore the known-good prompt instructions and inference configuration from version 7. It misses this constraint: version 8 regressed.
Answer D is incorrect because Delete all prompt versions and rebuild the draft to create an immutable governed prompt snapshot is adjacent but not sufficient. Deleting release history removes the very rollback artifact needed for controlled recovery. Here, It would increase risk and require manual reconstruction instead of using the stable version that already passed approval. The unmet need is: version 8 regressed.
Question 8
A regulated team wants a central repository containing prompt templates, review notes, and release metadata that can be retained under S3 lifecycle and access policies. Which component best serves as that repository? Choose ONE.
- The model context window to keep prior messages inside the model context
- A Guardrails word filter to match configured words or phrases
- A Bedrock Flow condition node to route flow execution by evaluated conditions
- An Amazon S3 bucket with governed access and lifecycle controls
Correct Answer: D
Correct Answer
Answer D is correct because An Amazon S3 bucket with governed access and lifecycle controls: S3 is durable object storage suitable for template repositories, review artifacts, and release evidence with IAM, versioning, and lifecycle governance. Here, It provides the central retained artifact store the team needs without conflating repository management with model inference. This meets the case constraint: central retained repository.
Incorrect Answers
Answer A is incorrect because The context window contains request-time information supplied for inference. The model context window to keep prior messages inside the model context can help elsewhere, but here It is transient and bounded, making it inappropriate for regulated retention of templates and approval evidence. Unmet condition: central retained repository.
Answer B is incorrect because A Guardrails word filter to match configured words or phrases has a different function. Word filters enforce exact blocked terms during model interactions. Under these conditions, They neither store prompt files nor preserve review and release metadata for long-term governance. It does not meet: central retained repository.
Answer C is incorrect because A Bedrock Flow condition node to route flow execution by evaluated conditions does not solve this control. Condition nodes route runtime data according to expressions. In this scenario, Flow branching is an execution concern and does not provide a durable repository for governance artifacts. It fails: central retained repository.
Question 9
A virtual assistant receives “cancel it” after a multi-turn conversation. The application needs to determine whether the user means an order, subscription, or appointment before selecting the next workflow. Which capability best helps classify that intent? Choose ONE.
- Increase the prompt maxTokens value to change the maximum generated-response length
- Create a new prompt version for each possible intent to create an immutable governed prompt snapshot
- Use Amazon Comprehend or equivalent intent-classification logic on the current utterance plus relevant context
- Use a custom Guardrails word filter for cancel to match configured words or phrases
Correct Answer: C
Correct Answer
Answer C is correct because Use Amazon Comprehend or equivalent intent-classification logic on the current utterance plus relevant context provides the needed capability. Intent recognition can map ambiguous natural-language requests into application categories that drive the next deterministic workflow step. For this workload, Combining the short utterance with relevant conversation context helps identify which cancel action the user is referring to before execution. Constraint met: cancel could refer to three business objects.
Incorrect Answers
Answer A is incorrect because Increase the prompt maxTokens value to change the maximum generated-response length is adjacent but not sufficient. maxTokens affects response-length limits. Here, A larger output budget does not identify whether the target is an order, subscription, or appointment. The unmet need is: cancel could refer to three business objects.
Answer B is incorrect because Prompt versions snapshot prompt configuration. Create a new prompt version for each possible intent to create an immutable governed prompt snapshot can help elsewhere, but here They are release artifacts, not per-request routing labels, and creating versions per intent would not resolve the ambiguous utterance. Unmet condition: cancel could refer to three business objects.
Answer D is incorrect because Use a custom Guardrails word filter for cancel to match configured words or phrases does not solve this control. A word filter blocks literal text. In this scenario, The word “cancel” is legitimate and should trigger understanding, not blocking; the application must classify its intended object. It fails: cancel could refer to three business objects.
Question 10
A chat application using a Converse-capable model needs the current response to consider the last several user and assistant turns. Which prompt construction is most appropriate? Choose ONE.
- Create a new guardrail version after every message as a different governance mechanism
- Provide the prior user and assistant messages as conversational history with the final user message
- Raise topP for later turns to change nucleus-sampling diversity during generation
- Put every prior turn into the system prompt to set persistent model-level behavioral instructions
Correct Answer: B
Correct Answer
Answer B is correct because Provide the prior user and assistant messages as conversational history with the final user message matches the need. Prompt construction for Converse-capable models can include previous user prompts and assistant responses so the model considers that interaction history. Specifically, Supplying the relevant turns directly gives the model the context needed to interpret the current message consistently. Deciding constraint: current answer depends on last several turns.
Incorrect Answers
Answer A is incorrect because Create a new guardrail version after every message as a different governance mechanism serves another purpose: Guardrail versions snapshot safety policy. Here, They do not carry conversational state and should not be used as a per-turn memory mechanism. It misses this constraint: current answer depends on last several turns.
Answer C is incorrect because topP affects token-sampling diversity. Raise topP for later turns to change nucleus-sampling diversity during generation can help elsewhere, but here Changing randomness does not provide the missing earlier messages that the model needs to understand the conversation. Unmet condition: current answer depends on last several turns.
Answer D is incorrect because Put every prior turn into the system prompt to set persistent model-level behavioral instructions has a different function. System prompts are intended for persistent application instructions or context. Under these conditions, Mixing the entire conversation into the system instruction blurs roles and makes ongoing message history harder to manage correctly. It does not meet: current answer depends on last several turns.
Question 11
A managed prompt contains the placeholder {{language}}. An application invocation omits a value for that placeholder. What design action best prevents this class of runtime defect? Choose ONE.
- Add the word language to a Guardrails filter to apply a configured model-interaction safeguard
- Increase temperature to let the model infer the language to change sampling randomness during generation
- Create a new flow version automatically to preserve a published immutable workflow snapshot
- Validate that every required prompt variable has a supplied value before invoking the prompt
Correct Answer: D
Correct Answer
Answer D is correct because Prompt variables are runtime placeholders, so application-side validation can ensure the invocation provides the complete parameter set expected by the template. In this case, Validate that every required prompt variable has a supplied value before invoking the prompt fits because Failing early with a clear validation error is more reliable than sending an incomplete governed prompt to inference. Required condition: managed prompt requires {{language}}.
Incorrect Answers
Answer A is incorrect because Add the word language to a Guardrails filter to apply a configured model-interaction safeguard does not solve this control. Word filters block terms in model interactions. In this scenario, Blocking the variable name would not populate it and would interfere with legitimate prompt content. It fails: managed prompt requires {{language}}.
Answer B is incorrect because Increase temperature to let the model infer the language to change sampling randomness during generation serves another purpose: Temperature controls sampling and cannot reliably replace a missing application parameter. Here, Guessing a required runtime value would make behavior nondeterministic and violate the template’s explicit parameter contract. It misses this constraint: managed prompt requires {{language}}.
Answer C is incorrect because Create a new flow version automatically to preserve a published immutable workflow snapshot is adjacent but not sufficient. Flow versions snapshot workflow definitions. Here, Versioning the workflow does not supply the missing variable value and would turn a request-validation problem into release churn. The unmet need is: managed prompt requires {{language}}.
Question 12
A generation must stop as soon as the model emits the delimiter END_OF_RECORD because anything after that delimiter would break a legacy parser. Which inference configuration is most appropriate? Choose ONE.
- Add END_OF_RECORD to stopSequences
- Raise maxTokens substantially to change the maximum generated-response length
- Increase temperature to change sampling randomness during generation
- Create an S3 storage node to retain governed artifacts in object storage
Correct Answer: A
Correct Answer
Answer A is correct because Add END_OF_RECORD to stopSequences provides the needed capability. A stop sequence tells the model runtime to stop generation when the configured character sequence is produced. For this workload, Using the parser delimiter as a stop sequence bounds the response at the exact marker the legacy consumer expects. Constraint met: stop at END_OF_RECORD.
Incorrect Answers
Answer B is incorrect because Raise maxTokens substantially to change the maximum generated-response length does not solve this control. maxTokens sets an upper bound on output length. In this scenario, A larger ceiling makes extra trailing text more possible and does not tie termination to the required delimiter. It fails: stop at END_OF_RECORD.
Answer C is incorrect because Increase temperature to change sampling randomness during generation serves another purpose: Temperature changes token randomness. Here, It cannot guarantee that generation stops when a specific marker is emitted and may make output structure less predictable. It misses this constraint: stop at END_OF_RECORD.
Answer D is incorrect because Create an S3 storage node to retain governed artifacts in object storage is adjacent but not sufficient. An S3 storage node persists data after it reaches that point in a flow. Here, Storage does not change model termination behavior and therefore cannot enforce the parser boundary. The unmet need is: stop at END_OF_RECORD.
Question 13
A Bedrock Flow receives an array of support cases. Each case must pass through the same prompt node, and the generated results must be returned as one array. Which node combination best fits? Choose ONE.
- Use only an S3 storage node to retain governed artifacts in object storage
- Use an iterator before the prompt node and a collector after it
- Create one prompt variable containing the entire array to substitute runtime values into the template
- Use two condition nodes in sequence to route flow execution by evaluated conditions
Correct Answer: B
Correct Answer
Answer B is correct because Use an iterator before the prompt node and a collector after it provides the needed capability. An iterator emits array items one at a time to downstream nodes, while a collector can gather the processed items back into an array. For this workload, That pair applies the same prompt processing to each case and reconstructs the requested result collection. Constraint met: same prompt for every case.
Incorrect Answers
Answer A is incorrect because An S3 storage node writes supplied content to object storage. Use only an S3 storage node to retain governed artifacts in object storage can help elsewhere, but here It can persist an array but does not execute the prompt once for each case or collect the generated per-case outputs. Unmet condition: same prompt for every case.
Answer C is incorrect because Create one prompt variable containing the entire array to substitute runtime values into the template does not solve this control. A prompt variable can carry structured input if supported by the template. In this scenario, Passing the whole collection as one value does not provide the explicit per-item processing and aggregation behavior required by the flow. It fails: same prompt for every case.
Answer D is incorrect because Use two condition nodes in sequence to route flow execution by evaluated conditions serves another purpose: Condition nodes route values according to expressions. Here, Branching does not inherently walk every element of an array or reassemble per-item results into one collection. It misses this constraint: same prompt for every case.
Question 14
A Bedrock Flow condition node has two rules that can both be true for the same numeric input. The high-priority rule must win. How should the team configure the conditions? Choose ONE.
- Convert both rules into prompt variables to substitute runtime values into the template
- Increase the model temperature to change sampling randomness during generation
- Publish two aliases for the same flow
- Place the high-priority condition earlier in the condition list
Correct Answer: D
Correct Answer
Answer D is correct because Place the high-priority condition earlier in the condition list is appropriate because bedrock Flow condition nodes evaluate conditions in order, and when more than one is satisfied, the earlier matching condition takes precedence. Here, Ordering the priority rule first makes routing deterministic for inputs that satisfy both expressions. This satisfies: multiple conditions can be true.
Incorrect Answers
Answer A is incorrect because Convert both rules into prompt variables to substitute runtime values into the template is adjacent but not sufficient. Variables provide values to prompt templates. Here, They do not define conditional-connection precedence and would move deterministic routing into the wrong abstraction. The unmet need is: multiple conditions can be true.
Answer B is incorrect because Temperature affects model sampling and has no influence on deterministic condition-node evaluation. Increase the model temperature to change sampling randomness during generation can help elsewhere, but here The route conflict exists entirely in flow logic, so an inference setting cannot resolve precedence. Unmet condition: multiple conditions can be true.
Answer C is incorrect because Publish two aliases for the same flow has a different function. Aliases provide application-facing routing to published flow versions. Under these conditions, They do not choose between conditions inside a single flow execution. It does not meet: multiple conditions can be true.
Question 15
A Bedrock Flow knowledge-base node should return raw retrieved passages for a later custom prompt rather than generating an answer inside the knowledge-base node. What configuration best supports that design? Choose ONE.
- Omit modelId from the knowledge-base node so it returns retrieval results
- Add a modelId so the node performs RetrieveAndGenerate to control whether the knowledge-base node generates text
- Replace the knowledge-base node with a Guardrails word filter
- Raise the flow maxIterations value as a different governance mechanism
Correct Answer: A
Correct Answer
Answer A is correct because Omit modelId from the knowledge-base node so it returns retrieval results: A Bedrock Flow knowledge-base node can return retrieved results as an array when no model is specified for response generation. Here, That keeps retrieval separate so the later custom prompt can decide how to consume and format the evidence. This meets the case constraint: raw passages needed for later custom prompt.
Incorrect Answers
Answer B is incorrect because Add a modelId so the node performs RetrieveAndGenerate to control whether the knowledge-base node generates text is adjacent but not sufficient. Specifying a model causes the node to generate output from the retrieved content. Here, That would collapse retrieval and generation into the same node, contrary to the requirement for a later custom prompt. The unmet need is: raw passages needed for later custom prompt.
Answer C is incorrect because A word filter blocks configured terms during model interactions. Replace the knowledge-base node with a Guardrails word filter can help elsewhere, but here It has no retrieval function and cannot return the source passages needed by the downstream prompt. Unmet condition: raw passages needed for later custom prompt.
Answer D is incorrect because Raise the flow maxIterations value as a different governance mechanism has a different function. maxIterations limits DoWhile loop repetitions. Under these conditions, The design has no loop requirement, and iteration count does not control whether a knowledge-base node generates or returns retrieval results. It does not meet: raw passages needed for later custom prompt.
Question 16
A Bedrock Flow must normalize a proprietary record format before the prompt and then apply deterministic redaction rules after generation. Existing Lambda functions already implement both transformations. What is the best flow design? Choose ONE.
- Increase maxTokens to accommodate the record to change the maximum generated-response length
- Use a flow condition node with no Lambda integration to route flow execution by evaluated conditions
- Invoke the preprocessing and post-processing Lambda functions as dedicated flow steps around the prompt
- Put both transformations into the model prompt only as a separate configuration change
Correct Answer: C
Correct Answer
Answer C is correct because Invoke the preprocessing and post-processing Lambda functions as dedicated flow steps around the prompt matches the need. Bedrock Flows can integrate AWS services such as Lambda into an end-to-end workflow so deterministic code can transform data before or after model inference. Specifically, Reusing the existing functions keeps proprietary normalization and redaction deterministic while the prompt remains focused on generation. Deciding constraint: existing Lambda transformations.
Incorrect Answers
Answer A is incorrect because Increase maxTokens to accommodate the record to change the maximum generated-response length does not solve this control. maxTokens controls only generated response length. In this scenario, It does not run the proprietary normalization logic before inference or the deterministic redaction logic afterward. It fails: existing Lambda transformations.
Answer B is incorrect because Use a flow condition node with no Lambda integration to route flow execution by evaluated conditions serves another purpose: Condition nodes choose routes based on expressions. Here, They cannot execute the existing transformation code unless the workflow actually invokes the Lambda functions that implement it. It misses this constraint: existing Lambda transformations.
Answer D is incorrect because A prompt can instruct a model to reformat or omit information. Put both transformations into the model prompt only as a separate configuration change can help elsewhere, but here The organization already has deterministic tested code for both rules, and replacing it with probabilistic behavior would weaken reliability and governance. Unmet condition: existing Lambda transformations.
Question 17
A prompt node inside a Bedrock Flow must apply an approved guardrail to both the prompt interaction and generated response. Which prompt-node configuration should the team provide? Choose ONE.
- Put the guardrail name in a prompt variable
- Set only the S3 bucket ARN to retain governed artifacts in object storage
- Set maxIterations on the prompt node as a different governance mechanism
- Set guardrailConfiguration with the approved guardrail identifier and version
Correct Answer: D
Correct Answer
Answer D is correct because Set guardrailConfiguration with the approved guardrail identifier and version matches the need. A Bedrock Flow prompt node supports a guardrail configuration containing the guardrail identifier and guardrail version. Specifically, Attaching the approved version at the node makes the safety policy part of the governed prompt execution path. Deciding constraint: prompt node must enforce approved guardrail.
Incorrect Answers
Answer A is incorrect because Put the guardrail name in a prompt variable has a different function. Prompt variables substitute text values at runtime. Under these conditions, A string inside the prompt is not equivalent to configuring Bedrock to evaluate the interaction with the approved Guardrails resource. It does not meet: prompt node must enforce approved guardrail.
Answer B is incorrect because Set only the S3 bucket ARN to retain governed artifacts in object storage does not solve this control. An S3 ARN identifies object storage. In this scenario, It does not select a Guardrails policy or cause the prompt node to evaluate inputs and outputs against safety filters. It fails: prompt node must enforce approved guardrail.
Answer C is incorrect because Set maxIterations on the prompt node as a different governance mechanism serves another purpose: maxIterations belongs to a DoWhile loop configuration. Here, It is unrelated to prompt-node safety enforcement and cannot identify which guardrail version should be applied. It misses this constraint: prompt node must enforce approved guardrail.
Question 18
Developers changed a Bedrock Flow draft and want to test the new graph, then expose only an immutable approved snapshot to the application. What release sequence is correct? Choose ONE.
- Prepare and test the working draft, publish a version, create or update an alias, then invoke the alias
- Invoke the draft from production and publish a version only after an incident as a separate workflow technique
- Create an alias before the flow has any published version to route application traffic to a published flow version
- Store the draft JSON in CloudWatch Logs and invoke the log group to retain searchable operational log events
Correct Answer: A
Correct Answer
Answer A is correct because Bedrock Flows uses a working draft for iterative testing, immutable published versions for release snapshots, and aliases as application-facing invocation targets. In this case, Prepare and test the working draft, publish a version, create or update an alias, then invoke the alias fits because That sequence validates changes before freezing them and keeps production traffic away from the mutable draft. Required condition: mutable development draft.
Incorrect Answers
Answer B is incorrect because Invoke the draft from production and publish a version only after an incident as a separate workflow technique has a different function. The draft can change as developers edit the flow. Under these conditions, Direct production use removes the approval boundary and makes behavior depend on unversioned work in progress. It does not meet: mutable development draft.
Answer C is incorrect because Create an alias before the flow has any published version to route application traffic to a published flow version does not solve this control. Aliases route application calls to deployable flow versions. In this scenario, Without a published snapshot there is no approved immutable release for the alias to target. It fails: mutable development draft.
Answer D is incorrect because Store the draft JSON in CloudWatch Logs and invoke the log group to retain searchable operational log events serves another purpose: CloudWatch Logs can retain diagnostic data. Here, A log group is not a Bedrock Flow deployment target and cannot process InvokeFlow requests. It misses this constraint: mutable development draft.
Question 19
A prompt regression test has 500 representative cases with expected categorical outcomes. The team wants the release pipeline to fail automatically when accuracy drops below 97%. Which design is best? Choose ONE.
- Increase temperature until average accuracy improves to change sampling randomness during generation
- Store the 500 cases in a prompt variable to substitute runtime values into the template
- Run the cases automatically, compute the pass rate, and make the pipeline gate fail below 97%
- Have an operator read a random output after deployment as an adjacent operational control
Correct Answer: C
Correct Answer
Answer C is correct because Run the cases automatically, compute the pass rate, and make the pipeline gate fail below 97%: A deterministic evaluation harness can invoke the candidate prompt across the fixed suite, compare outputs with expected outcomes, and emit one release metric. Here, Turning the threshold into an automated gate makes the acceptance criterion repeatable and prevents a known regression from being promoted. It meets the requirement: 500 cases with expected outcomes.
Incorrect Answers
Answer A is incorrect because Increase temperature until average accuracy improves to change sampling randomness during generation is adjacent but not sufficient. Temperature changes sampling behavior and can also increase variance. Here, Tuning one inference parameter is not a substitute for executing the defined regression suite and enforcing its acceptance threshold. The unmet need is: 500 cases with expected outcomes.
Answer B is incorrect because Prompt variables provide runtime substitutions to one prompt invocation. Store the 500 cases in a prompt variable to substitute runtime values into the template can help elsewhere, but here A variable does not execute hundreds of tests, compare outcomes, or make the release pipeline fail on aggregate accuracy. Unmet condition: 500 cases with expected outcomes.
Answer D is incorrect because Have an operator read a random output after deployment as an adjacent operational control does not solve this control. Manual spot checks can catch obvious defects but provide weak coverage and occur too late. In this scenario, The requirement calls for a measurable pre-release threshold across a large representative set. It fails: 500 cases with expected outcomes.
Question 20
A summarization prompt frequently omits two mandatory compliance facts even though they are present in the source text. The response should remain concise. Which revision most directly addresses the defect? Choose ONE.
- Move the prompt to another S3 prefix to retain governed artifacts in object storage
- Add an explicit checklist of the two required facts to the output instructions
- Increase maxTokens without changing the instructions to change the maximum generated-response length
- Raise topP to diversify summaries to change nucleus-sampling diversity during generation
Correct Answer: B
Correct Answer
Answer B is correct because Add an explicit checklist of the two required facts to the output instructions matches the need. Structured instructions can state mandatory content elements while still imposing a concise format or length target. Specifically, The observed failure is omission of known required facts, so naming those elements in the response contract directly focuses the model on them. Deciding constraint: two facts must always appear.
Incorrect Answers
Answer A is incorrect because Move the prompt to another S3 prefix to retain governed artifacts in object storage serves another purpose: Changing object location can support repository organization. Here, It does not alter the model instructions or make the required compliance facts more likely to appear. It misses this constraint: two facts must always appear.
Answer C is incorrect because A higher token ceiling helps only when the response is being truncated. Increase maxTokens without changing the instructions to change the maximum generated-response length can help elsewhere, but here The requirement says the summary should remain concise and does not indicate truncation, so extra capacity does not explain which facts are mandatory. Unmet condition: two facts must always appear.
Answer D is incorrect because Raise topP to diversify summaries to change nucleus-sampling diversity during generation has a different function. A higher topP can widen token choices and increase variation. Under these conditions, More diversity makes inclusion less predictable and does not encode the two compliance facts that must always appear. It does not meet: two facts must always appear.