Skip to content
ML Academy

LLMs, GenAI, RAG, agents, evaluation · insight-0528

Give every extracted field an explicit unknown value so the model is not forced to invent

Evidence type
practitioner heuristic
Difficulty
easy
Roles
Applied AI, ML engineer, Data analyst
Industries
aviation, insurance

Summary: situation, action, reason, boundary

  1. Situation

    An extraction schema requires a booking reference, a fare class and a travel date for every complaint email.

  2. Action

    Make fields nullable or add an explicit not-stated option, instruct the model to use it when the text lacks the value, and add eval cases where each field is genuinely missing.

  3. Reason

    Required fields with no way to say absent turn missing information into a generation task, which the model completes with plausible values.

  4. Boundary

    Document and email extraction, form filling, CRM enrichment.

Symptom or risk

Emails that never mention a fare class still produce one, because a required string must be filled, and the invented values look identical to real ones.

Exceptions

Fields that are always present by construction, such as a message ID supplied by your system, can stay strictly required.

Trade-offs

Nullable fields push missing-data handling downstream, which must then be designed.

Pitfalls

Measuring extraction accuracy only on emails where every field is present.

Example

In a synthetic test of 200 complaint emails, the fare-class field would be checked separately on the subset where the email never states a class; any non-null value there is an invention.

Lessons and concepts