NHS North West Genomics
2.2.5 - ci-build
NHS North West Genomics - Local Development build (v2.2.5) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions
Laboratory reports come in two broad kinds. Which kind a report is decides how easily it fits
a FHIR Document. A FHIR Document requires a Composition with human-readable narrative,
so the kind that fits worst is the discrete result (for example a list of reportable variants) -
the opposite of what is often assumed.
| Term used in this guide | Also called | Meaning |
|---|---|---|
| Narrative (interpretive) report | unstructured / semi-structured report, opinion-based or consultative report, document-based report | The result is the opinion of a clinical scientist or pathologist, written as text - often under headings, sometimes as a PDF |
| Discrete (numeric) result | structured / coded result, analytical result, observation-based result, atomic data | The result is a set of values produced by an analyser or pipeline - a code, a value, units, a reference range and a flag for each test |
| Synoptic report | structured report, dataset report | A narrative report whose key items are recorded as discrete data from a defined dataset (for example the RCPath cancer datasets, or the variants in a genomic report) |
Where a single word is wanted on each side, this guide uses report for the narrative kind and result for the discrete kind.
In messaging the difference shows as:
| Narrative report | Discrete result | |
|---|---|---|
| HL7 v2 | OBX of type FT / TX (often many lines with \.br\), NTE, or ED (an embedded PDF) |
OBX of type NM, CWE / CE, SN, with OBX-6 units, OBX-7 range, OBX-8 flag |
| FHIR | DiagnosticReport.conclusion / presentedForm, Observation.valueString, Composition.section.text |
Observation.valueQuantity / valueCodeableConcept, referenceRange, interpretation |
Usually narrative (text with headings, or PDF):
Usually discrete:
Each diagram shows the FHIR resources, the HL7 v2 segment each one comes from, and the element that links them.
ORU^R01 equivalent, see Message Exchange) and to FHIR RESTful
Resource Access (IPA / QEDm)For FHIR Messages and Resource Access. A report is one DiagnosticReport
(the OBRs sharing OBR-3). Each DiagnosticReport.result is either a panel - a test group,
one OBR with several OBX, as an organizer Observation Panel
whose hasMember are the results - or a single result (an OBR with one OBX).
Panel - for example a chromosome analysis (karyotype and FISH):
flowchart LR
DR["DiagnosticReport<br/>ORU_R01 report<br/>OBR-3, OBR-22, OBR-25"]
P["Observation - panel<br/>test group (organizer)<br/>OBR-4 e.g. Chromosome analysis"]
R1["Observation - result<br/>OBX e.g. ISCN karyotype"]
R2["Observation - result<br/>OBX e.g. FISH"]
DR -- result --> P
P -- hasMember --> R1
P -- hasMember --> R2
Single results - for example the reportable variants of a ctDNA panel, each linked directly from the report:
flowchart LR
DR["DiagnosticReport<br/>ORU_R01 report<br/>OBR-3, OBR-22, OBR-25"]
R1["Observation - result<br/>OBX e.g. Variant"]
R2["Observation - result<br/>OBX e.g. Variant"]
DR -- result --> R1
DR -- result --> R2
Both patterns can be mixed in one report - for example a panel (one OBR) and a single result (a second OBR) from one request:
flowchart LR
DR["DiagnosticReport<br/>OBRs sharing OBR-3"]
P["Observation - panel<br/>OBR 1"]
R1["Observation - result<br/>OBX"]
R2["Observation - result<br/>OBX"]
S["Observation - result<br/>OBR 2 / OBX"]
DR -- result --> P
P -- hasMember --> R1
P -- hasMember --> R2
DR -- result --> S
Examples: Shire cytogenetics (panel, karyotype), Shire cytogenetics with FISH (panel with two results) and OMICS DSS ctDNA test results (single results) - all FHIR Messages.
Rendered report (PDF) - an OBX of type ED (Base64 PDF) or RP (a link) becomes a
DocumentReference and a Binary. The DiagnosticReport
stays the parent: presentedForm.url gives the PDF directly, and the DocumentReference points to
the same PDF and back to the report:
flowchart LR
DR["DiagnosticReport<br/>ORU_R01 report"]
DOC["DocumentReference<br/>OBX type ED / RP<br/>OBX-3 document type"]
BIN["Binary<br/>the PDF<br/>OBX-5 ED-5 Base64 data"]
DR -- presentedForm.url --> BIN
DOC -- content.attachment.url --> BIN
DOC -- context.related --> DR
DiagnosticReport.result can only reference an Observation, so the report cannot
list the DocumentReference among its results. HL7 Europe defines a DiagnosticReport.media.link
extension (which references a DocumentReference) for this; the examples in this guide use
presentedForm.url and DocumentReference.context.related instead.
A rendered report is normally exchanged in one of two ways (see the general rule above):
presentedForm / the
DocumentReference) - for example the Genomics Report messageText report in a FHIR Message or Resource Access - the text is in OBX of type ST / FT (or TX
lines), and becomes a result whose value is the text - for example the ISCN karyotype and FISH results
in the Shire cytogenetics example:
flowchart LR
DR["DiagnosticReport<br/>ORU_R01 report"]
R["Observation - result<br/>valueString<br/>OBX type ST / FT<br/>(line breaks become new lines)"]
DR -- result --> R
Text report in a FHIR Document (Document Exchange) - the link is simply Composition to section to narrative.
The OBX of type ST / FT is used to create the section: OBX-3 gives section.code (and
title), and OBX-5 (with \.br\ as line breaks) gives section.text:
flowchart LR
C["Composition<br/>FHIR Document header<br/>Composition.text"]
S["section<br/>section.code from OBX-3"]
N["Narrative<br/>section.text<br/>from OBX-5 (ST / FT)"]
C -- section --> S
S -- text --> N
Where the narrative is only available as a PDF, the section entry is the DocumentReference (and Binary) - for example the Presented Format section of the ctDNA FHIR Document, and the Genomics Report Targeted Variant document.
A Composition can also carry discrete results. The Composition is the parent: the DiagnosticReport is an entry in a section, and links on to its panels and results as in the FHIR Message. The Observations are also entries in the sections: a section entry can be the panel Observation or an individual result directly (for example each reportable variant in a Findings section). The section's narrative is generated from those results - see Why Discrete Results Are Harder to Send as a FHIR Document:
flowchart LR
C["Composition<br/>FHIR Document header<br/>Composition.text"]
S["section<br/>section.text = generated<br/>table of results"]
DR["DiagnosticReport<br/>ORU_R01 report"]
P["Observation - panel<br/>OBR-4"]
R1["Observation - result<br/>OBX"]
R2["Observation - result<br/>OBX"]
C -- section --> S
S -- entry --> DR
S -- entry --> P
S -- entry --> R2
DR -- result --> P
P -- hasMember --> R1
P -- hasMember --> R2
Examples: ctDNA UGR Phase 2 - EU Laboratory Report, ctDNA and Lynch syndrome (FHIR Documents).
A FHIR Document is a Bundle of type document whose first entry is a Composition.
HL7 Europe Composition-eu-lab (the parent of the
Composition Genomic Report)
requires at least one section and makes section.text mandatory (1..1). The narrative
is the attested, human-readable content of the document.
For a narrative report this fits naturally: the laboratory already wrote the narrative.
Its headings (findings, implications, recommended actions) become sections, the authorised text
becomes section.text, and what is coded is added alongside it. The document is a wrapper
for content that already exists.
For a discrete result there is usually nothing to put there:
ORU^R01 has no text form of it beyond a few NTE comments. The sender SHALL
make one to meet section.text 1..1OBR), so each test group becomes a section, with the test group
code as section.codeObservations; the narrative adds a second copy that must be kept in step. The
ctDNA FHIR Document example has
placeholder section text ("see PDF") rather than a rendering of the variants, which shows
the difficultyORU^R01 and FHIR Messages carry discrete
results without a Composition. HL7 Europe DiagnosticReport-eu-lab requires the
DiagnosticReport.composition extension, which is why this guide's
Diagnostic Report is derived from EU Core
insteadIn short, the FHIR Document model suits narrative reports, where a document already exists. For discrete results it adds an artificial document that has to be generated.