Mid

Why do LLMs hallucinate, and how do you reduce it?

How to answer it in an AI engineer interview: what is being tested, a step-by-step framework, a sample answer and the mistakes to avoid.

$19.99 on Gumroad, instant download40% off with code EARLYBF until Nov 3, 11:59 PM PTEARLYBF: 40% off until Nov 3

Smaller start: Score your answers against 50 rubrics, $9. 50 AI engineer questions, one rubric each, PDF on Gumroad.

Practiced one out loud? Paste your answer into the free self-check and get a score in 30 seconds

What the interviewer is testing

Whether you can explain the root cause in one sentence, give layered mitigations that a production system can actually use, and say how you would measure the problem rather than only describe it.

Answer framework

  1. Cause: the model is trained to produce plausible continuations, not to verify facts, and it has no built-in signal for what it does not know.
  2. Ground it: retrieve sources and ask for citations.
  3. Allow abstention: make "I don't know" an acceptable, rewarded answer.
  4. Constrain it: schemas and enumerations for outputs, lower temperature for factual tasks.
  5. Verify afterwards: check claims against the sources with an automated verifier.
  6. Measure it: split answers into claims and report the share supported by sources, plus citation checks.

Sample answer

The model is trained to produce plausible continuations, not to verify facts, and it has no built-in signal for what it does not know. So it will produce fluent text even when the answer is not supported.

I reduce it in layers: ground answers in retrieved sources and ask for citations; allow and reward an "I don't know" path; constrain outputs with schemas or enumerations; lower temperature for factual tasks; and check claims afterwards against the sources with an automated verifier.

To measure it, I break each answer into individual claims and check each against the provided sources with an NLI model or an LLM judge, then report the share of supported claims. I pair that with citation checks: does the cited passage actually contain the claim?

Likely follow-ups

How should a RAG system decide to say "I don't know"? Combine low retrieval or re-ranker scores below a calibrated threshold, no chunk that answers the question, and a verifier step that checks the draft answer against sources. Evaluate refusal precision as well as answer accuracy.

Common mistakes

The PlaybookWant the full method?

The 0 to 1 AI Engineer Interview Playbook covers the answer frameworks, system-design walkthroughs and an 8-week plan.

Get the playbook 40% off with code EARLYBF until Nov 3, 11:59 PM PTEARLYBF: 40% off until Nov 3

Smaller start: Score your answers against 50 rubrics, $9. 50 AI engineer questions, one rubric each, PDF on Gumroad.

Interviewing for PM or TPM? See the full PM package, $59 on Gumroad: a resume system, a PM, TPM and PGM interview handbook, a 1:1 cheat sheet and a PM playbook. PM and TPM content, not AI engineer prep.

Related questions

Based on question #14, #68, #33 in the full question bank.