Q63 — AWS AIF-C01 Ch.3

Question 63 of 100 | ← Chapter 3

A regional utility company wants to build a generative AI application that provides customers with personalized energy-saving tips. The company developed an application that constructs prompts by inserting customer inputs into a prompt template. Customer inputs are restricted to selections from a prepopulated list—including postal code, household size, and topics of interest. Security of the company’s systems and customer data is paramount. Which solution provides the strongest security benefit to prevent prompt injection attacks?

Correct Answer: B. Add instructions in the prompt template on how to handle irrelevant requests

Explanation

Preventing prompt injection attacks is critical when building generative AI applications. Such attacks often occur when user input is improperly handled or interpreted, potentially leading to unintended or malicious behavior. In this scenario, although customer input is constrained to a prepopulated list, secure handling during insertion into the prompt template remains essential. View all