Courseiva

Generative AI Leader Practice Question: Business Strategies for Generative AI Solutions

A company is choosing a generative AI model for code generation. Which TWO considerations are most important?

⚠ Common exam trap

Candidates often assume more parameters (A) or lower latency (E) are always better, but Google tests the understanding that domain-specific training data relevance (B) and context length (D) are critical for code generation accuracy and handling long code sequences.

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

✓

Whether the model's training data includes the target programming languages

Option B is correct because a code-generation model must have been trained on the target programming languages (e.g., Python, Java, C++) to produce syntactically valid and idiomatic code; a model lacking exposure to a language will generate unreliable or non-compiling output. Option D is correct because maximum context length determines how much source code, documentation, and surrounding files the model can ingest at once, which is critical for tasks like multi-file refactoring, repository-level completion, and understanding large codebases. Option A is not decisive because parameter count alone does not guarantee code quality; a smaller model fine-tuned on code can outperform a larger general-purpose model. Option C is not a primary technical consideration for code-generation capability, though licensing matters for legal/commercial deployment rather than model effectiveness. Option E affects user experience and cost but is a deployment concern, not a core capability consideration for choosing a code-generation model.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    The total number of model parameters

    Why it's wrong here

    The total number of model parameters is not the most important consideration for code generation. While larger models may perform better, parameter count alone does not ensure quality; relevance of training data and context length are more critical.

  • ✓

    Whether the model's training data includes the target programming languages

    Why this is correct

    Code generation depends on the model having seen the target programming languages during training; without that coverage, syntax, idioms and library usage are unreliable, so training-data language coverage directly determines output quality for the required languages.

  • ✗

    The open-source license of the model

    Why it's wrong here

    The open-source license of the model is a legal and community consideration, but it is not a primary technical factor for code generation effectiveness. The license does not directly impact the model's ability to generate code.

  • ✓

    The maximum context length supported by the model

    Why this is correct

    Context length determines how much code, documentation and surrounding files the model can consider in one prompt. Code generation frequently requires whole-file or multi-file context, so a short window truncates inputs and degrades output quality regardless of other model strengths.

  • ✗

    The latency of the model's inference endpoint

    Why it's wrong here

    Latency of the inference endpoint is a performance metric that depends on deployment and user experience, but it is not a primary consideration when selecting a model for code generation; factors like training data and context length are more important.

Visual reference

Client Server SYN (seq=100) SYN-ACK (seq=200, ack=101) ACK (ack=201) Connection established — data transfer begins

About these practice questions

Courseiva writes every Generative AI Leader question from scratch — 1,008 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

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.