A hallucination reads exactly like a correct answer. That is what makes it costly.
How it works
A language model writes the most plausible next tokens given its training and the prompt. Nothing in that loop checks a fact against the world. When the model lacks the answer, a plausible-looking one is still available.
Kalai and colleagues, in a 2025 paper, argue that hallucinations persist because “training and evaluation procedures reward guessing over acknowledging uncertainty.” Most benchmarks give credit for a right guess and nothing for abstaining, so models are tuned to be good test-takers. They also trace the errors to a statistical source: if a model cannot reliably tell true statements from false ones, pretraining will produce false ones.
Common forms in API work:
- invented citations, URLs or quotes
- wrong figures in a summary of a correct document
- API methods or parameters that do not exist
- answers to questions the provided context does not cover
Why it matters
The cost is downstream: a support bot that invents a refund policy, a report with a wrong total, code that calls a missing function. The fixes are cheap compared with that:
- Ground the answer. Put the source text in the prompt or retrieve it with RAG. Lewis and colleagues found retrieval-augmented generation more “factual” than a parametric-only baseline. See grounding.
- Allow “I don’t know”. Anthropic lists explicit permission to admit uncertainty as a basic step.
- Ask for quotes, then verify. Have the model cite a supporting quote for each claim and drop claims without one.
- Measure. Build an eval with questions that have no answer in the context, and track how often the model invents one. Logprobs can flag low-confidence answers where the API returns them.
- Check in code. Totals, dates and IDs can be verified without a model.
Lowering temperature helps with drift in long text, not with confident errors.
On BroadNet Inference
BroadNet’s docs do not publish hallucination rates for their models and do not list guardrails or fact-checking features, so these controls live in your application. A large context helps grounding: DeepSeek V4.1 Flash and GLM 5.3 accept 1,048,576 tokens per request, enough to include full source documents. For Arabic retrieval pipelines, see Arabic RAG; for checking extracted fields against the image, see the invoice guide.