Generative AI Leader Practice Question: Techniques to Improve Generative AI Model Output
A financial services firm is using a foundation model on Vertex AI to generate investment summaries from quarterly reports. The summaries are accurate but often miss key financial metrics and trends. The team cannot afford to fine-tune the model frequently. Which technique should they use to improve the completeness and relevance of the summaries without modifying the model?
⚠ Common exam trap
Watch out — candidates often confuse hyperparameter tuning (temperature, top_p) with prompt engineering, assuming that increasing randomness or restricting token selection will improve output quality, when in fact few-shot examples directly teach the model the desired output structure without modifying the model.
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
✓
Provide three few-shot examples in the prompt that highlight the desired metrics.
Few-shot prompting provides the model with concrete examples of desired output structure and content, guiding it to include key financial metrics and trends without retraining. This technique leverages in-context learning, where the model generalizes from the examples in the prompt to produce more complete and relevant summaries, while avoiding the cost and latency of fine-tuning.
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 temperature to 0.9 to encourage more creative outputs.
Why it's wrong here
Raising temperature increases randomness, which risks fabricated figures rather than surfacing the report's actual metrics and trends. It is tempting because temperature tuning shapes output variety, and would be correct for brainstorming or creative drafting where diverse phrasing matters more than factual completeness.
- ✓
Provide three few-shot examples in the prompt that highlight the desired metrics.
Why this is correct
Few-shot prompting supplies in-context examples that steer the foundation model toward including the specific financial metrics and trends the firm needs, without altering weights. This satisfies the constraint of avoiding frequent fine-tuning, since the model remains unmodified and behaviour is shaped purely through prompt content at inference time.
- ✗
Set stop sequences to [' '] to ensure the model finishes each paragraph.
Why it's wrong here
Stop sequences merely halt generation at a chosen string; they cannot pull missing metrics from the quarterly reports into the summary. They are tempting because they control output length and formatting, and would be correct where the model must end each paragraph at a defined delimiter.
- ✗
Lower top_p to 0.5 to reduce the sampling pool.
Why it's wrong here
Lowering top_p narrows token sampling, making wording more predictable but adding no report content, so omitted metrics stay omitted. It is tempting because nucleus sampling controls output diversity, and it would suit a scenario needing tighter, less rambling prose rather than improved factual coverage.
Go deeper
Related to this question
About these practice questions
This Generative AI Leader question is part of Courseiva's 1,008-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. 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.