Correct Answer: To discover actions with better rewards
Explanation:
Exploration allows the agent to test actions that could produce higher rewards than its current choices.
Incorrect! Try again.
15What is reward shaping?
Reward shaping
Easy
A.Removing all feedback from the environment
B.Converting rewards into training instructions
C.Adding guidance through modified reward signals
D.Changing the model's physical hardware
Correct Answer: Adding guidance through modified reward signals
Explanation:
Reward shaping adds or modifies reward signals to guide an agent toward desired behavior.
Incorrect! Try again.
16Why is reward shaping often used during agent training?
Reward shaping
Easy
A.To make every action equally valuable
B.To provide more frequent learning guidance
C.To replace the environment with a dataset
D.To prevent the agent from observing states
Correct Answer: To provide more frequent learning guidance
Explanation:
Reward shaping can provide intermediate feedback when the original reward is sparse or delayed.
Incorrect! Try again.
17What can happen if a shaped reward is poorly designed?
Reward shaping
Easy
A.The model will automatically increase precision
B.The environment will lose all possible states
C.The agent will always find the ideal policy
D.The agent may exploit unintended shortcuts
Correct Answer: The agent may exploit unintended shortcuts
Explanation:
A poorly designed reward can encourage unintended behavior that earns reward without achieving the true goal.
Incorrect! Try again.
18What type of information do humans commonly provide when guiding an agent through feedback?
Learning from human feedback for agent behavior
Easy
A.Preferences between possible responses
B.Hardware instructions for memory allocation
C.Random changes to model architecture
D.Exact values for every model weight
Correct Answer: Preferences between possible responses
Explanation:
Humans often rank or compare responses to show which behavior is more helpful or appropriate.
Incorrect! Try again.
19What is the role of a reward model in learning from human feedback?
Learning from human feedback for agent behavior
Easy
A.To predict which outputs humans prefer
B.To store the entire internet locally
C.To tokenize every prompt twice
D.To select the model's numeric precision
Correct Answer: To predict which outputs humans prefer
Explanation:
A reward model learns from human preferences and assigns scores that guide the agent's behavior.
Incorrect! Try again.
20What is a common goal of learning from human feedback?
Learning from human feedback for agent behavior
Easy
A.Aligning agent behavior with human preferences
B.Increasing model size after every response
C.Replacing language data with random values
D.Removing all safety constraints from the agent
Correct Answer: Aligning agent behavior with human preferences
Explanation:
Human feedback helps train an agent to produce behavior that better matches human preferences and expectations.
Incorrect! Try again.
21A model fine-tuned only on a small customer-support dataset becomes less capable on general language tasks. Which strategy most directly reduces this problem?
Supervised fine-tuning and instruction tuning
Medium
A.Increase the learning rate throughout all training epochs
B.Remove instruction prompts from the fine-tuning examples
C.Train repeatedly on the smallest support-data category
D.Mix representative general examples into the fine-tuning data
Correct Answer: Mix representative general examples into the fine-tuning data
Explanation:
Mixing general examples with task-specific data helps reduce catastrophic forgetting while preserving adaptation to customer support.
Incorrect! Try again.
22During instruction tuning, each training example contains an instruction, optional context, and target response. Which tokens should usually contribute most directly to the supervised loss?
Supervised fine-tuning and instruction tuning
Medium
A.Primarily the tokens in the target response
B.Only padding tokens after the target response
C.Primarily separator tokens between sequence fields
D.Only instruction tokens before the context
Correct Answer: Primarily the tokens in the target response
Explanation:
Response-token loss trains the model to generate the desired answer while treating the instruction and context primarily as conditioning input.
Incorrect! Try again.
23Two instruction-tuning datasets give conflicting answers to nearly identical prompts. What is the most appropriate action before training?
Supervised fine-tuning and instruction tuning
Medium
A.Increase generation temperature during model training
B.Resolve conflicts using a consistent annotation policy
C.Duplicate both answers to increase their frequency
D.Randomly remove half of all training prompts
Correct Answer: Resolve conflicts using a consistent annotation policy
Explanation:
A consistent annotation policy reduces contradictory supervision that would otherwise make the desired behavior unclear.
Incorrect! Try again.
24A team wants to estimate whether instruction tuning generalizes to unseen user requests. Which evaluation split is most informative?
Supervised fine-tuning and instruction tuning
Medium
A.Training responses evaluated without their original prompts
B.Unseen prompts representing the intended task distribution
C.Training prompts repeated with shuffled answer order
D.Random tokens sampled from the model vocabulary
Correct Answer: Unseen prompts representing the intended task distribution
Explanation:
A held-out set of realistic, unseen instructions measures generalization better than reused training examples or unrelated tokens.
Incorrect! Try again.
25A LoRA adapter uses updates of the form . What is the main effect of increasing the rank ?
Parameter-efficient techniques (LoRA)
Medium
A.It changes every base-model weight into an integer
B.It freezes more layers in the original transformer
C.It reduces adapter capacity and trainable parameter count
D.It increases adapter capacity and trainable parameter count
Correct Answer: It increases adapter capacity and trainable parameter count
Explanation:
A larger rank allows to represent more complex weight updates, but it also requires more trainable parameters and memory.
Incorrect! Try again.
26A service must switch rapidly among adapters for legal, medical, and technical tasks while sharing one base model. Which deployment design best supports this?
Parameter-efficient techniques (LoRA)
Medium
A.Combine all adapters into random transformer layers
B.Delete the base weights after training each adapter
C.Load one shared base model and swap task adapters
D.Retrain a separate base model for every request
Correct Answer: Load one shared base model and swap task adapters
Explanation:
LoRA adapters are small and task-specific, so multiple adapters can share the same frozen base model and be selected as needed.
Incorrect! Try again.
27Before exporting a model with one fixed LoRA adapter, the team merges the adapter into the base weights. What is the primary deployment benefit?
Parameter-efficient techniques (LoRA)
Medium
A.It removes separate adapter operations during inference
B.It permits switching adapters without storing their weights
C.It restores the base model to random initialization
D.It automatically converts all weights to four bits
Correct Answer: It removes separate adapter operations during inference
Explanation:
Merging applies the learned low-rank update to the base weights, eliminating the need to execute separate adapter branches.
Incorrect! Try again.
28LoRA is applied to attention projection matrices while the base model remains frozen. Which parameters receive gradient-based updates?
Parameter-efficient techniques (LoRA)
Medium
A.Only the tokenizer's fixed vocabulary identifiers
B.The low-rank adapter matrices attached to projections
C.Every parameter in the frozen transformer backbone
D.Only the optimizer's non-trainable configuration values
Correct Answer: The low-rank adapter matrices attached to projections
Explanation:
LoRA trains its added low-rank matrices while keeping the original model weights unchanged.
Incorrect! Try again.
29Ignoring metadata and scaling factors, approximately how does converting model weights from FP32 to INT8 affect weight storage?
Quantization for deployment
Medium
A.It leaves storage approximately unchanged
B.It reduces storage to about one half
C.It reduces storage to about one eighth
D.It reduces storage to about one quarter
Correct Answer: It reduces storage to about one quarter
Explanation:
FP32 uses 32 bits per weight, while INT8 uses 8 bits, so raw weight storage becomes approximately as large.
Incorrect! Try again.
30A post-training quantized model loses substantial accuracy because a few activation values are extreme outliers. Which response is most appropriate?
Quantization for deployment
Medium
A.Increase the tokenizer vocabulary without recalibration
B.Use calibrated ranges or selective higher-precision operations
C.Map every activation to one shared integer value
D.Remove all scaling factors from quantized computations
Correct Answer: Use calibrated ranges or selective higher-precision operations
Explanation:
Calibration and mixed-precision handling can prevent outliers from forcing ranges that represent most activation values poorly.
Incorrect! Try again.
31A model must run at low precision, but post-training quantization causes unacceptable degradation. Which technique can adapt the model to simulated quantization error?
Quantization for deployment
Medium
A.Instruction tuning without any quantization simulation
B.Reward shaping with a constant terminal reward
C.Tokenization-aware decoding with unlimited precision
D.Quantization-aware training with fake quantization
Correct Answer: Quantization-aware training with fake quantization
Explanation:
Quantization-aware training simulates low-precision effects during training, allowing weights to adapt to rounding and clipping errors.
Incorrect! Try again.
32For a Q-learning update, let , , , , and . What is the updated value?
Reinforcement learning foundations (Q-learning basics)
Medium
A.
B.
C.
D.
Correct Answer:
Explanation:
Using gives .
Incorrect! Try again.
33An agent receives reward and enters a terminal state. If and , what is the updated value when terminal states have no bootstrap value?
Reinforcement learning foundations (Q-learning basics)
Medium
A.
B.
C.
D.
Correct Answer:
Explanation:
The terminal target is , so the update is .
Incorrect! Try again.
34A Q-learning agent uses an -greedy policy. If is reduced too quickly near the start of training, what is the most likely consequence?
Reinforcement learning foundations (Q-learning basics)
Medium
A.The agent may exploit poor actions before exploring alternatives
B.The agent will update every action with identical rewards
C.The environment will become fully deterministic during training
D.The discount factor will automatically increase above one
Correct Answer: The agent may exploit poor actions before exploring alternatives
Explanation:
Rapidly reducing limits exploration, so early and inaccurate Q-values may cause the agent to settle on suboptimal behavior.
Incorrect! Try again.
35Which shaping reward is known to preserve the optimal policy under standard conditions when added to the environment reward?
Reward shaping
Medium
A.
B.
C.
D.
Correct Answer:
Explanation:
Potential-based shaping of the form changes learning signals without changing the optimal policy under standard assumptions.
Incorrect! Try again.
36A delivery agent earns a small reward whenever it moves closer to a package. It learns to oscillate between two locations and repeatedly collect reward. What does this demonstrate?
Reward shaping
Medium
A.Quantization error caused by low-precision activations
B.Reward hacking caused by an exploitable shaping signal
C.Policy preservation caused by terminal-state bootstrapping
D.Catastrophic forgetting caused by supervised fine-tuning
Correct Answer: Reward hacking caused by an exploitable shaping signal
Explanation:
The agent is maximizing the specified intermediate reward through unintended behavior rather than completing the intended delivery task.
Incorrect! Try again.
37A navigation task gives a reward only when the destination is reached, so successful experiences are rare. Which shaping approach is most useful?
Reward shaping
Medium
A.Penalize the agent only after successful episodes
B.Remove all observations related to the destination
C.Add progress rewards based on reduced goal distance
D.Replace every reward with the same positive constant
Correct Answer: Add progress rewards based on reduced goal distance
Explanation:
A progress signal supplies denser feedback, helping the agent discover behaviors that lead toward the sparse terminal reward.
Incorrect! Try again.
38Human reviewers consistently choose the better of two agent trajectories. How is this feedback commonly converted into a trainable learning signal?
Learning from human feedback for agent behavior
Medium
A.Copy every preferred trajectory into the tokenizer vocabulary
B.Assign rewards using only each trajectory's token count
C.Quantize both trajectories and compare their memory sizes
D.Train a reward model to predict pairwise preferences
Correct Answer: Train a reward model to predict pairwise preferences
Explanation:
A reward model can learn from pairwise rankings and then score new agent behavior during policy optimization.
Incorrect! Try again.
39During feedback-based policy optimization, an agent begins producing unnatural outputs that score highly under the learned reward model. Which technique most directly limits excessive policy drift?
Learning from human feedback for agent behavior
Medium
A.Remove the reference model from all evaluations
B.Increase reward-model scores by a fixed constant
C.Train only on the highest-scoring generated token
D.Add a KL penalty relative to a reference policy
Correct Answer: Add a KL penalty relative to a reference policy
Explanation:
A KL penalty discourages the optimized policy from moving too far from a stable reference, reducing reward-model exploitation and behavioral drift.
Incorrect! Try again.
40An assistant can call external tools, and reviewers care about both answer correctness and safe tool use. What should the preference data contain?
Learning from human feedback for agent behavior
Medium
A.Complete trajectories showing answers and tool-call decisions
B.Only tool names without arguments or resulting observations
C.Random prompts without reviewer comparisons or ratings
D.Only final answers with all tool actions removed
Correct Answer: Complete trajectories showing answers and tool-call decisions
Explanation:
Trajectory-level feedback exposes the reward model to both final outcomes and intermediate tool behavior, enabling it to learn the reviewers' full preferences.
Incorrect! Try again.
41An instruction-tuning dataset concatenates multiple examples into each fixed-length sequence. Which attention and loss configuration best prevents unintended cross-example learning?
Supervised fine-tuning and instruction tuning
Hard
A.Use causal attention globally and compute loss on every response and padding token
B.Use causal attention globally and compute loss only on each example's instruction tokens
C.Use block-diagonal attention and compute loss only on each example's response tokens
D.Use bidirectional attention and compute loss on every non-padding token
Correct Answer: Use block-diagonal attention and compute loss only on each example's response tokens
Explanation:
Block-diagonal attention prevents one packed example from conditioning on another, while response-only masking trains the desired conditional behavior rather than reproducing prompts.
Incorrect! Try again.
42A model is fine-tuned with teacher forcing and obtains low token-level validation loss, but its long generated answers frequently drift after an early mistake. Which explanation best accounts for this discrepancy?
Supervised fine-tuning and instruction tuning
Hard
A.Teacher forcing evaluates predictions under gold prefixes rather than model-generated prefixes
B.Teacher forcing optimizes sequence-level accuracy rather than token-level likelihood
C.Teacher forcing removes causal masking from response tokens during optimization
D.Teacher forcing trains recovery only from prefixes sampled by the model itself
Correct Answer: Teacher forcing evaluates predictions under gold prefixes rather than model-generated prefixes
Explanation:
At inference, an erroneous token changes later inputs, creating exposure bias. Validation under gold prefixes may therefore underestimate autoregressive error accumulation.
Incorrect! Try again.
43Two instruction datasets contain identical response tokens, but one repeats long prompts before every response. Training loss is averaged over all non-padding tokens without prompt masking. What is the most likely consequence?
Supervised fine-tuning and instruction tuning
Hard
A.All examples retain equal influence because token averaging normalizes each sequence
B.Prompt length affects memory use but cannot affect the optimization objective
C.Short-prompt examples receive disproportionate influence through response-only gradients
D.Long-prompt examples receive disproportionate influence through prompt-reconstruction gradients
Correct Answer: Long-prompt examples receive disproportionate influence through prompt-reconstruction gradients
Explanation:
Without prompt masking or per-example normalization, long prompts contribute more supervised tokens and therefore more aggregate gradient signal.
Incorrect! Try again.
44For multi-turn assistant fine-tuning, the loss is applied to every assistant turn but masked on system and user turns. What behavior does this objective directly train?
Supervised fine-tuning and instruction tuning
Hard
A.Reconstruct the complete dialogue using bidirectional context from later turns
B.Predict each user turn conditioned only on the preceding assistant response
C.Predict each assistant turn conditioned on all preceding visible conversation tokens
D.Optimize only the final assistant turn while treating earlier turns as labels
Correct Answer: Predict each assistant turn conditioned on all preceding visible conversation tokens
Explanation:
Causal attention exposes prior system, user, and assistant tokens as context, while the mask makes assistant tokens the supervised targets.
Incorrect! Try again.
45A frozen linear layer has . LoRA represents its update as with rank . Ignoring biases, how many trainable parameters are added?
Parameter-efficient techniques (LoRA)
Hard
A.
B.
C.
D.
Correct Answer:
Explanation:
The two factors have shapes and , so their parameter counts add.
Incorrect! Try again.
46Two independently trained rank- LoRA adapters for the same frozen layer are merged by adding both updates. What is the tightest general upper bound on the rank of the combined update?
Parameter-efficient techniques (LoRA)
Hard
A.
B.
C.
D. regardless of
Correct Answer:
Explanation:
Rank is subadditive: . It may be smaller when the adapters' row or column spaces overlap.
Incorrect! Try again.
47A LoRA implementation uses . If rank changes from to while and the typical scale of entries in and remain fixed, what is the purpose of the divisor ?
Parameter-efficient techniques (LoRA)
Hard
A.It exactly preserves the matrix rank of the update
B.It guarantees identical gradients for every possible rank
C.It moderates update magnitude as more rank components are added
D.It converts the low-rank update into an orthogonal projection
Correct Answer: It moderates update magnitude as more rank components are added
Explanation:
Scaling by limits the growth of the aggregate adapter contribution as rank increases; it does not guarantee exact invariance.
Incorrect! Try again.
48A weight matrix contains a few extreme outlier values confined to certain output channels. Under the same bit width, which scheme should usually reduce quantization error most effectively?
Quantization for deployment
Hard
A.One symmetric scale shared by the entire model
B.One affine scale shared by the entire matrix
C.A single scale estimated only from the median weight
D.Separate scales for individual channels or small groups
Correct Answer: Separate scales for individual channels or small groups
Explanation:
Finer-grained scales isolate outlier ranges, allowing ordinary channels to use more of the available integer resolution.
Incorrect! Try again.
49Post-training activation quantization is calibrated only on short, formal prompts, but deployment uses long conversational prompts. What is the central technical risk?
Quantization for deployment
Hard
A.Deployment activations may exceed calibrated ranges and undergo clipping
B.Deployment weights will change because activation scales are recalculated
C.Long prompts necessarily increase the numerical precision of each activation
D.Conversational tokens cannot be represented by the original tokenizer
Correct Answer: Deployment activations may exceed calibrated ranges and undergo clipping
Explanation:
Calibration data must represent deployment distributions. A range mismatch can cause excessive clipping or poor use of quantization levels.
Incorrect! Try again.
50An autoregressive decoder stores key-value tensors for every generated token. Which change most directly reduces KV-cache memory growth while leaving model weights unchanged?
Quantization for deployment
Hard
A.Merge LoRA adapters into the frozen projection weights
B.Quantize cached keys and values to a lower bit width
C.Quantize only the embedding matrix to a lower bit width
D.Increase the group size used for weight quantization
Correct Answer: Quantize cached keys and values to a lower bit width
Explanation:
KV-cache memory scales with sequence length, layers, and cache precision. Lowering cache precision directly reduces its per-token memory cost.
Incorrect! Try again.
51For a non-terminal transition , tabular Q-learning uses learning rate and discount . Which update is correct?
Reinforcement learning foundations (Q-learning basics)
Hard
A.
B.
C.
D.
Correct Answer:
Explanation:
Q-learning moves the current estimate toward the one-step target .
Incorrect! Try again.
52A transition ends an episode because the agent reaches a genuine terminal state and receives reward . What target should standard Q-learning use for that transition?
Reinforcement learning foundations (Q-learning basics)
Hard
A.
B.
C.
D.
Correct Answer:
Explanation:
A genuine terminal state has no future return, so its bootstrap contribution is zero. Time-limit truncations may require different handling.
Incorrect! Try again.
53Why can the operator in noisy Q-learning estimates cause systematic overestimation?
Reinforcement learning foundations (Q-learning basics)
Hard
A.It forces all state-action values to converge to the same fixed point
B.It tends to select actions whose estimation errors are unusually positive
C.It removes rewards associated with actions not chosen by the behavior policy
D.It averages positive and negative estimation errors before action selection
Correct Answer: It tends to select actions whose estimation errors are unusually positive
Explanation:
Maximization couples action selection with noisy evaluation, preferentially choosing positive errors. Double Q-learning separates these roles to reduce the bias.
Incorrect! Try again.
54An LLM agent observes only the latest user message, while optimal action choice depends on an unobserved earlier constraint. Why may tabular Q-learning on the latest message fail even with unlimited visits?
Reinforcement learning foundations (Q-learning basics)
Hard
A.The observation aliases histories requiring different optimal actions
B.Off-policy updates require rewards to be differentiable functions
C.The discount factor prevents learning from any delayed reward
D.Q-learning cannot represent deterministic policies in finite action spaces
Correct Answer: The observation aliases histories requiring different optimal actions
Explanation:
The latest message is not a Markov state: identical observations can correspond to different latent histories and therefore different optimal actions.
Incorrect! Try again.
55In a discounted MDP, which shaping reward preserves the set of optimal policies under the standard potential-based shaping result?
Reward shaping
Hard
A.
B.
C.
D.
Correct Answer:
Explanation:
Potential-based shaping with the same discount factor changes returns by a telescoping potential term without changing optimal action preferences.
Incorrect! Try again.
56An agent receives each time it calls a diagnostic tool and for completing the task. It learns to call the tool repeatedly without finishing. Which redesign best addresses the reward-hacking mechanism?
Reward shaping
Hard
A.Remove the completion reward but retain the per-call reward
B.Increase the reward for every diagnostic tool call equally
C.Increase the discount factor while leaving rewards unchanged
D.Reward verified information gain and penalize redundant tool calls
Correct Answer: Reward verified information gain and penalize redundant tool calls
Explanation:
The original proxy rewards activity rather than progress. Tying reward to verified novelty and charging for repetition better aligns incentives with task completion.
Incorrect! Try again.
57A designer applies while the learner discounts returns using . What guarantee is generally lost?
Reward shaping
Hard
A.Existence of any finite state-action value function
B.Preservation of the original MDP's optimal policies
C.Convergence of every policy to uniform random actions
D.Ability to represent rewards using scalar values
Correct Answer: Preservation of the original MDP's optimal policies
Explanation:
The telescoping policy-invariance argument requires the shaping term to use the learner's discount factor. A mismatch can alter action rankings.
Incorrect! Try again.
58A preference model uses . Which transformation of leaves every predicted preference probability unchanged?
Learning from human feedback for agent behavior
Hard
A. for a constant
B. for every completion
C. for every completion
D. for every completion
Correct Answer: for a constant
Explanation:
Pairwise probabilities depend only on reward differences, so adding a shared constant cancels. Scaling generally changes preference confidence.
Incorrect! Try again.
59An RLHF objective maximizes . What is the primary role of the KL term?
Learning from human feedback for agent behavior
Hard
A.Eliminate all sampling variance from policy-gradient estimates
B.Constrain policy drift from the reference while optimizing learned reward
C.Force the policy to assign equal probability to every response
D.Guarantee that the learned reward equals true human utility
Correct Answer: Constrain policy drift from the reference while optimizing learned reward
Explanation:
The KL penalty regularizes updates toward the reference policy, reducing extreme distribution shifts and exploitation of reward-model errors.
Incorrect! Try again.
60Human raters evaluate only final outcomes of long agent trajectories, but many intermediate tool decisions affect success. Which learning challenge is most directly created?
Learning from human feedback for agent behavior
Hard
A.Matrix-rank selection for the reward model's adapters
B.Tokenization ambiguity in the human preference labels
C.Temporal credit assignment across intermediate actions
D.Integer overflow in the policy's quantized embeddings
Correct Answer: Temporal credit assignment across intermediate actions
Explanation:
A trajectory-level judgment gives sparse information about which earlier actions caused the outcome, making behavioral improvement difficult without decomposition or better feedback.
Incorrect! Try again.
Did this save you a night before the exam?
LPU Notes is free, and it stays free. Ads cover part of the server bill.
The rest comes out of a student's own pocket: the domain, the storage,
and keeping the site up through the weeks everyone needs it at once.
The payment button didn't load. An ad blocker or a filtered network is the usual reason.
to try again.
Nothing here is ever locked, and nothing unlocks. Chip in only if it was worth it.
What it pays for →