Skip to main content

Adjust advanced settings

Adjust the advanced settings to have better control over generated output in Google Sheets. You can learn more in the OpenAI API documentation.

TermDefinition
TokenTokens can be thought of as pieces of words. During processing, the language model breaks down both the input (prompt) and the result (completion) texts into smaller units called tokens. Tokens generally correspond to ~4 characters of common English text. So 100 tokens are approximately worth 75 words. Learn more with our token guide.
Token limitToken limit is the maximum total number of tokens that can be used in both the input (prompt) and the result (completion) when interacting with a language model.
Max tokensCut-off limit of the result measured in tokens. If the result is larger than this limit, it will be truncated. Helps control cost and speed.
Top PHelps adjust creativity level - Lower values result in more focused output, while higher values allow for more creative responses.
Frequency penaltyPenalizes tokens based on their frequency in the text so far - Higher values discourage the model from repeating the same tokens too frequently, as the more they appear in the text, the more penalized they get.
Presence penaltyPenalizes new tokens based on whether they appear in the text so far - Higher values encourage the model to use new tokens, that are not penalized.
  1. In the GPT for Sheets sidebar, click Default settings.

  2. Open the View advanced settings dropdown.

  3. Set the values for:

    • Max tokens: Set a cut-off limit for results by entering a maximum number of tokens. The value must be lower than the model limit to make room for input tokens.

      Use the slider or the text field to input a value
    • Top P: Adjust the creativity level by entering a value from 0 to 1.

      Use the slider or the text field to input a value
      note

      Set the temperature parameter to 1 when the value for Top P is lower than 1.

    • Frequency penalty: Set a penalty to apply to tokens each time they are repeated in the result by entering a value from 0 to 2.

      Use the slider or the text field to input a value
    • Presence penalty: Set a one-time penalty for tokens that appear more than once in the result by entering a value from 0 to 2.

      Use the slider or the text field to input a value

You can now execute a GPT function in the current spreadsheet with these advanced settings.

What's next

Refresh your GPT formulas to get results that take these new settings into account.