Which prompt engineering strategy enables sentiment analysis on Amazon Bedrock?
A company wants to use a large language model (LLM) on Amazon Bedrock for sentiment analysis. The company wants to classify the sentiment of text passages as positive or negative. Which prompt engineering strategy meets these requirements?
Community Votes
100% of anonymous learners picked answer A. Votes are pick records left by other test-takers — they are not the verified answer.
Community Insight
The exam tests your understanding of few-shot prompting versus zero-shot prompting; the common trap is assuming that a detailed explanation of the task (option B) or simply providing raw text (option C) is sufficient without demonstrating the expected input-output pattern.
Few-shot prompting is the recommended strategy for sentiment analysis on Amazon Bedrock because providing labeled examples of positive and negative text passages helps the LLM understand the classification pattern. Community consensus confirms that few-shot learning significantly improves accuracy by guiding the model with clear context before presenting the new input.
Option C is a common wrong answer because candidates assume the LLM inherently understands sentiment analysis without needing explicit examples, overlooking that zero-shot prompting often yields inconsistent results compared to few-shot prompting.
Community Discussion (6 comments)
Comments & Corrections
No comments yet — spotted an error or have a note? Share it below.
Expert Analysis
Why the Answer Is Correct
Option A demonstrates few-shot prompting, a proven technique where labeled examples are included in the prompt to guide the LLM's output format and reasoning. By showing text passages paired with positive or negative labels, the model learns the exact classification pattern expected. This approach is explicitly recommended in AWS documentation for improving accuracy on classification tasks using Amazon Bedrock.Why the Other Options Are Wrong
Option B provides theoretical context but no practical examples, leaving the model without a clear demonstration of the desired input-output mapping. Option C relies on zero-shot prompting, which may produce inconsistent or incorrectly formatted responses since the model lacks explicit guidance. Option D introduces unrelated task examples, which confuse the model by providing irrelevant patterns that do not align with sentiment classification.Community Comment Notes
Community members unanimously support option A, with multiple comments highlighting that few-shot prompting is the most effective strategy for guiding LLMs on classification tasks. Commenters emphasize that providing labeled examples helps the model understand both the task context and the expected output format, reducing ambiguity and improving reliability.Official Reference
Exam Strategy
When evaluating prompt engineering strategies, always prioritize approaches that provide concrete examples of the expected input-output pattern. Few-shot prompting consistently outperforms zero-shot or overly verbose explanations for classification tasks on AWS certification exams.
Related Analysis
Practice All AIF-C01 Questions
Access 100 questions with complete answers and detailed explanations.
View Full AIF-C01 Practice Test →