Sarvam launched a document extraction API on 24 November. Every value it returns comes with the page it came from, a bounding box and a confidence score. I like that design, because the hard part of extraction is rarely the values that are there. It's the values that aren't, and the values that are there but mean something else.
My problem is smaller and not about documents, but it's the same question. My WhatsApp assistant pulls promises out of my chats, with a due date when I gave one. The parser that turns the due phrase into a date has this comment at the top:
A missing due is strictly better than a guessed one — a false "overdue" shows first in !today and is the fastest way to lose the user's trust.
I added that rule in June and never measured it. So I built a small test: what does a model do with a date field when the message has no date?
The setup
46 short synthetic chats. In each, someone asks me for something and I promise to do it. The system prompt says today is Tuesday, 1 December 2026, in India; every right answer is counted from that day.
-
18 promises with a due date. Eight absolute (
by 5 Dec,on the 10th,15/12 tak bhej dunga) and ten relative (tomorrow,kal pakka kar dunga,by Friday,in 2 weeks,by EOD). - 10 with no time at all. "Sure, will send." "Main dekh lunga."
-
8 with a rough time but no calendar day.
soon,jaldi,sometime next week,next month,after the holidays,early next week. - 10 with a date nearby that isn't the due date. "The invoice dated 28 Nov is still unpaid" / "Sorry, I'll pay it." Two of these have the date in my own message: "Got the 28 Nov invoice, I'll pay it".
So 18 chats name a due day and 28 don't. Same model, same chats, four setups:
-
Date required.
"due": the due date as YYYY-MM-DD. -
Date or null. The same, plus
or null if I did not give a due date. - Date or null, plus a quote check. The model also returns the exact words from my message that give the date. Code keeps the date only if those words really are in a message I sent.
-
Phrase, plus my bot's parser. The wording from my assistant's prompt,
a due date or time if mentioned, else null, then the parser from my bot turns the phrase into a date. Anything it doesn't recognise becomes no date.
"Required" here means the prompt asks for a date. There's no JSON schema or structured output mode in any setup; the only thing that changes between setups 1 and 2 is that one clause in the prompt. Setups 3 and 4 change the prompt and the code after it.
I committed the chats, labels and grader before the first run, then ran each setup three times on 1 December on openai/gpt-oss-120b through Groq, with Groq's default settings (no temperature or reasoning level set). Code scores every answer: right date, wrong date, missed, right null or invented.
Results
| Setup | Right dates (of 18) | Wrong or missed dates | Invented dates (of 28 with none) | Invented, all runs (of 84) |
|---|---|---|---|---|
| Date required | 18, 18, 18 | 0, 0, 0 | 27, 26, 27 | 80 |
| Date or null | 18, 18, 18 | 0, 0, 0 | 1, 3, 1 | 5 |
| Date or null + quote check | 18, 18, 18 | 0, 0, 0 | 0, 3, 1 | 4 |
| Phrase + my bot's parser | 17, 18, 18 | 1, 0, 0 | 1, 0, 1 | 2 |
Each setup had 84 chances to invent a date: 28 chats, three runs. The required date took 80 of them.
The real dates were never the problem. Every setup got 15/12 tak, kal and by Friday right in every run. Almost all the differences are in the 28 chats with no date; the one exception is a real date the parser setup missed in run 1, which I'll come to.
A required date is today
Asked for a date every time, the model gave one almost every time. Across three runs it invented 80 dates, and 66 of them were 1 December, today. The medicines, the repo link, the dentist, the call back, the unpaid invoice: all due today.
The other 14 were precise dates too: 12 from vague words, and 2 from a birthday that had already passed. sometime next week became 8, 11 or 13 December, depending on the run. after the holidays became 27 December or 2 January. "Mom's birthday was on the 29th and you forgot!" made the gift due on 29 December in two runs.
The only chat it left empty in every run was "I'll come once things settle down".
I expected false dates in the past, the overdue items my comment warns about. That's not what happened. A required field mostly fills with today, so almost every promise looks due today. That's a quieter failure, but it would still bury the three promises in this set that really are due today.
Allowing null did most of the work
Adding or null if I did not give a due date took the invented dates from 26 or 27 down to 1 to 3 per run. One extra clause in the prompt.
What was left was nearly all vague words. early next week became 7 or 9 December in every run. next month became 1 January once. And once, "Haan, I'll pick them up" became due today.
The quote check checked the wrong thing
This is the result I didn't expect. The check itself rejected nothing, in any run. Its first run has one fewer invented date than the date or null setup, but that's a separate model call answering differently, not the check catching anything.
Every date the model kept came with words that really were in my message, 58 of them across three runs. The invented ones quoted next month and early next week correctly. In run 2 it quoted 28 Nov from "Got the 28 Nov invoice, I'll pay it" and made the payment due on 28 November, three days before I promised it. That was the only invented date in the past across all twelve setup runs.
The check proves where the words came from. It doesn't prove the words are a due date. Sarvam's page and bounding box work the same way for documents: they tell a reviewer where to look, and someone still has to look. Its confidence score goes further. Sarvam says values get lower scores when they fail its validation checks or a second read disagrees. That's a useful signal for what to review, but it still isn't proof that a value means what the field says.
My check also has a rule that's too strict for real chats: the quote must come from my own message. "Can you send it by Friday?" / "Sure" is a promise due on Friday, with the date in the other person's message. None of my 46 chats has that shape, so this test doesn't show the cost, but a real version should tie the date to the right message in the conversation, not only to mine.
My bot's parser almost never got a phrase
My bot's design depends on one assumption: the model hands over the phrase, and code decides whether it's a date. Code is strict, so next month and soon fail closed.
The model didn't hand over phrases. Asked for "a due date or time if mentioned", it answered with a date every single time: 55 times as YYYY-MM-DD and once as a full timestamp, 2026-12-01T23:59:00+05:30, for "Sending them tonight". The parser doesn't read timestamps, so it failed closed and missed a real date. Meanwhile early next week arrived already converted to 2026-12-07, and the parser accepted it like any other date.
So the parser did exactly what it was built to do, and it barely mattered. The model had already made the decision the parser was supposed to make.
The flip side shows up when the parser gets the raw words. In this run, kal and 15/12 tak reached it as dates the model had already worked out. When I fed it the quoted words from setup 3 instead, it rejected 10 of the 18 real dates in every run, because it can't read 5 Dec, 15/12, on the 10th or kal. The model was doing the interpreting, not my parser.
One difference matters here. This demo tells the model today's date. My bot's prompt doesn't state it, though every message it sends carries a Unix timestamp, so the model there has a date to anchor on too. I haven't tested whether that changes how often it converts phrases itself.
What I'd change
- Never make a date field required. If the source might not have the value, the schema has to allow null. That one clause did more than everything else I tried.
- Split the job in three. The model extracts: the due phrase exactly as written, the quote and the message it came from, with no conversion. Code interprets: it turns the phrase into a date using that message's timestamp and timezone, and returns nothing when the phrase is ambiguous. The user confirms: anything inferred stays a suggestion. My bot already has that shape, but its prompt never says not to convert. I haven't tested whether saying so fixes it.
-
Check what the quote says, not just where it is. A quote that exists is not a quote that means a date. Passing each quote through my parser drops every invented date, and also 10 of the 18 real ones. As it stands, that trades invented dates for missed ones, so the parser needs
5 Dec,15/12andkalfirst. - Tie the date to the promise. A date in the same conversation isn't necessarily the date of the thing I promised. The 28 Nov invoice is the example.
- Show the date as a suggestion until someone confirms it. FixPoint Drive already does this. Sahil's backend extracts a date from a document, and it stays a suggestion until the owner accepts or corrects it with the review controls I built, like "Use this date" on the home screen.
What this doesn't prove
These are 46 chats I wrote myself, with labels I wrote, knowing what each setup does. Real promises are messier, and a different set could move these numbers. It's one model, three runs on one day, under a model name a provider can update.
Some labels are judgement calls. I labelled sometime next week, early next week and next month as no due date, meaning no calendar day, not no time at all. A rough window could still be useful for a suggested reminder; this test only asks whether the model invents an exact deadline. "Haan, I'll pick them up", after "Bring the medicines on the way back", probably does mean today, and "Sorry, I'll call back" and "On it, I'll fix it" lean that way too. I labelled them no date because I didn't say when. I'd still rather code decide those defaults than the model.
The setups differ only in the prompt and the code after it, but the quote check asks for one more field, which may change how the model answers the first one. And my bot's real prompt asks for a list of promises with evidence fields, not a single object.
What it does show: a required date gets filled, mostly with today. Allowing null fixed nearly all of it. And a check on where an answer came from is not a check on whether the answer is right.
The code, chats and all three runs are in shipping-with-ai/05-null-beats-a-guess.

Top comments (0)