GCP Generative AI Leader Practice Question 7: Consistent Output Format
Google Cloud Generative AI Leader · Test 1 · question 7 of 10
A retail merchandising team uses Gemini to write product descriptions. The instructions in the prompt are clear, but the output keeps drifting: some descriptions are one paragraph, some are bullet lists, and the brand's tone is inconsistent. The team has a dozen approved descriptions that show exactly the format and voice it wants.
What is the simplest effective change the team lead should suggest?
Show answer and explanation
Answer:
This is few-shot prompting. The team is currently giving instructions only, which is zero-shot prompting. Adding a few input-and-output examples to the prompt shows the model the format, phrasing, scope, and pattern the team wants. Examples are one of the most dependable ways to get consistent structure and tone. The change takes minutes and needs no new infrastructure, and the approved descriptions the team already has are ideal material.
Option A pushes in the wrong direction. A higher temperature makes the output more random and varied, which is the opposite of consistency.
Option C could work, but it is not the simplest step. Fine-tuning costs time and money and needs a larger training dataset than twelve examples. Google recommends trying prompt design first and tuning only when prompting is not enough.
Option D describes chain-of-thought prompting. It helps with multi-step reasoning problems such as calculations or logic, but it does nothing to fix the format and voice of marketing copy.
References: Include few-shot examples; Introduction to tuning