A team needs the same output for the same prompt every time, for audit. Which decoding choice fits?
- Exam domain
- LLM capabilities and limitations
- Difficulty
- Hard
- In this mock
- 5 questions on this domainPractise this domain
Why C is the answer
Greedy decoding
Greedy decoding always takes the most likely next token, so the same prompt and model give the same output, which suits repeatable results.
Remember: Repeatable means greedy.
In detail
- Greedy: repeatable.
- Sampling: varied.
Every option, checked
Knowing why each wrong option fails is how you rule it out on exam day.
A. Sampling with top-k set to 100Wrong
A large top-k keeps many candidates, so outputs vary.
B. Sampling with a new random seed on each call, which gives every run a fair chanceWrong
A new seed each call changes the result.
C. Greedy decodingRight
Repeatable means greedy.
D. Sampling with a high temperatureWrong
A high temperature adds variety.
Use case
An illustrative scenario, not a real incident.
Illustrative: a claims extractor uses greedy decoding so a re-run during an audit matches the original.
See it in different ways
flowchart TD
Q{"Do you need repeatable output?"}
Q -->|"Yes"| A0["Greedy decoding"]
Q -->|"No, want variety"| A1["Sampling"]How to read this chart
- At "Do you need repeatable output?": if "Yes", go to "Greedy decoding"; if "No, want variety", go to "Sampling".
stateDiagram-v2 state "Sampling" as s0 state "Varied outputs" as s1 state "Greedy" as s2 state "Same output" as s3 [*] --> s0 s0 --> s1: random choice s2 --> s3: top token each step s1 --> [*] s3 --> [*]
How to read this chart
- It starts at "Sampling".
- From "Sampling", "random choice" moves it to "Varied outputs".
- From "Greedy", "top token each step" moves it to "Same output".
- It ends at "Varied outputs" or "Same output".