Generating Synthetic Medical Records for High-Stakes Evals
AI Engineergo watch the original →
the gist
Anterior bypasses strict data retention contracts by reversing their inference pipeline, using symbolic decision trees to sample labels and reasoning traces that generate high-fidelity, synthetic medical records.
Reversing the Inference Pipeline
Anterior generates synthetic medical records by running their standard inference workflow in reverse. Instead of starting with unstructured fax data to reach a label, they sample a label first, derive a reasoning trace from an explicit symbolic decision tree, and then generate the medical record that would logically produce that outcome. This approach ensures that labels are correct by construction, eliminating the need for expensive ground-truthing and allowing the team to test edge cases that are rarely present in production data.
Coarse-to-Fine Generation
The generation pipeline follows a structured, multi-layer process to maintain token efficiency and ensure long-form consistency:
- Patient Invariants: The model generates foundational data such as biological sex, birth date, and blood group.
- Patient Journey: An LLM produces an ordered list of provider encounters and events based on the reasoning trace.
- Document Fanning: The system generates a document plan for each encounter, then fans out to create individual documents in parallel.
- Refinement Loop: An automated eval layer checks for contradictions or inconsistencies across the parallel-generated documents to ensure the entire record remains coherent.
Clinician-Led Pipelines
To ensure domain accuracy, Anterior models the entire generation pipeline as a series of skills running on an internal agent harness. Clinicians can steer the generation process in real-time or modify the pipeline logic by creating new skill files without requiring engineering intervention. This setup allows the team to simulate specific failure modes and generate datasets just-in-time for new customer deployments, effectively bypassing the inability to store or derive information from real patient fax bundles.