PatientFlowSynth: Evaluating FHIR Agents with Matched Patient Charts
Organizations: Oracle Health AI
Abstract
Agents that search patient charts must classify claims from retrieved records, including cases with missing or conflicting evidence. In Fast Healthcare Interoperability Resources (FHIR), status fields can change how those records should be interpreted. PatientFlowSynth provides 18,000 tasks from 225 synthetic patients and 18 templates that hold the patient, question, and retrieval program fixed across chart variants representing four evidence states. Re-executing the program verifies each variant's reference answer, evidence sets, and search requirements. Strict success requires a completed response with correct labels and citations exactly matching an accepted evidence set retrieved during the episode. Where required, a tool response must also show a complete search at the specified scope. In a study using GPT-5.6 Luna and 225 synthetic patients (3,600 matched pairs), explicit Encounter-status guidance increased strict success from 40.7% to 51.3% (+10.6 percentage points; 95% patient-bootstrap confidence interval, 8.4 to 12.8). Among cases whose primary reference label was insufficient evidence, label agreement fell from 49.2% to 29.3%. A prespecified two-model replication reproduced both changes. Failed retrieval can mask interpretation errors by producing a correct insufficient-evidence label without examining the relevant records. Additional model comparisons showed that the benefit of guidance was model-dependent. Retrieval, citation, and classification should be evaluated separately.
Figures & tables
| Clinical resource(s) | Direct | Encounter-first |
|---|---|---|
| Condition | 688 | 688 |
| Immunization | 360 | 360 |
| Observation | 752 | 752 |
| Condition Immunization | 1,216 | 1,216 |
| Condition Observation | 1,536 | 1,536 |
| Immunization Condition | 576 | 576 |
| Study | Patients; models | Episodes | Contrast and evidence status |
|---|---|---|---|
| Primary Encounter | 225; Luna | 7,200 | Natural versus explicit Encounter status; confirmatory |
| Replication | 48 new; Luna/Terra | 6,144 | Same contrast, two repeats; prespecified |
| Four-note extension | 128; Luna/Terra | 2,048 | Relevant versus equal-length irrelevant notes; prespecified |
| Luna depth three | 225; Luna | 7,200 | Status contrast, widths one and two; prespecified descriptive |
| Qwen/Luna comparison | 24 new; Luna/Qwen3.8-27B | 3,072 | Status contrast, two repeats; prespecified |
| Cross-provider panel | 48; Claude/Gemini | 2,304 | Depth one/two, high reasoning; exploratory |
Appendix figures & tables10 assets
Supplementary material from the paper’s appendix.
Appendix
| Rate (%) | (pp) | 95% interval | ||
|---|---|---|---|---|
| Outcome | Natural | Explicit | ||
| Exact answer | 61.50 | 73.00 | +11.50 | [9.69, 13.28] |
| Evidence sufficient | 68.17 | 93.78 | +25.61 | [23.64, 27.56] |
| Exact + evidence | 52.64 | 69.89 | +17.25 | [15.33, 19.19] |
| Exact + evidence + search | 40.75 | 51.31 | +10.56 | [8.36, 12.78] |
| Strict success | 40.72 | 51.28 | +10.56 | [8.36, 12.75] |
| Strict success (%) | (pp) | 95% interval | |||
|---|---|---|---|---|---|
| Rule | Natural | Explicit | |||
| Condition documented | 86 | 38.15 | 44.11 | +5.96 | [2.69, 9.16] |
| Immunization complete | 45 | 31.11 | 46.11 | +15.00 | [10.28, 19.44] |
| Observation final | 94 | 47.67 | 60.31 | +12.63 | [8.98, 16.36] |
| Depth and claims | Natural (%) | Explicit (%) | (pp) |
|---|---|---|---|
| Luna, depth two: exploratory | |||
| 48.89 | 53.33 | +4.44 | |
| 32.56 | 49.22 | +16.67 | |
| Luna, depth three: prespecified descriptive | |||
| 8.94 | 13.06 | +4.11 | |
| 4.11 | 7.28 | +3.17 | |
| Model | Irrelevant (%) | Relevant (%) | (pp) | 95% interval |
|---|---|---|---|---|
| Encounter search | ||||
| Luna | 38.28 | 50.78 | +12.50 | [1.56, 23.44] |
| Terra | 43.75 | 77.34 | +33.59 | [25.78, 41.41] |
| Condition verification status | ||||
| Luna | 42.97 | 53.91 | +10.94 | [1.56, 20.31] |
| Terra | 30.47 | 24.22 | -6.25 | [-16.41, 3.13] |
| Judgment | Reviewer 1 | Reviewer 2 |
|---|---|---|
| Reference defensible | 22/1/1 | 24/0/0 |
| Model answer acceptable | 17/6/1 | 19/5/0 |
| Citations adequate, original forms | 17/6/1 | 24/0/0 |
| Citations adequate, clarification | — | 19/5/0 |
| Resource | Supports | Refutes |
|---|---|---|
| Condition | confirmed | refuted |
| Immunization | completed | not-done |
| Observation | final , amended , or corrected , with a nonnull normalized value | cancelled |
| Study/model | Exception to shared defaults |
|---|---|
| Qwen interface study | Provider-default parallel calls |
| Claude/Gemini panel | High reasoning; sequential tools |
| Fixed-record diagnostic | No tools; one classification call per case, condition, model, and repeat |
| Model | Natural | Explicit | [95% interval] |
|---|---|---|---|
| Claude Opus 4.8 | 64.06 | 65.63 | |
| Gemini 3.1 Pro | 18.23 | 14.58 |
| Cohort / model | Pairs | Encounter returned | Correct primary label | New retrieval / regressions |
|---|---|---|---|---|
| Primary Luna | 900 | |||
| Rep. Luna | 384 | |||
| Rep. Terra | 384 |
| Model | Instructions | Clinical | Routing | ID error |
|---|---|---|---|---|
| Luna | Generic | 23 | 0 | 0 |
| Luna | Routing | 22 | 0 | 0 |
| Luna | Full policy | 0 | 13 | 1 |
| Terra | Generic | 18 | 9 | 0 |
| Terra | Routing | 21 | 9 | 0 |
| Terra | Full policy | 0 | 328 | 0 |