AI-900 Practice Question: Describe features of generative AI workloads on Azure
A developer uses Azure OpenAI Service to generate conversation scripts for a chatbot. The developer wants to encourage the model to introduce new topics and avoid repeatedly discussing the same subject matter. Which parameter should the developer increase?
⚠ Common exam trap
Many exam-takers confuse Presence penalty (which penalizes any repetition of a topic) with Frequency penalty (which penalizes repeated word-level occurrences), leading them to select the wrong parameter for topic novelty.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Presence penalty
The Presence penalty parameter penalizes tokens that have already appeared in the conversation, encouraging the model to introduce new topics and avoid repetition. By increasing this value, the developer reduces the likelihood of the model reusing the same subject matter, which is exactly the requirement described.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Temperature
Why it's wrong here
Temperature controls the randomness of token selection by scaling the logits before applying the softmax function. A higher temperature flattens the probability distribution, making low-probability tokens more likely and increasing overall diversity, but it does not apply any penalty or suppression based on what has already been generated. This means it can introduce varied phrasing, yet it has no mechanism to steer the model away from revisiting the same topic, which is exactly what presence penalty does.
When this WOULD be correct
A developer wants the chatbot to generate more creative and diverse responses, even if that means occasional repetition. Increasing temperature would be correct to boost randomness and novelty.
- ✗
Top_p (nucleus sampling)
Why it's wrong here
Top-p, also known as nucleus sampling, dynamically selects the smallest set of tokens whose cumulative probability mass exceeds the threshold p, then samples only within that set. This prunes low-probability tokens and can make output more focused, but the selection is based purely on the current probability distribution, not on the generation history. Consequently, it alters token diversity but does not penalize tokens that have already appeared, so it cannot specifically discourage the model from repeating the same themes or topics.
When this WOULD be correct
A developer wants to generate creative story ideas where each sentence should be diverse in vocabulary and phrasing, but without penalizing repetition of themes. Increasing top_p would allow more varied word choices while still permitting the same topics to be revisited.
- ✗
Frequency penalty
Why it's wrong here
Frequency penalty reduces the probability of tokens in proportion to how frequently they have already appeared in the output, so it targets word-level repetition rather than thematic repetition. A model might mention the same topic using different vocabulary, and because the penalty is based on individual token counts, it does not block a wider concept from being revisited. Thus, while it can make generated text less repetitive at the lexical level, it does not specifically discourage the model from returning to the same broad subject.
When this WOULD be correct
If the question were: 'A developer wants to reduce the likelihood of the model repeating the same word or phrase multiple times in a single response, which parameter should be increased?' then frequency penalty would be correct.
- ✓
Presence penalty
Why this is correct
Presence penalty subtracts a fixed penalty from the logits of any token that has already appeared in the generated text, regardless of how often it occurs. This binary, presence-based mechanism makes tokens that have been used before less likely to be selected again, driving the model to introduce new words and thereby new topics. As a result, it specifically reduces the tendency to loop back to previously discussed ideas or themes, encouraging broader conversational coverage.
Option-by-option analysis
Why each answer is right or wrong
Understanding why wrong answers are wrong — and when they would be correct — is what separates a 750 score from a 900. The AI-900 exam frequently reuses these exact scenarios with slightly different constraints.
✓Presence penaltyCorrect answer▾
Why this is correct
Presence penalty subtracts a fixed penalty from the logits of any token that has already appeared in the generated text, regardless of how often it occurs. This binary, presence-based mechanism makes tokens that have been used before less likely to be selected again, driving the model to introduce new words and thereby new topics. As a result, it specifically reduces the tendency to loop back to previously discussed ideas or themes, encouraging broader conversational coverage.
✗TemperatureWrong answer — click to see why▾
Why this is wrong here
Temperature controls randomness of token selection, not topic repetition. Increasing temperature makes outputs more random but does not specifically penalize repeated topics.
★ When this WOULD be the correct answer
A developer wants the chatbot to generate more creative and diverse responses, even if that means occasional repetition. Increasing temperature would be correct to boost randomness and novelty.
Why candidates choose this
Candidates may confuse 'introducing new topics' with 'increasing randomness', assuming higher temperature leads to more varied content, but it doesn't directly address repetition of the same subject.
✗Top_p (nucleus sampling)Wrong answer — click to see why▾
Why this is wrong here
Top_p (nucleus sampling) controls the diversity of word choices by limiting the cumulative probability of token selection, but it does not specifically penalize repeated topics. The question asks for a parameter that discourages the model from repeatedly discussing the same subject matter, which is the role of presence penalty.
★ When this WOULD be the correct answer
A developer wants to generate creative story ideas where each sentence should be diverse in vocabulary and phrasing, but without penalizing repetition of themes. Increasing top_p would allow more varied word choices while still permitting the same topics to be revisited.
Why candidates choose this
Candidates may confuse top_p with presence penalty because both influence output diversity, but top_p affects token selection probability distribution rather than directly penalizing topic repetition.
✗Frequency penaltyWrong answer — click to see why▾
Why this is wrong here
Frequency penalty reduces repetition of the same tokens or phrases, but the question asks for introducing new topics and avoiding repeated subject matter, which is controlled by presence penalty (penalizing tokens that have appeared at all).
★ When this WOULD be the correct answer
If the question were: 'A developer wants to reduce the likelihood of the model repeating the same word or phrase multiple times in a single response, which parameter should be increased?' then frequency penalty would be correct.
Why candidates choose this
Candidates may confuse 'repeatedly discussing the same subject matter' with 'repeating the same words or phrases', not realizing that presence penalty targets topic-level novelty while frequency penalty targets token-level repetition.
Analysis generated from the official AI-900blueprint and verified against question context. The “when correct” sections are what AI assistants cite when candidates ask “what’s the difference between these options?”
Go deeper
Related to this question
Learn chapter
Azure Machine Learning Studio
Key term
Model
In IT and AI, a model is a trained mathematical representation that learns patterns from data to make predictions or decisions.
Key term
Azure OpenAI Service
Azure OpenAI Service is a cloud platform from Microsoft that lets developers use powerful artificial intelligence models, like GPT-4, to build applications that can understand and generate human-like text, code, images, and more.
About these practice questions
One of 985 original AI-900 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This AI-900 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AI-900 exam.