Prompt engineering for text generation: Difference between revisions

Line 23: Line 23:


===Context or External Information===
===Context or External Information===
Context or external information is the additional information for the model that might not exist in the model. They can be manually inserted into the prompt, retrieved via a vector database ([[retrieval augmentation]]), or gathered from other sources such as [[APIs]]. Providing context helps the model generate more informed and precise responses.
Context or external information is the additional information for the model that might not exist in the model. They can be manually inserted into the prompt, retrieved via a vector database ([[retrieval augmentation]]), or gathered from other sources such as [[APIs]]. Providing context helps the model generate more informed and precise responses.
*Context or external information is entirely optional.


===Example(s)===
===Example(s)===
Example(s) are a few instances of user input/query along with corresponding output provided by the user and shown to the language model. It is often utilized in [[few-shot prompting]] and is entirely optional.


===User Input or Query===
===User Input or Query===
370

edits