FHIR Release 3 (STU) CI-Build

This page is part of the FHIR Specification (v3.0.2: STU 3). The current version which supercedes this version is 5.0.0 . For a full list Continuous Integration Build of available versions, see FHIR (will be incorrect/inconsistent at times).
See the Directory of published versions . Page versions: R5 R4B R4 R3

Composition-example.ttl

Example Composition/example (Turtle)

Maturity Level : N/A
Responsible Owner: Structured Documents Work Group Ballot Standards Status : Informative Compartments : Device , Encounter , Patient , Practitioner , RelatedPerson

Raw Turtle , JSON-LD (+ also see Turtle/RDF Format Specification )

Simple Example of a Composition

@prefix fhir: <http://hl7.org/fhir/> .
@prefix loinc: <http://loinc.org/owl#> .

@prefix loinc: <https://loinc.org/rdf/> .

@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .

# - resource -------------------------------------------------------------------

<http://hl7.org/fhir/Composition/example> a fhir:Composition;
  fhir:nodeRole fhir:treeRoot;
  fhir:Resource.id [ fhir:value "example"];
  fhir:DomainResource.text [
     fhir:Narrative.status [ fhir:value "generated" ];
     fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n			<p>Consultation note for Henry Levin the 7th</p>\n			<p>Managed by Good Health Clinic</p>\n		</div>"
  ];
  fhir:Composition.identifier [
     fhir:Identifier.system [ fhir:value "http://healthintersections.com.au/test" ];
     fhir:Identifier.value [ fhir:value "1" ]
  ];
  fhir:Composition.status [ fhir:value "final"];
  fhir:Composition.type [
     fhir:CodeableConcept.coding [
       fhir:index 0;
       a loinc:11488-4;
       fhir:Coding.system [ fhir:value "http://loinc.org" ];
       fhir:Coding.code [ fhir:value "11488-4" ];
       fhir:Coding.display [ fhir:value "Consult note" ]
     ]
  ];
  fhir:Composition.class [
     fhir:CodeableConcept.coding [
       fhir:index 0;
       a loinc:LP173421-1;
       fhir:Coding.system [ fhir:value "http://loinc.org" ];
       fhir:Coding.code [ fhir:value "LP173421-1" ];
       fhir:Coding.display [ fhir:value "Report" ]
     ]
  ];
  fhir:Composition.subject [
     fhir:link <http://hl7.org/fhir/Patient/xcda>;
     fhir:Reference.reference [ fhir:value "Patient/xcda" ];
     fhir:Reference.display [ fhir:value "Henry Levin the 7th" ]
  ];
  fhir:Composition.encounter [
     fhir:link <http://hl7.org/fhir/Encounter/xcda>;
     fhir:Reference.reference [ fhir:value "Encounter/xcda" ]
  ];
  fhir:Composition.date [ fhir:value "2012-01-04T09:10:14Z"^^xsd:dateTime];
  fhir:Composition.author [
     fhir:index 0;
     fhir:link <http://hl7.org/fhir/Practitioner/xcda-author>;
     fhir:Reference.reference [ fhir:value "Practitioner/xcda-author" ];
     fhir:Reference.display [ fhir:value "Harold Hippocrates, MD" ]
  ];
  fhir:Composition.title [ fhir:value "Consultation Note"];
  fhir:Composition.confidentiality [ fhir:value "N"];
  fhir:Composition.attester [
     fhir:index 0;
     fhir:Composition.attester.mode [
       fhir:value "legal";
       fhir:index 0
     ];
     fhir:Composition.attester.time [ fhir:value "2012-01-04T09:10:14Z"^^xsd:dateTime ];
     fhir:Composition.attester.party [
       fhir:link <http://hl7.org/fhir/Practitioner/xcda-author>;
       fhir:Reference.reference [ fhir:value "Practitioner/xcda-author" ];
       fhir:Reference.display [ fhir:value "Harold Hippocrates, MD" ]
     ]
  ];
  fhir:Composition.custodian [
     fhir:link <http://hl7.org/fhir/Organization/2.16.840.1.113883.19.5>;
     fhir:Reference.reference [ fhir:value "Organization/2.16.840.1.113883.19.5" ];
     fhir:Reference.display [ fhir:value "Good Health Clinic" ]
  ];
  fhir:Composition.relatesTo [
     fhir:index 0;
     fhir:Composition.relatesTo.code [ fhir:value "replaces" ];
     fhir:Composition.relatesTo.targetReference [
       fhir:link <http://hl7.org/fhir/Composition/old-example>;
       fhir:Reference.reference [ fhir:value "Composition/old-example" ]
     ]
  ], [
     fhir:index 1;
     fhir:Composition.relatesTo.code [ fhir:value "appends" ];
     fhir:Composition.relatesTo.targetIdentifier [
       fhir:Identifier.system [ fhir:value "http://example.org/fhir/NamingSystem/document-ids" ];
       fhir:Identifier.value [ fhir:value "ABC123" ]

<http://hl7.org/fhir/Composition/example> a fhir:Composition ;
  fhir:nodeRole fhir:treeRoot ;
  fhir:id [ fhir:v "example"] ; # 
  fhir:text [
     fhir:status [ fhir:v "generated" ] ;
     fhir:div [ fhir:v "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n			<p>Consultation note for Henry Levin the 7th</p>\n			<p>Managed by Good Health Clinic</p>\n		</div>"^^rdf:XMLLiteral ]
  ] ; # 
  fhir:identifier ( [
     fhir:system [
       fhir:v "http://healthintersections.com.au/test"^^xsd:anyURI ;
       fhir:l <http://healthintersections.com.au/test>
     ] ;
     fhir:value [ fhir:v "1" ]
  ] ) ; # 
  fhir:status [ fhir:v "final"] ; # 
  fhir:type [
     fhir:coding ( [
       a loinc:11488-4 ;
       fhir:system [
         fhir:v "http://loinc.org"^^xsd:anyURI ;
         fhir:l <http://loinc.org>
       ] ;
       fhir:code [ fhir:v "11488-4" ] ;
       fhir:display [ fhir:v "Consult note" ]
     ] )
  ] ; # 
  fhir:category ( [
     fhir:coding ( [
       a loinc:LP183761-8 ;
       fhir:system [
         fhir:v "http://loinc.org"^^xsd:anyURI ;
         fhir:l <http://loinc.org>
       ] ;
       fhir:code [ fhir:v "LP183761-8" ] ;
       fhir:display [ fhir:v "Report" ]
     ] )
  ] ) ; # 
  fhir:subject ( [
     fhir:l <http://hl7.org/fhir/Patient/xcda> ;
     fhir:reference [ fhir:v "Patient/xcda" ] ;
     fhir:display [ fhir:v "Henry Levin the 7th" ]
  ] ) ; # 
  fhir:encounter [
     fhir:l <http://hl7.org/fhir/Encounter/xcda> ;
     fhir:reference [ fhir:v "Encounter/xcda" ]
  ] ; # 
  fhir:date [ fhir:v "2012-01-04T09:10:14Z"^^xsd:dateTime] ; # 
  fhir:author ( [
     fhir:l <http://hl7.org/fhir/Practitioner/xcda-author> ;
     fhir:reference [ fhir:v "Practitioner/xcda-author" ] ;
     fhir:display [ fhir:v "Harold Hippocrates, MD" ]
  ] ) ; # 
  fhir:title [ fhir:v "Consultation Note"] ; # 
  fhir:attester ( [
     fhir:mode [
       fhir:coding ( [
         fhir:system [
           fhir:v "http://hl7.org/fhir/composition-attestation-mode"^^xsd:anyURI ;
           fhir:l <http://hl7.org/fhir/composition-attestation-mode>
         ] ;
         fhir:code [ fhir:v "legal" ] ;
         fhir:display [ fhir:v "Legal" ]
       ] )
     ] ;
     fhir:time [ fhir:v "2012-01-04T09:10:14Z"^^xsd:dateTime ] ;
     fhir:party [
       fhir:l <http://hl7.org/fhir/Practitioner/xcda-author> ;
       fhir:reference [ fhir:v "Practitioner/xcda-author" ] ;
       fhir:display [ fhir:v "Harold Hippocrates, MD" ]

     ]
  ];
  fhir:Composition.event [
     fhir:index 0;
     fhir:Composition.event.code [
       fhir:index 0;
       fhir:CodeableConcept.coding [
         fhir:index 0;
         fhir:Coding.system [ fhir:value "http://hl7.org/fhir/v3/ActCode" ];
         fhir:Coding.code [ fhir:value "HEALTHREC" ];
         fhir:Coding.display [ fhir:value "health record" ]
       ]
     ];
     fhir:Composition.event.period [
       fhir:Period.start [ fhir:value "2010-07-18"^^xsd:date ];
       fhir:Period.end [ fhir:value "2012-11-12"^^xsd:date ]
     ];
     fhir:Composition.event.detail [
       fhir:index 0;
       fhir:link <http://hl7.org/fhir/Observation/example>;
       fhir:Reference.reference [ fhir:value "Observation/example" ]

  ] ) ; # 
  fhir:custodian [
     fhir:l <http://hl7.org/fhir/Organization/2.16.840.1.113883.19.5> ;
     fhir:reference [ fhir:v "Organization/2.16.840.1.113883.19.5" ] ;
     fhir:display [ fhir:v "Good Health Clinic" ]
  ] ; # 
  fhir:relatesTo ( [
     fhir:type [
       fhir:coding ( [
         fhir:system [
           fhir:v "http://terminology.hl7.org/CodeSystem/artifact-relationship-type"^^xsd:anyURI ;
           fhir:l <http://terminology.hl7.org/CodeSystem/artifact-relationship-type>
         ] ;
         fhir:code [ fhir:v "replaces" ] ;
         fhir:display [ fhir:v "Replaces" ]
       ] )
     ] ;
     fhir:target [
       a fhir:Reference ;
       fhir:l <http://hl7.org/fhir/Composition/old-example> ;
       fhir:reference [ fhir:v "Composition/old-example" ]

     ]
  ];
  fhir:Composition.section [
     fhir:index 0;
     fhir:Composition.section.title [ fhir:value "History of present illness" ];
     fhir:Composition.section.code [
       fhir:CodeableConcept.coding [
         fhir:index 0;
         a loinc:11348-0;
         fhir:Coding.system [ fhir:value "http://loinc.org" ];
         fhir:Coding.code [ fhir:value "11348-0" ];
         fhir:Coding.display [ fhir:value "History of past illness Narrative" ]
       ]
     ];
     fhir:Composition.section.text [
       fhir:Narrative.status [ fhir:value "generated" ];
       fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n				<table>\n					<tr>\n						<td>\n							<b>Code</b>\n						</td>\n						<td>\n							<b>Date</b>\n						</td>\n						<td>\n							<b>Type</b>\n						</td>\n						<td>\n							<b>BodySite</b>\n						</td>\n						<td>\n							<b>Severity</b>\n						</td>\n					</tr>\n					<tr>\n						<td>Stroke</td>\n						<td>2010-07-18</td>\n						<td>Diagnosis</td>\n						<td/>\n						<td/>\n					</tr>\n					<tr>\n						<td>Burnt Ear</td>\n						<td>2012-05-24</td>\n						<td>Diagnosis</td>\n						<td>Left Ear</td>\n						<td/>\n					</tr>\n					<tr>\n						<td>Asthma</td>\n						<td>2012-11-12</td>\n						<td>Finding</td>\n						<td/>\n						<td>Mild</td>\n					</tr>\n				</table>\n			</div>"
     ];
     fhir:Composition.section.mode [ fhir:value "snapshot" ];
     fhir:Composition.section.orderedBy [
       fhir:CodeableConcept.coding [
         fhir:index 0;
         fhir:Coding.system [ fhir:value "http://hl7.org/fhir/list-order" ];
         fhir:Coding.code [ fhir:value "event-date" ];
         fhir:Coding.display [ fhir:value "Sorted by Event Date" ]

  ] [
     fhir:type [
       fhir:coding ( [
         fhir:system [
           fhir:v "http://terminology.hl7.org/CodeSystem/artifact-relationship-type"^^xsd:anyURI ;
           fhir:l <http://terminology.hl7.org/CodeSystem/artifact-relationship-type>
         ] ;
         fhir:code [ fhir:v "appends" ] ;
         fhir:display [ fhir:v "Appends" ]
       ] )
     ] ;
     fhir:target [
       a fhir:Reference ;
       fhir:identifier [
         fhir:system [
           fhir:v "http://example.org/fhir/NamingSystem/document-ids"^^xsd:anyURI ;
           fhir:l <http://example.org/fhir/NamingSystem/document-ids>
         ] ;
         fhir:value [ fhir:v "ABC123" ]

       ]
     ];
     fhir:Composition.section.entry [
       fhir:index 0;
       fhir:link <http://hl7.org/fhir/Condition/stroke>;
       fhir:Reference.reference [ fhir:value "Condition/stroke" ]
     ], [
       fhir:index 1;
       fhir:link <http://hl7.org/fhir/Condition/example>;
       fhir:Reference.reference [ fhir:value "Condition/example" ]
     ], [
       fhir:index 2;
       fhir:link <http://hl7.org/fhir/Condition/example2>;
       fhir:Reference.reference [ fhir:value "Condition/example2" ]

     ]
  ], [
     fhir:index 1;
     fhir:Composition.section.title [ fhir:value "History of family member diseases" ];
     fhir:Composition.section.code [
       fhir:CodeableConcept.coding [
         fhir:index 0;
         a loinc:10157-6;
         fhir:Coding.system [ fhir:value "http://loinc.org" ];
         fhir:Coding.code [ fhir:value "10157-6" ];
         fhir:Coding.display [ fhir:value "History of family member diseases Narrative" ]
       ]
     ];
     fhir:Composition.section.text [
       fhir:Narrative.status [ fhir:value "generated" ];
       fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n				<p>History of family member diseases - not available</p>\n			</div>"
     ];
     fhir:Composition.section.mode [ fhir:value "snapshot" ];
     fhir:Composition.section.emptyReason [
       fhir:CodeableConcept.coding [
         fhir:index 0;
         fhir:Coding.system [ fhir:value "http://hl7.org/fhir/list-empty-reason" ];
         fhir:Coding.code [ fhir:value "withheld" ];
         fhir:Coding.display [ fhir:value "Information Withheld" ]

  ] ) ; # 
  fhir:event ( [
     fhir:period [
       fhir:start [ fhir:v "2010-07-18"^^xsd:date ] ;
       fhir:end [ fhir:v "2012-11-12"^^xsd:date ]
     ] ;
     fhir:detail ( [
       fhir:concept [
         fhir:coding ( [
           fhir:system [
             fhir:v "http://terminology.hl7.org/CodeSystem/v3-ActCode"^^xsd:anyURI ;
             fhir:l <http://terminology.hl7.org/CodeSystem/v3-ActCode>
           ] ;
           fhir:code [ fhir:v "HEALTHREC" ] ;
           fhir:display [ fhir:v "health record" ]
         ] )
       ] ;
       fhir:reference [
         fhir:l <http://hl7.org/fhir/Observation/example> ;
         fhir:reference [ fhir:v "Observation/example" ]

       ]
     ] )
  ] ) ; # 
  fhir:section ( [
     fhir:title [ fhir:v "History of present illness" ] ;
     fhir:code [
       fhir:coding ( [
         a loinc:11348-0 ;
         fhir:system [
           fhir:v "http://loinc.org"^^xsd:anyURI ;
           fhir:l <http://loinc.org>
         ] ;
         fhir:code [ fhir:v "11348-0" ] ;
         fhir:display [ fhir:v "History of Past illness note" ]
       ] )
     ] ;
     fhir:text [
       fhir:status [ fhir:v "generated" ] ;
       fhir:div [ fhir:v "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n				<table>\n					<tr>\n						<td>\n							<b>Code</b>\n						</td>\n						<td>\n							<b>Date</b>\n						</td>\n						<td>\n							<b>Type</b>\n						</td>\n						<td>\n							<b>BodySite</b>\n						</td>\n						<td>\n							<b>Severity</b>\n						</td>\n					</tr>\n					<tr>\n						<td>Stroke</td>\n						<td>2010-07-18</td>\n						<td>Diagnosis</td>\n						<td/>\n						<td/>\n					</tr>\n					<tr>\n						<td>Burnt Ear</td>\n						<td>2012-05-24</td>\n						<td>Diagnosis</td>\n						<td>Left Ear</td>\n						<td/>\n					</tr>\n					<tr>\n						<td>Asthma</td>\n						<td>2012-11-12</td>\n						<td>Finding</td>\n						<td/>\n						<td>Mild</td>\n					</tr>\n				</table>\n			</div>"^^rdf:XMLLiteral ]
     ] ;
     fhir:orderedBy [
       fhir:coding ( [
         fhir:system [
           fhir:v "http://terminology.hl7.org/CodeSystem/list-order"^^xsd:anyURI ;
           fhir:l <http://terminology.hl7.org/CodeSystem/list-order>
         ] ;
         fhir:code [ fhir:v "event-date" ] ;
         fhir:display [ fhir:v "Sorted by Event Date" ]
       ] )
     ] ;
     fhir:entry ( [
       fhir:l <http://hl7.org/fhir/Condition/stroke> ;
       fhir:reference [ fhir:v "Condition/stroke" ]
     ] [
       fhir:l <http://hl7.org/fhir/Condition/example> ;
       fhir:reference [ fhir:v "Condition/example" ]
     ] [
       fhir:l <http://hl7.org/fhir/Condition/example2> ;
       fhir:reference [ fhir:v "Condition/example2" ]
     ] )
  ] [
     fhir:title [ fhir:v "History of family member diseases" ] ;
     fhir:code [
       fhir:coding ( [
         a loinc:10157-6 ;
         fhir:system [
           fhir:v "http://loinc.org"^^xsd:anyURI ;
           fhir:l <http://loinc.org>
         ] ;
         fhir:code [ fhir:v "10157-6" ] ;
         fhir:display [ fhir:v "History of family member diseases note" ]
       ] )
     ] ;
     fhir:text [
       fhir:status [ fhir:v "generated" ] ;
       fhir:div [ fhir:v "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n				<p>History of family member diseases - not available</p>\n			</div>"^^rdf:XMLLiteral ]
     ] ;
     fhir:emptyReason [
       fhir:coding ( [
         fhir:system [
           fhir:v "http://terminology.hl7.org/CodeSystem/list-empty-reason"^^xsd:anyURI ;
           fhir:l <http://terminology.hl7.org/CodeSystem/list-empty-reason>
         ] ;
         fhir:code [ fhir:v "withheld" ] ;
         fhir:display [ fhir:v "Information Withheld" ]
       ] )

     ]
  ] .

  ] ) . # 


<http://hl7.org/fhir/Patient/xcda> a fhir:Patient .

<http://hl7.org/fhir/Encounter/xcda> a fhir:Encounter .

<http://hl7.org/fhir/Practitioner/xcda-author> a fhir:Practitioner .

<http://hl7.org/fhir/Organization/2.16.840.1.113883.19.5> a fhir:Organization .

<http://hl7.org/fhir/Composition/old-example> a fhir:Composition .

<http://hl7.org/fhir/Observation/example> a fhir:Observation .

<http://hl7.org/fhir/Condition/stroke> a fhir:Condition .

<http://hl7.org/fhir/Condition/example> a fhir:Condition .

<http://hl7.org/fhir/Condition/example2> a fhir:Condition .

# - ontology header ------------------------------------------------------------

<http://hl7.org/fhir/Composition/example.ttl> a owl:Ontology;
  owl:imports fhir:fhir.ttl;
  owl:versionIRI <http://hl7.org/fhir/STU3/Composition/example.ttl> .


# -------------------------------------------------------------------------------------


Usage note: every effort has been made to ensure that the examples are correct and useful, but they are not a normative part of the specification.