AWS Certified AI Practitioner (AIF-C01) — Question 99
Which prompting technique can protect against prompt injection attacks?
Answer options
- A. Adversarial prompting
- B. Zero-shot prompting
- C. Least-to-most prompting
- D. Chain-of-thought prompting
Correct answer: A
Explanation
Adversarial prompting is designed to identify and mitigate the risks associated with prompt injection attacks by anticipating potential malicious inputs. The other techniques, while useful for various applications, do not inherently focus on the security aspects necessary to counteract such threats.