hardMultiple Choice
Generative AI Leader Practice Question: A large enterprise is planning to roll out a…
A large enterprise is planning to roll out a GenAI assistant for contract negotiation. The legal team wants to ensure that the assistant's outputs are consistent and follow a predefined format for downstream processing. What is the BEST prompt engineering technique?
⚠ Common exam trap
Google often tests the misconception that vague instructions or reasoning techniques (like chain-of-thought) are sufficient for output consistency, when in fact only explicit, machine-readable format constraints guarantee the structured output required for enterprise automation.
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
✓
Define a structured output schema (e.g., JSON) in the prompt and request the model to output in that format
Defining a structured output schema (e.g., JSON) in the prompt explicitly constrains the model's output format, ensuring consistency and machine-readability for downstream contract negotiation processing. This technique leverages the model's instruction-following capability to produce parseable, schema-compliant responses, which is critical for automated legal workflows where variable formatting would break integration.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Use few-shot examples with variable formatting
Why it's wrong here
Variable formatting in the examples actively teaches the model to vary structure, defeating the fixed-format requirement. Few-shot examples are tempting because they reliably steer output, and they would be correct if every example demonstrated the identical target schema.
- ✗
Add a system instruction to 'be consistent'
Why it's wrong here
A vague 'be consistent' instruction gives the model no schema, so output structure still varies run to run. It is tempting because it sounds like a constraint, but it is the correct approach only when tone or style, not machine-parseable formatting, is the goal.
- ✓
Define a structured output schema (e.g., JSON) in the prompt and request the model to output in that format
Why this is correct
Specifying a structured output schema such as JSON in the prompt constrains the model's response format, ensuring consistent, machine-parseable contracts that downstream systems can process. This directly satisfies the legal team's requirement for predefined, repeatable output formatting.
- ✗
Use chain-of-thought prompting to have the model reason step-by-step
Why it's wrong here
Chain-of-thought improves reasoning accuracy on complex problems but does not constrain output structure, so formats still drift. It is tempting because contract negotiation involves reasoning, yet it is the right choice when correctness of logic matters rather than consistent downstream-parseable formatting.
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.