Elements of Prompt

Elements of a Prompt

A prompt contains any of the following elements:

  • Instruction - a specific task or instruction you want the model to perform
  • Context - external information or additional context that can steer the model to better responses
  • Input Data - the input or question that we are interested to find a response for
  • Output Indicator - the type or format of the output.

Consider this prompt as an example:

Classify the text into neutral, negative, or positive
Text: I think the food was okay.
Sentiment:

elements_of_prompt.png

For prompting we don't always needs all four of the elements, but it is good to know that how to use them.