Same topic, related formats. Practice these next.
Same topic, related formats. Practice these next.
A RAG product is shipping confident hallucinations whenever the retriever misses. Design an SFT recipe that teaches the model to refuse, i.e. say 'I don't have enough information in the provided context', when the retrieved chunks do not actually support an answer. Specify the data shape, how you construct positive vs negative examples, the balance between them, and at least one failure mode to watch.
Build matched (question, chunks, response) triples: half where chunks support the answer, half where chunks look related but do not, with templated refusals. Realistic negatives matter most.
Picture teaching a kid to say 'I don't know' when their notes do not cover a question. You quiz them with two kinds of cards. On half the cards, the notes do answer the question, and the kid is rewarded for using them. On the other half, the notes look related but actually do not answer it, and the kid is rewarded for saying 'these notes do not cover that'. The trick is the second pile has to look real. If you only quiz them with blank notes, they only learn to refuse when the page is empty, and they keep making things up whenever the page has any text on it. The realistic near-miss notes are what teach the actual signal.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example.
Everything important, quickly.
3 min: describe the triple shape, the two matched halves plus partial slice, the three negative-sourcing techniques, the templating discipline, and the precision-recall evaluation.
Real products, models, and research that use this idea.
What an interviewer would ask next. Try answering before peeking at the approach.
Red flags and common mistakes that signal junior thinking. Click to expand.
Sourcing negative examples as blank or wildly off-topic context. The model then learns to refuse only on those obvious shapes and keeps hallucinating on the subtle near-miss cases that actually hurt in production.
The night-before-the-interview bullets. Scan these on the way to the call.
Primary sources. Skim if you want the original framing.