NCP-GENL Fine-Tuning Practice Question
A developer is preparing a supervised fine-tuning dataset for an instruction-tuned LLM using NVIDIA NeMo. The dataset contains prompts and responses, but the model sometimes learns to generate the prompt text as part of the response. Which dataset formatting practice should be applied to prevent this?
⚠ Common exam trap
The trap here is thinking that dataset formatting alone controls what the model learns, when the loss mask determines which tokens actually contribute gradients.
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
✓
Use a loss mask that excludes prompt tokens so the model is trained only on response tokens.
Prompt echoing occurs when the loss is computed over both prompt and response tokens. Applying a loss mask that excludes prompt tokens ensures gradients are only derived from response tokens, which teaches the model to generate answers rather than repeat instructions. Duplicating prompts, extending sequence length, or shuffling pairs do not address the loss computation.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Shuffle the dataset so prompts and responses are randomly paired during training.
Why it's wrong here
Randomly pairing prompts and responses destroys the instruction-response relationship and would teach the model meaningless associations. It does not prevent prompt echoing and would severely degrade fine-tuning quality. Data shuffling is useful for order randomization, not for controlling loss targets.
- ✗
Increase the maximum sequence length so the prompt and response always fit in a single sample.
Why it's wrong here
Sequence length affects truncation and context capacity, not which tokens contribute to the loss. Even with a longer sequence, the model would still be trained on prompt tokens if no mask is applied. This change does not address the root cause of the model echoing the prompt.
- ✗
Duplicate the prompt in both the input and output fields to reinforce the instruction format.
Why it's wrong here
Duplicating the prompt in the output teaches the model to generate the prompt before the answer, which is exactly the behavior to avoid. It also wastes context window space and can confuse the model about the expected response structure. This practice worsens the problem rather than solving it.
- ✓
Use a loss mask that excludes prompt tokens so the model is trained only on response tokens.
Why this is correct
A loss mask sets the loss contribution of prompt tokens to zero, so the model is optimized only on the response tokens. This prevents the model from learning to reproduce the prompt as output. In NeMo, this is handled through the data configuration and tokenizer settings that mark which tokens contribute to the loss.
About these practice questions
One of 352 original NCP-GENL 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 and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed September 2026 · checked against the official NVIDIA exam blueprint
This NCP-GENL practice question is part of Courseiva's free NVIDIA 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 NCP-GENL exam.