Generative AI Leader Practice Question: Techniques to Improve Generative AI Model Output
A content generation model for e-commerce product descriptions repeats the same phrases across multiple descriptions (e.g., 'high-quality', 'best-in-class'). The team wants more varied and engaging output. Which parameter adjustment is most appropriate?
⚠ Common exam trap
The Generative AI Leader exam often tests the distinction between frequency penalty and temperature, where candidates mistakenly increase temperature to add variety, not realizing that temperature increases randomness and can break coherence, while frequency penalty directly targets repetition without sacrificing quality.
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
✓
Increase the frequency penalty parameter to 1.0.
Increasing the frequency penalty to 1.0 penalizes tokens that have already appeared in the generated text, directly reducing repetition of phrases like 'high-quality' and 'best-in-class'. This encourages the model to use more diverse vocabulary and sentence structures, leading to varied and engaging product descriptions.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
Increase the frequency penalty parameter to 1.0.
Why this is correct
Raising frequency penalty to 1.0 penalises tokens proportionally to how often they have already appeared in the generated text, directly discouraging the repeated phrases the stem describes. This satisfies the requirement for varied, engaging product descriptions without altering the model's underlying knowledge or the prompt itself.
- ✗
Decrease the max output tokens to 50.
Why it's wrong here
Truncating output at 50 tokens shortens descriptions but does not alter token selection probabilities, so repeated phrases persist. Max output tokens governs response length, not lexical diversity. It would be the right control when responses must fit a strict size limit, such as generating short product titles.
- ✗
Increase the temperature parameter to 1.5.
Why it's wrong here
Temperature 1.5 over-flattens the probability distribution, producing incoherent, off-topic text and possible hallucinated product claims rather than controlled variation. High temperature suits brainstorming or creative drafting where factual accuracy is not critical, not e-commerce copy.
- ✗
Set the top-p value to a very small number like 0.1.
Why it's wrong here
A top-p of 0.1 restricts sampling to the highest-probability tokens, narrowing vocabulary and increasing repetition rather than reducing it. Low top-p suits factual, deterministic outputs such as structured data extraction, where consistency matters more than variety.
Go deeper
Related to this question
About these practice questions
One of 1,008 original Generative AI Leader 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 Generative AI Leader practice question is part of Courseiva's free Google Cloud 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 Generative AI Leader exam.