
Ultimate access to all questions.
Deep dive into the quiz with AI chat providers.
We prepare a focused prompt with your quiz and certificate details so each AI can offer a more tailored, in-depth explanation.
A developer wants to train a model to classify text reviews as positive or negative. They provide two example inputs and outputs before the main query. What type of prompting is being used?
A
Zero-shot Prompting
B
Few-shot Prompting
C
Negative Prompting
D
Guided Prompting
Explanation:
Few-shot Prompting is the correct answer because the developer is providing two example inputs and outputs before the main query.
Few-shot Prompting:
Involves providing a small number of examples (typically 2-5) to demonstrate the desired task
Helps the model understand the pattern or format expected
The examples serve as a "demonstration" of how to process similar inputs
Zero-shot Prompting:
Would involve asking the model to perform the task without any examples
The model relies solely on its pre-trained knowledge
Negative Prompting:
Typically refers to specifying what NOT to include in the output
Common in image generation models
Guided Prompting:
Not a standard term in prompt engineering
May refer to providing step-by-step instructions
The question explicitly states "They provide two example inputs and outputs before the main query," which is the definition of few-shot prompting. The examples help the model understand the classification task (positive vs. negative reviews) by showing it how similar inputs should be processed.
In AWS services like Amazon Bedrock or SageMaker, few-shot prompting is commonly used when working with foundation models to improve accuracy on specific tasks without full fine-tuning.