Debugging a Candidate Selection Script
Based on the scenario described, what is the fundamental misunderstanding in the engineer's implementation, and which specific mathematical operator should they use to correct the code so it returns the best candidate text instead of its score?
0
1
Tags
Ch.5 Inference - Foundations of Large Language Models
Foundations of Large Language Models
Foundations of Large Language Models Course
Computing Sciences
Analysis in Bloom's Taxonomy
Cognitive Psychology
Psychology
Social Science
Empirical Science
Science
Related
A system generates four candidate text sequences to complete a prompt. A scoring function,
r(sequence), evaluates the quality of each candidate. The system uses theargmaxoperator to select the best one based on these scores:best_sequence = argmax(r(sequence_i)). Given the following candidates and their scores, what is the output of theargmaxoperation?- Candidate A: "The cat sat on the mat." (Score: 0.82)
- Candidate B: "A feline rested on the rug." (Score: 0.91)
- Candidate C: "The mat was under the cat." (Score: 0.75)
- Candidate D: "On the mat, a cat sat." (Score: 0.89)
Debugging a Candidate Selection Script
Distinguishing
maxandargmaxin Candidate Selection