Gpt example
$create template generates a template for GPT-3 to follow when producing text.
This function is used during conversations with a GPT-3 model to provide a structured pattern for response creation.
Parameters
Prompt: This parameter refers to the starting point the model will use to generate a response. It should be formulated in a way that guides the GPT-3 model to follow the desired pattern.
Completion: This parameter refers to the expected response or ending part of the text. This is used as an example for the GPT-3 model to understand how to complete a response based on the provided prompt.
Return Value
This function returns a string, which represents the template for GPT-3 to follow. The template will use both the provided prompt and completion.
Example
$template = $create template("Translate the following english text to french:", "The cat sat on the mat.")
In this script the function creates a template with the prompt "Translate the following english text to french:" and the completion "The cat sat on the mat.". The generated template is then stored in the variable named "template".