Skip to content
Ho Dinh Tri
Writing

Short note

Notes on Reliable AI Systems: Measuring Fluency vs Correctness

Synthetic data that read naturally held the wrong type of value in most slots. Fluency is judged by reading; correctness needs checks in code.

Short note2 min read

Observation#

In the Meddies-PII v3 pipeline, synthetic clinical documents have typed slots, such as a patient's tax ID or a clinic's record number, and a provider fills each one. A filled slot only has to read naturally in its sentence to look right to a reviewer skimming samples.

When each value was checked against the type its slot asked for, the old provider failed badly. Only 43.6% of Vietnamese slots and 36.1% of English ones held a value of the right type. A generic number sat where a tax ID belonged; a hospital name sat where a record code belonged. The text was fluent. The data was wrong more often than it was right.

After switching to meddies-faker, the same check gave 99.7% and 99.6%.

Analysis#

Fluency and correctness are measured by different things.

  • Fluency is judged by reading. A human skimming samples, or an LLM judge, sees whether the text flows. Both are good at that, and both are easy to satisfy: anything plausible passes.
  • Correctness lives in constraints the reader doesn't check. Is this a valid Vietnamese mobile number? Is this ZIP code in the state the address claims? Does this ID's checksum hold? Does the span's offset point at exactly the name? None of these show up when you read the text.

So a system can improve on everything a reviewer sees while staying wrong on what matters. For training data this is worse than it sounds: a model learns the wrong values with full confidence, because nothing in the text tells it they're wrong.

The same pattern shows up beyond data generation. An LLM's answer can be well written and cite the right kind of source while the number in it is invented.

Rule of thumb#

  • Write down the constraints before you look at samples. For each field: what makes a value valid? A format, a checksum, a range, a relation to another field.
  • Check them in code, on every record. Deterministic checks are cheap, repeatable and don't get tired. In v3, every span is re-checked against the text, and the audit reports 0 offset mismatches.
  • Use reading, and LLM judges, for what code can't check: tone, realism, whether a document makes clinical sense. Not as the measure of correctness.
  • Keep the checks honest. If the people who built the generator also wrote the checks, the checks share their blind spots. A blind human review, and ultimately a model trained on the data and tested on real text, are the stronger tests.

Short note2 min read

How I Read AI Security Papers as a Student

A reproduction that landed eight points below the paper taught me to read results before explanations, and to treat every number as a measurement under conditions.

AI SecurityLearning Notes
Back to Writing