AI-900 practice question 5 of 35

Which parameter should you configure to produce a more diverse range of tokens in the responses from a chat solution that uses the Azure OpenAI GPT-3.5 model?

Full set: 316 questions

Domain Describe fundamental principles of machine learning on Azure

Answer options
A: Max response
B: Past messages included
C: Presence penalty Correct answer
D: Stop sequence
Correct Answer:
C. Presence penalty
Explanation

The presencepenalty parameter is specifically designed to influence the diversity of the generated text. By applying a penalty to tokens that have already appeared in the conversation history and the generated output, it discourages the model from repeating itself. A positive presencepenalty value increases the likelihood that the model will introduce new topics and use a more varied vocabulary, directly addressing the requirement to produce a more diverse range of tokens.

Why Incorrect

A. Max response: This parameter (maxtokens) controls the maximum length of the generated response, not the diversity or variety of the words used within it.
B. Past messages included: This refers to the conversational history provided as context. While context influences the response, it is not a configurable parameter for controlling token diversity.
D. Stop sequence: This parameter defines specific sequences of text that, when generated, will cause the model to stop its output. It is a termination control, not a diversity control.

References

1. Microsoft Learn, Azure AI Services Documentation. "Learn how to work with the Azure OpenAI models". Under the "Chat completion" section, the presencepenalty parameter is defined: "Positive values penalize new tokens based on whether they appear in the text so far, increasing the model's likelihood to talk about new topics."

2. Microsoft Learn, Azure OpenAI Service REST API reference. In the "Create chat completion" API documentation, the presencepenalty parameter is described as a mechanism to penalize new tokens based on their existing presence in the text, which encourages the model to generate novel content.

Scroll to Top