AI & XML / LLM test suite / Results / Test cases / FHIR_HFIR_01_SimpleBundle-json

Test case description

This test checks whether the model can generate a simple FHIR R4 Bundle with exactly one Patient and one Observation, with the Observation containing four HFIR components H, F, I and R.

Source file

FHIR_HFIR_01_SimpleBundle_json.txt

Series

2

Categories

fhir, json, hfir, bundle

Evaluation

LLM judge

Prompt SHA-256

803ac05a6abc70bdfbb7717421c49eda0aa5a7545a97d0a9931035c17d9c6173

LLM judge: The answer is evaluated with LLM support. A judge model compares the model’s answer with the domain expectation and decides whether its content meets it.

Expected result

Valid FHIR R4 JSON Bundle with exactly one Patient, one Observation and four HFIR components H, F, I and R.

Expectation in the catalog

No

Correct result in the catalog

Yes

Judge instruction

Check the requested FHIR R4 serialization, exact resource counts and complete HFIR representation in Observation.component.

Must be satisfied

  • The output consists solely of a syntactically valid JSON object. Markdown code fences may be removed for evaluation; extra prose, comments and trailing commas are not allowed.

  • The root object contains resourceType with value Bundle.

  • Bundle.entry is an array whose resource objects have the correct resourceType values Patient and Observation.

  • FHIR primitives are JSON values with the correct data type. XML attributes or namespace declarations must not be imitated.

  • The Observation has at least status and code. Observation.subject.reference consistently references the Patient in the Bundle.

  • The Bundle contains exactly two entry resources: one Patient and one Observation.

  • The Observation contains exactly four component entries identifying H, F, I and R, each exactly once.

  • Each component has a nonempty valueString or the format-compliant FHIR RDF representation of that valueString.

Error criteria

  • The output is not a parseable JSON object or contains prose or comments outside JSON.

  • resourceType Bundle is missing, or Patient and Observation are not modeled in entry[].resource.

  • XML-style value attributes, xmlns fields treated as mandatory structure, or other mixed syntax are used.

  • Observation.status, Observation.code or the consistent Patient reference is missing.

  • The Bundle has extra or missing Patient or Observation resources.

  • A component H, F, I or R is missing, duplicated or lacks a nonempty string value.

  • HFIR is output only as unstructured text rather than four Observation.component entries.

Judge note: FHIR JSON has no XML namespace. A missing xmlns field is therefore never an error. Valid FHIR R4 JSON structure is decisive. Clinical HFIR text is judged by semantic plausibility, not particular wording.

Prompt

Erstelle ein FHIR R4 Bundle im json-Format.
Es soll genau einen Patient und eine Observation enthalten.
Die Observation soll vier HFIR-Komponenten enthalten namens H, F, I und R.
Hinterlege zu jeder Komponente einen kurzen medizinischen Inhalt.
Verwende gültige FHIR-Attribute und gebe nur das vollständige Bundle zurück.

755 Runs 739 evaluated 27.9 % Score 16.5 % exactly correct

Help on evaluation, score and exact correctness

Score is a graded quality measure: correct = 100 %, mostly_correct = 80 %, partial = 50 %, wrong/not_answered = 0 %.

Exactly correct is stricter: only correct-labeled runs count. Mostly correct increases score but does not count as exactly correct.

Evaluated counts all runs with a substantive judgment. LLM-judge errors also count as evaluated, with score 0 %.

Model Category Access route

x

back to top