1. Fundamentals of CDA & Implementing CDA (30-31 August 2010 , Auckland) A practical hands on, international expert driven training seminar Presented by: Grahame Grieve B.Sc. MAACB. CTO, Kestral Computing P/L Thanks to… HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 1
2. Fundamentals of CDA & Implementing CDA HL7 NZ, August 2010 Grahame Grieve Acknowledgements: Bob Dolin, Rene Spronk HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 2
3. Agenda Day #1: Fundamentals of CDA Background CDA, RIM, Vocab, datatypes, templates… Messages vs Documents & Exchanging CDA Day #2: Implementing CDA Representing Data Models in CDA CDA XML – schemas, schematrons Tools for working with CDA HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 3
4. Agenda for Today Welcome CDA In Depth Exchanging CDA v2 / CDA Comparison HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 4
5. Agenda for Today Welcome Administration Biography Handouts Distribution CDA In Depth Exchanging CDA v2 / CDA Comparison HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 5
6. Grahame’s Bio B Sc Biochemistry (Auckland Uni) Clinical Biochemistry/Medical Research (6 years) Lead Developer CTO, Kestral Computing Clinical & middleware product development Chair, various HL7 Committees (incl CDA) Editor, various standards (templates & data types) Project Lead, Eclipse Open Health Framework HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 6
7. Distribution HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 7
8. Interoperability Ability of two or more systems or components to exchange information and to use the information that has been exchanged. Source: IEEE Standard Computer Dictionary: A Compilation of IEEE Standard Computer Glossaries, IEEE, 1990] Functional Interoperability Semantic Interoperability HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 8
9. Three Laws of Interoperability Interoperability: It’s all about the people HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 9
10. Three Laws of Interoperability Interoperability: It’s all about the people You can hide the complexity, or make it worse, but you can’t make it go away HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 10
11. Three Laws of Interoperability Interoperability: It’s all about the people You can hide the complexity, or make it worse, but you can’t make it go away Cheap, flexible, and interoperable: when developing healthcare software, you can have two of these HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 11
12. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 12
13. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 13
14. Interoperability Drive-by Interoperability Vendors with antagonistic relationships Highly variable business arrangements National Program Interoperability Large contracts with efficiency of scale Standardised business practices imposed on variable architecture HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 14
15. Agenda for Today Welcome CDA In Depth (circular) Document characteristics Document Structure CDA Reference model / Data Types Architecture, Templates, Extensibility Implementation guides / CCD Exchanging CDA v2 / CDA Comparison HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 15
16. What is CDA? A document that a human can read Computer can understand Contains clinical content Authored by a human XML “Architecture” – a way to control it’s contents HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 16
17. Where is CDA being used? http://www.google.com/maps/ms?ie=UTF8&oe=UTF8&source=embed&msa=0&msid=110535847732151766411.00047b0b46314e91435c9 HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 17
18. Clinical Documents: Documentation of clinical observations and services Attestation Persistance / Stewardship Own context Potential for authentication (whole, unchanged) Human readable HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 18
19. Clinical Documents: Used for communication & record-keeping Content is somewhat predictable Content must be understood Multi media – not just text (tables, letters, pictures, sounds, videos, hand-drawn diagrams, specimens) For humans & computers Demonstrated authorship & custodianship HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 19
20. Scope of CDA Documents for exchange Does not specify: Storage Creation Management HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 20
21. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 21
22. Parts of a CDA Document <ClinicalDocument> ... CDA Header ... <structuredBody> <section> <text>...</text> <observation>...</observation> <substanceAdministration> <supply>...</supply> </substanceAdministration> <observation> <externalObservation> ... </externalObservation> </observation> </section> <section> <section> ... </section> </section> </structuredBody> </ClinicalDocument> Document Header Body Sections Narrative (Text) Data (Entries) (Observations, Prescriptions, etc) Component Sections HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 22
23. Human Readability Clinical Content must display in a browser (transform) Compromise: This is partly infrastructural Partly the responsibility of the document author – must design according to these rules Often violated (can’t be tested) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 23
24. Narrative Example <example> <paragraph> <caption styleCode="Bold xHead1">Introduction</caption> Thank you for referring this patient for investigation into <content ID="c1">burnt ears</content>. </paragraph> <list> <caption styleCode="Bold xHead1">Initial Observations</caption> <item>The patient presented in a very confused state.</item> <item> There was extensive damage to the outer ears: <renderMultiMedia referencedObject="i1"> <caption>Photo of left ear</caption> </renderMultiMedia> </item> </list> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 24
25. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 25
27. Narrative Example <paragraph> <caption styleCode="Bold xHead1">Recommendations</caption> The patient should apply a cream to the outer ears until they are healed. <content revised="insert">The patient should wear a woollen balaclava in the future while ironing his shirts to prevent a re-occurence of the accident<footnote>This has been proven to offer the best protection against a repeat injury. See <linkHtml href="http://www.wikipedia.org/wiki/burnt_ears"> the wikipedia article about burnt ears</linkHtml> for further information.</footnote>.</content> </paragraph> </example> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 27
28. CDA Narrative Functionally a stripped down version of XHTML Some key differences in scope not intended to be complete documents allow referencing into other content embedded version/change control can easily transform to XHTML Created before XHTML + new work on microformats : may migrate to XHTML HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 28
29. Conformance Must be valid against schema & specification Must use allowed codes Valid with regard to claimed templates (not stated) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 29
30. Conformance: Receiver Know default values Parse the complete header Be able to render the body Don’t have to read the entries Don’t have to know or validate the templates May make trading partner agreements HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 30
31. Conformance: Originator Properly construct Narrative blocks Does not have to create entries May make trading partner agreements HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 31
32. CDA Content Model Multiple views of the one model RMIM diagram (Static Model) Heirarchical Description (Excel spreadsheet) Schema Narrative MIF Others could be imagined There is only one model HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 32
33. CDA Static Model HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 33
34. RIM (Reference Information Model) Basis of All HL7 V3 designs Fairly abstract (Unified Service Action Model) Act | Participation | Role | Entity Act | ActRelationship Reference Model – metadata A matter of perspective HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 34
35. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 35
36. RMIM/HD RMIM = Refined Message Information Model -> Static Model HD = HMD = Heirarchical (Message) Description A static model is a statement of constraints on a class model. It can also be seen as a class model – but this is an approximation HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 36
37. CDA - ITS The ITS (“Implementation Technology Specification”) describes how abstract concepts in HL7 model are represented in XML The CDA XML is closely based on the ITS XML Naming and Design Rules (NDR) are highly controversial. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 37
38. Basic Structure: not quite UML Header Body / Narrative Data / EntriesClinical Statement HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 38
44. Coding restrictionsHL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 39
45. Structural Vocabulary Each core RIM class has 1 or 2 structural attributes that define its meaning Primary: classCode | typeCode Secondary: moodCode | etc… Values are taken from carefully defined heirarchical vocabulary definitions classCode defines type of class Code defines type of object the class represents HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 40
46.
47.
48.
49. Graphical Elements: Shadows Shadow: a reference to a class defined elsewhere HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 44
50. Graphical Elements: Choices Content can be any one of the classes defined inside the choice box (~abstract class) Relationships outbound from the choice box are shared by all classes in the choice HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 45
51. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 46
52. Hidden Attributes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 47
53. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 48
54. CDA Header Participants HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 49
55. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 50
56. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 51
57. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 52
58. Types of Entries HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 53
70. targetSiteCodeHL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 54
71. Mood Codes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 55
72. Entry Participants HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 56
73. Entry Relationships HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 57
74. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 58
75. Context CDA headers establish a context Context Propagates hierarchically May be overridden Body Section Entry May be set to null Uses RIM propagation mechanisms HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 59
76. Data Types ANY.NullFlavor – incomplete data II - identifiers EN/AD – names & addresses CD – coded values ED – multimedia content PQ – measurements IVL – intervals and ranges HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 60
77. Data Types are Abstract HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 61
78. NullFlavor Incomplete / Partial Data is common in healthcare Patient is unconscious Patient was unwilling to provide information Data is not (yet?) available User does not have access to the information Other system does not collect or share data item Actual value is not a proper value HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 62
79. Not a proper value? Main case: Coded values Code must come from a code system Code system doesn’t contain concept Text alternative is “not a proper value” Other cases: Infinity (+/-) is not a valid integer A trace detected Water to 100mL (in a formulation) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 63
80. Choice: How to handle this? By Exception extra field for providing a reason when appropriate Infrastructurally Slot for reason is always present (?) even when not appropriate May be banned when inappropriate CDA Solution: Every data element (Data Type or RIM Class) may have a nullFlavor HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 64
81. NullFlavor Domain HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 65
82. nullFlavor != null Types or classes that have a nullFlavor may also have other information:<CD nullFlavor=“OTH” codeSystem=“SNOMED”> <originalText>Burnt Ear</originalText></CD> null in implementation technologies (SQL null, OCL null, pointers) mean that no extra information is found nullFlavor is not the same as null! HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 66
83. Why “null”Flavor? If it’s not the same as null, why give it such a confusing name? “ExceptionalValueStatus” is a pig to say It is connected to the notion of a null value in v2 (Internal Continuity) It behaves like an SQL or OCL null (External Continuity) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 67
88. HL7 null values are never equalHL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 68
89. HL7 null and equal HL7 null values’ equality is unknown<CD nullFlavor=“OTH” codeSystem=“SNOMED”> <originalText>Burnt Ear</originalText></CD><CD nullFlavor=“OTH” codeSystem=“SNOMED”> <originalText>Burnt Ear</originalText></CD> HL7 null values may be not equal<INT nullFlavor=“PINF”/><INT nullFlavor=“NINF”/> Not Equal<INT nullFlavor=“UNK”/> Unknown<INT nullFlavor=“PINF”/> No Information HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 69
90. OCL Null OCL null values propagateCD.displayName.language.equal(x) == null Unless special OCLType properties are used:CD.displayName.language.isNull == true HL7 null values work exactly the same way:CD.displayName.language.equal(x) == NICD.displayName.language.isNull == true HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 70
91. NullFlavor NullFlavor does not mean “null” But behaves like it in many ways Every data type (including properties) implicitly carries information about how or why it is incomplete or an improper value Every class and data type may carry other information even when null Implementers must always consider null value! HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 71
92. NullFlavors and Conformance NullFlavors are tied to the conformance framework A null value (has a nullFlavor) is an exception to the value domain assigned in the context of use (not an exception to the value domain assigned in the data types) A mandatory value cannot be null (must be a value from the value domain) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 72
93. NullFlavors and Conformance If value domain is 1-100 and the attribute is not mandatory, can send<INT nullFlavor=“OTH” value=“120”/> What is an implementation supposed to do? Data types specification does not say. You can choose. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 73
94. NullFlavor Implementation When a value is not present (i.e. null) in an implementation, the nullFlavor NI (No information) is considered to apply. (No information = no information) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 74
95. NullFlavors and Properties Sometimes the nullFlavor just doesn’t matter The ITS doesn’t need to convey it. It defaults to NI This applies to other properties too The ITS simplifies many properties to underlying primitives where some of the semantic properties are inferred HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 75
102. Authority NameHL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 76
103. II – Attributes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 77
104. II root & extension root is required (if not null) HL7 & ISO register roots for shared identifiers extension is optional Case sensitive the concatenation of root and extension SHALL be a globally unique identifier HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 78
105. Where’s the type? No type for the identified thing Should there be? No: The identifier is not the identified thing Yes: The identified thing can never change Modeling type of identified thing is hard HL7 V2: one big mess OpenEHR: just give it a code ISO – even worse HL7 V3: lack of modeling discipline a problem! HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 79
106. The Identifier Pattern Where’s identifier type? http://wiki.hl7.org/index.php?title=Common_Design_Patterns HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 80
107. Patient CMET HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 81
108. CDA Doesn’t have this HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 82
110. EN/AD: Names and Addresses A series of parts which are strings Each part has a type Name parts have a set of qualifiers Parts may have a nullFlavor Has a set of use codes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 84
111. Examples Name <name use="L"> <prefix>Mr</prefix><given>Grahame</given>↩ <given>David</given><family>Grieve</family> </name> <addr use="WP PHYS"> <addressLine>1050 W Wishard Blvd</addressLine> <addressLine>RG 5th floor</addressLine> <city>Indianapolis</city> <state>IN</state> <postalCode>46240</postalCode> <country nullFlavor="UNK"/> </addr> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 85
112. Name Use Codes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 86
113. Name Part Types HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 87
114. Name Part Qualifiers HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 88
115. Address Part Types HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 89
116. Address Use Codes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 90
117. CD: Concept References a reference to a concept defined by a referenced code system HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 91
118. CD – Attributes (1) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 92
119. CD Examples <example code="784.0" codeSystem="2.16.840.1.113883.6.42" codeSystemName="ICD-9" displayName="Headache"/> <originalText value="general headache"/> </example> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 93
120. Code System Versions Different versions of one code system must be compatible. By definition a code symbol SHALL have the same meaning throughout all versions of a code system. Between versions, codes may be retired but not withdrawn or reused. Where the definition of the meaning of a code symbol changes, it must still be compatible (equal) between different code system versions. Whenever a code system changes in an incompatible way, it will constitute a new code system, not simply a different version, regardless of how the vocabulary publisher calls it. For example, the publisher of ICD-9 and ICD-10 calls these code systems, "revision 9" and "revision 10" respectively. However, ICD-10 is a complete redesign of the ICD code, not a backward compatible version. Therefore, for the purpose of this data type specification, ICD-9 and ICD-10 are different code systems, not just different versions. By contrast, when LOINC updates from revision "1.0j" to "1.0k", this would be considered as just another version of LOINC, since LOINC revisions are backwards compatible. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 94
121. CD – Qualifiers CR Attributes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 95
122. <example code="128045006" codeSystem=“[SNOMED-CT]" displayName="cellulitis (disorder)"> <qualifier> <name code="363698007" displayName="finding site"/> <value code="56459004" displayName="foot structure"> </qualifier> </example> CD Example - Qualifier HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 96
123. CD – Attributes (cont) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 97
124. displayName Rules The displayName SHALL conform to any rules defined by the codingSystem; if the codeSystem does not define a human representation for the code or expression, then none can be provided. displayName is a courtesy; it has no functional meaning; displayName SHALL never modify the meaning of the code. Information Processing Entities claiming direct or indirect conformance MAY choose not to implement displayName but SHALL NOT reject instances because displayName is present. display names SHOULD NOT be presented to a user without checking it Communication SHALL NOT simply rely on the display name. The display name's main purpose is to support implementation debugging. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 98
125. originalText Rules CD may store only the text that the user entered or uttered. In this situation, original text will exist without a code. In a situation where the code is assigned sometime after the text was entered, originalText is the text or phrase used as the basis for assigning the code. NullFlavor will be OTH or UNC Translations may be provided The original text SHALL be represented in plain text form (excerpt if required) originalText may be a reference to some other text artefact resolution scope must be clearly described and may be further proscribed in specifications that use this specification. Translations SHALL NOT have an originalText of their own. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 99
126. translation Rules Each translation in the set is supposed to express the same meaning "in other words." However, exact synonymy rarely exists so not all of the translations will be equally exact. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 100
127. Coding Failure Cases A common situation with CD is when the actual concept cannot be properly represented in a particular coding system. Usually this circumstance arises where the concept is expected to be represented in a particular coding system. Base case: observation value of type CD bound to the full Snomed-CT valueset Example OID for the value set = 2.16.840.1.113883.19.11.1 as published 11-June 2007 Real OID for the SNOMED-CT code system = 2.16.840.1.113883.6.96 HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 101
128. Simplest Case: <value nullFlavor="NI"/> More useful - say SNOMED: <value nullFlavor="OTH" codeSystem="2.16.840.1.113883.6.96"/> Better to give originalText: <value nullFlavor="OTH" codeSystem="2.16.840.1.113883.6.96"> <originalText value="Burnt ear with iron. Burnt other ear calling for ambulance"/> </value> Coding Failure Cases HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 102
129. Coding Failure Cases CWE: <value code="burn" codeSystem="2.16.840.1.113883.19.5.2"> <originalText value="Burnt ear with iron. Burnt other ear calling for ambulance"/> </value> CNE: <value nullFlavor="OTH" codeSystem="2.16.840.1.113883.6.96"> <originalText value="Burnt ear with iron. Burnt other ear calling for ambulance"/> <translation code="burn" codeSystem="2.16.840.1.113883.19.5.2"> </value> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 103
130. ED – Attributes (1) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 104
131. ED – Attributes (2) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 105
132. PQ Main Features value, precision & Units Translations Canonical form HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 106
133. PQ – Attributes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 107
134. UCUM Unified Code for Units of Measure Developed and maintained by Regenstrief http://aurora.regenstrief.org/ucum PQ uses case sensitive units Units are computable – canonical form can be derived HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 108
136. PQ: part of a triad Sometimes it is not clear how some measurements in healthcare map to UCUM codes. The general pattern for a measurement is valueunit of Thing. In this scheme, the PQ represents the value and the unit, and the Thing is described by some coded concept that is linked to the PQ by the context of use. This maps obviously to some measurements, such as Patient Body Temperature of 37Celsius, and 250mg/day of Salicylate. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 110
137. PQ : part of a triad However for some measurements that arise in healthcare, the scheme is not so obvious: 5 Drinks of Beer 3 Acetominophen tablets At first glance it is tempting to classify these measurments like this: 5drinks of Beer 3Acetominophentablets. UCUM does not support units of "beer", "tablets" or "scoops". HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 111
138. PQ : part of a triad Neither tablets or scoops are proper units. What kind of tablets? How big is the glass? the concept that appears to be a unit needs to further specified before interoperability is established. If a correct amount is required, use an exact measurement with a UCUM unit. If this is not possible, then the concept is not part of the measurement. UCUM provides a unit called unity for use in these cases: The proper way to understand these measurements as 31Acetominophentablets, where 1 is the UCUM unit for unity, and the Thing has a qualifier. The context of use will need to provide the extra qualifying information. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 112
139. CDA – UCUM a problem The third element of the triad is missing… HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 113
140. TS Main Features Fixed instant in time value is a string with the format "YYYYMMDDHHMMSS.UUUU[+|-ZZzz] Precision is very important Semantics are calendar based Example: <example xsi:type="TS" value="20031101234511-1100"/> 11:45pm on 01-Nov 2003 at +5 from UTC (e.g. NZ daylight) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 114
143. max of 2000 and 20000605 is 20001231235959.999 2000HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 115
144. TS - Equality Two nonNull TS values are only equal if their time and precision are equal. If both TS value have timezones, the values should be be corrected for timezone before comparison. If neither TS value has a timezone, then they may be compared for equality without correction. If only one TS value has a timezone, then the equality is null (nullFlavor NI). HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 116
145. IVL Main Features low .. high | center width Bounds closed HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 117
146. IVL(T) – Attributes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 118
147. IVL Examples <example> <low value='2.8' unit='m' inclusive='true' /> <high value='4.6' unit='m' inclusive='false'/> </example> <example> <low value='200012041000'/> <high value='200012041030'/> </example> <example> <low value='20001204'/> <high value='20001206'/> </example> Note: Does not include all of 6/12/2000 HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 119
148. CDA Extensibility Can add Xml in other namespaces should not change the meaning of any of the standard data items receivers must be able to safely ignore these elements recipients must be able to faithfully render the CDA document while ignoring extensions Custom: Extensions should be based on RIM, and submitted to HL7 for inclusion HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 120
149. Clinical Document Architecture CDA has a sophisticated and complex clinical information model Nice for the document author Painful for the document processor Desire for fit between complexity and requirements Need some way to say how a particular use-case is represented Template: a statement of restriction on the CDA model HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 121
152. Describing usage in a formal statement will help implementersHL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 122
153. Formal Statements - Templates There are a number of ways to make formal statements about usage: English Narrative“A valid legal authenticator must be provided” Schematron assertions“legalAuthenticator and not legalAuthenticator[@nullFlavor]” OCL statements“context ClinicalDocument: legalAuthenticator.isNonNull and legalAuthenticator.nonNull” Static ModelPublish a new static model making legalAuthenticator mandatory HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 123
154. 3 meanings for “Template” Example (i.e. Word Document) Something that builds (i.e. Templated classes in Object Orientation) Something that restricts (i.e. Lego Pattern) All: constrain to extend, restrict to free HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 124
155. HL7 Templates A set of constraints on the RIM Formally defined Formal definition in one of more human readable languages (optional) Formal definition as a static model Implementation Specific representations for validation Applied “over-the-top” on the data HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 125
156. Applied “Over-the-top”? This instance conforms to all three models. Which is the class? HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 126
157. Simple Class Model HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 127
158. “Student” as a template ? Student is treatedas a set of rules instead of a “class”definition – doesn’ttake ownership HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 128
159. “Student” as a template Use Stereotype “Student” to markthe relationship HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 129
160. “IdentifiedPerson” as a template Use Stereotype “Student” and “IdentifiedPerson” to markthe relationships HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 130
161. HL7 Templates A set of constraints on the RIM Formally defined Applied “over-the-top” on the data Implicitly Explicitly CDA templates are explicit Data must conform to the constraints HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 131
162. templateId A template makes statements about how a CDA document is actually used Identify templates in specifications Implementers know how CDA document will be used Identify templates in CDA documents Processors (Systems) know how this bit of the document is actually used – can process accordingly Validators can check that the document conforms to the rules But templateIds may be ignored HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 132
163. Document Processing Process by semantics (codes) Slow. Hard? Thorough Process by TemplateId Fast Unreliable? Incomplete? HL7 deeply conflicted about this HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 133
164. Template Registration Well designed templates might be able to used in many contexts A common format and a template registry would allow both humans and computers to find, retrieve and use templates, and re-use the work of experts Template Registry standards are under development HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 134
165. Mandatory Template Metadata HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 135
166. Implementation Guides CDA is too general to use without further rules Communities agree how to use CDA National Programs / Standards Authorities Projects, Colleges, Vendors etc Publish a set of templates called “Implementation Guides” HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 136
167. Implementation Guide Samples Procedure Note (HL7) Etc CCD HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 137
168. CCD : Background CCR: Continuity of Care Record (ASTM E2369-05) most relevant administrative, demographic, and clinical information covering one or more healthcare encounters. means for healthcare entities to aggregate all of a patient’s data and forward it to another one primary use case is a snapshot in time HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 138
169. CCD CCR caused a turf war Resolution was to define a CDA profile that covered the same information Continuity of Care Document: A joint standard between HL7 and ASTM Wide Adoption (especially in USA) HITSP/NIEM(?) Microsoft/Google HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 139
170. CCD: CDA Templates <ClinicalDocument xmlns='urn:hl7-org:v3'> <typeId extension='POCD_HD000040' root='2.16.840.1.113883.1.3'/> <templateId root='2.16.840.1.113883.10.20.1'/> … </ClinicalDocument> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 140
171. CCD: CDA Templates HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 141
172. CCD : CDA Templates HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 142
173. CCD : CDA Templates <!-- CCD v1.0 Templates Root: 2.16.840.1.113883.10.20.1 --> <!-- errors --> ... <pattern id='p-2.16.840.1.113883.10.20.1-errors‘ see='#p-2.16.840.1.113883.10.20.1-errors'> <assert test='count(.//cda:templateId[@root="2.16.840.1.113883.10.20.1.13"]) <= 1'> CCD MAY contain exactly one and SHALL NOT contain more than one Purpose section (templateId 2.16.840.1.113883.10.20.1.13). </assert> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 143
174. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 144
175. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 145
176. CCD Problem A “problem concern” act A Problem Observation An Alert Observation A problem status observation Episode Observations Patient Awareness Report Fit for purpose for Continuity of Care HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 146
177. Agenda for Today Welcome CDA In Depth Exchanging CDA CDA in v2 (Documents vs messages) CDA & web Services IHE XDS V2 / CDA Comparison HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 147
178. Exchanging CDA All parts included (i.e. multimedia) Links maintained Required Stylesheets included No change to existing references No change to XML ID attribute No restrictions on directory structure Document Metadata (state etc) included in transfer HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 148
179. Exchanging CDA in v2 MDM message OBX segment for document, TXA for metadata HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 149
180. MSH|... EVN|... PID|... PV1|... TXA|... OBX|1|ED|11492-6^History and Physical^LN|| ^multipart^related^A^ MIME-Version: 1.0 Content-Type: multipart/related; boundary="HL7-CDA-boundary"; type="text/xml"; start="10.12.45567.43" Content-Transfer-Encoding: BASE64 --HL7-CDA-boundary Content-Type: text/xml; charset="US-ASCII" Content-ID: <10.12.45567.43> ... Base 64 of base CDA document, which contains ... <observationMedia classCode="OBS" moodCode="EVN"> <id root="10.23.4567.345"/> <value mediaType="image/jpeg"> <reference value="left_hand_image.jpeg"/> </value> </observationMedia> ... --HL7-CDA-boundary Content-ID: <10.23.4567.345> Content-Location: canned_left_hand_image.jpeg Content-Type: image/JPEG ... Base64 image ... --HL7-CDA-boundary-- ... HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 150
181. Interoperability paradigms HL7 has 3 major interoperability paradigms: Messages Documents Services HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 151
182. Interoperability Paradigms Messages: Messages exchange documents around to build services Documents:Documents implement services when passed around in messages Services: Services exchange documents in messages HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 152
183. Interoperability Paradigms The 3 paradigms differ in the following: Who decides what happens Who decides what technology is used When the decisions are made When content is bound to business processes What is explicit in an exchange, and what is delegated to the trading agreement Approach the same place from different directions Document = late binding by humans HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 153
184. Document vs Workflow Documents do not convey instructions i.e. Record of prescription Document says “Adam Smith (pharmacist) to prescribe Lasix” Adam’s Pharmacy system receives a copy of document Is Adam authorised to prescribe to patient? No – the record of Adam being asked is not the same as asking Adam HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 154
185. Document vs Workflow Documents never convey instructions A wrapper may reference a section of the document and indicate it is an instruction The exchange needs some choreography to make this safe Multiple sources of choreography V2 / v3 / IHE / National Programmes Trading Partner Agreement HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 155
186. IHE XDS Cross-Enterprise(X) Document Sharing Distributed solution for sharing clinical documents Tailored for CDA (? exclusive) Scalable, Standards based Widely adopted HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 156
187. XDS Architecture HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 157
188. CDA vs HL7 v2 An article I wrote for Pulse in Australia(Healthcare IT magazine) Addresses the question of whether we should use CDA instead of HL7 for pathology reports 99+% of lab reports distributed using v2 HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 158
189. Is HL7 v2 enough? The industry is now close to achieving plug-and-play interoperability with regard to pathology and radiology reports. Increasingly I am hearing comments suggesting that the job is done, that we have met the industry needs, and that there is no need to consider further changes, at least for the time being. I hear these comments at industry groups, standards meetings, and in discussions with our customers. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 159
190. Reporting Requirements Fidelity – reporting conventions Structured Data – proper grouping, computable model Explicit link between presentation and data Multimedia support Cross-Industry standard formats Clearly understood responsibilities (for legal liability) Ability to integrate reports and reporting in a greater context HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 160
191. Advantages of CDA Clinical Safety Document Management Presentation Content Expressivity Alignment HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 161
192. Disadvantages of CDA Based on reference model CDA documents are big No skills in CDA Change Process scary HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 162
197. Not safeHL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 163
198. End of Day #1 Fundamentals of CDA What it is & what parts it has How to navigate the defining standards How/When to use CDA Tomorrow Mapping Data into CDA documents Understanding the XML CDA Tools HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 164
199. Day #2: Implementing CDA Mapping Data to CDA: NZ Example CDA XML Implementation Considerations Tools Many miscellanea HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 165
200. CDA Certification You sit a multi-choice exam. Requirements Read the CDA Specification Listen to this talk Attend the CDA tutorial at the Working Meeting It’s easy (David H says so!) Only at the Working Meeting (Come to Sydney…) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 166
201. How hard to implement CDA? Unconstrained CDA presents some challenges There is some additional complexity from CDA/RIM/Templates Requires buy in, commitment to architecture Saves more complexity in the long run Alternatives are even more unattractive Implementation Guides are your friend! You’ll get good at mapping…. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 167
202. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 168
203. Alternative? A patient should have had an immunisation as per a standard plan, but an alternative was given instead. Two records for an immunisation where an alternative was given: the original scheduled immunisation (where the completion status will be AG) and the actual alternative, where all the details will be complete and the indication will be stated. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 169
204. What is CDA to be used for? Submit to NIR: Immunization administered Immunization administered elsewhere Immunization Refused Opt out of NIR? Is Opt In/Out by patient or by immunization? HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 170
205. CDA Header Contents HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 171
206. CDA Sections Single Section vs. Multiple Sections Data/Entries go in the same section as the narrative Is it safe to extract the narrative & data apart from the rest of the document? Custom is that there will be a special section for immunizations (CCD) Sections need Loinc Codes (CCD code not suitable?) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 172
207. Entry – what Base Act? (1) Consider definitions HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 173
208. Entry – what base Act? (2) CCD: one or more supply or medication sections (either “Supply” or “SubstanceAdministration”) A medication activity (templateId 2.16.840.1.113883.10.20.1.24)is used to describe what is administered whereas a supply activity (templateId 2.16.840.1.113883.10.20.1.34) is used to describe what has been dispensed. Else consider other HL7 / IHE Igs Finally, look at available attributes HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 174
209. SubstanceAdministration HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 175
210. Candidate Mappings HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 176
211. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 177
212. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 178
213. Candidate Mappings HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 179
214. Remaining Mappings HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 180
215. Mapping Language What we’d really like would be a mapping language Express mappings formally Feed instance and mapping into an engine to transform from one model to another HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 181
216. Mapping Language Requirements Be Linked to a Semantic Model Have Well-Defined Meaning Be Semantically Expressive Be Easy to Understand and Review Be Easy to Write Have Static Validation Criteria Be Declarative rather than Procedural Be Executable Have Editing Support Have Automated Validation Be open and neutral, not proprietary HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 182
217. OpenEHR Archetypes OpenEHR defined ADL – “Archetype Definition Language” ADL and Static models are alternative syntaxes for very nearly the same thing ADL doesn’t allow choices at entry point Static Models have some artificial graphical restrictions Reference Model | Constraint | XML But the reference models differ greatly HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 183
220. Usage in templateHL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 184
221. CDA XML XML policy CDA XML Example CDA Schema Transform Schematron HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 185
222. XML NDR Specify the XML form Names & namespaces Attributes vs elements Compositional form i.e. schema form Naming & Design rules are highly controversial The NDR is not well documented. Use the schema as the final arbiter of XML format HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 186
223. General XML method Namespace = “urn:hl7-org:v3” Root element = “ClinicalDocument” XML Attributes for “Immutable RIM attributes” (no namespaces) XML elements for other attributes (1st) or associations (2nd) Choice naming complicated Data Types from XML Data Types HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 187
224. CDA Schemas CDA.xsd – empty pointer to main schema POCD_MT000040.xsd – HL7 meaningless identifier for CDA – main schema datatypes.xsd & datatypes-base.xsd – datatypes schemas Infrastucture root – not used Voc.xsd – vocabulary as xsd enumerations NarrativeBlock.xsd – text format specification HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 188
225. Schema Conformance “CDA instances are valid against the CDA Schema” Schema are not normative (except Narrative Block) Schema conformance is necessary but not sufficient “checking an instance against the CDA Schema is a surrogate for validating conformance against the normative XML ITS” HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 189
226. Extra Contents All associations have: nullFlavor (attribute) (not commonly used) realmCode (do not use) typeId (do not use) templateId ID Attribute (ObservationMedia, RegionOfInterest, Section) POCD_MT000040.RegionOfInterest.value Narrative Block Schema (ISO 21090) ED/ST content model HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 190
227. XML Design Principles HL7 Priorities: Density Human readability Validation & PSVI Missing: Computer Processibility HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 191
228. Schema and Extensions What to do about extensibility and schemas HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 192
229. Transform Simple Transform to convert CDA to XHTML The transform has known issues No registry of known issues exists, nor a registry of alternatives You can write your own Doing so may be a good idea HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 193
230. Schematron Abstract Rules in data types schema CCD.sch – CCD schematron Why no CCD schema? HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 194
232. ED Forms Plain Text Base64 content Embedded XML <example language="EN">This is some text</example> <example mediaType="image/jpeg" representation="B64"> omSJUEdmde … MIjdMDSsWdIJdksIJR3373jeu83== </example> <example mediaType="text/xhtml"> <html xmlns:xh="...“> </html> </example> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 196
234. Entry/Narrative Linking HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 198
235. Multimedia Linking HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 199
236. Multimedia Attachment renderMultiMedia refers to an observation media class Observation media Includes data directly in document refers to an attachment by a URL Possible schemes for URL Default http(s): / ftp: / file: / nfs: cid: - Mime Package Reference II reference HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 200
238. II Reference URL form is hl7-att:[II.literal]hl7-att:2.1.16.3.9.12345.2.39.3:ABC123 Attachment Id SHALL be globally unique Receiver stores attachment for later use Sender does not need to send again. Resolve against all stored attachments Forward references are allowed within an instance but not to other instances. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 202
239. Multimedia Attachment Store attachment inline in ED Store attachment in mime package with CDA Describe attachment as if it is in the same “place” as CDA, and require infrastructure to handle this Store attachment on some [globally] available server (by url or id) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 203
241. Renormalisation Relational databases should be normalised Normalization (can) increase efficiency and control Exchange formats are very denormalised HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 205
242. Security Considerations Possible sources of insecurity Alteration of document “in flight” Denial of service attacks Alteration of document in storage HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 206
243. Security Considerations No schema location or transform location in documents No general web protocols in attachments (cid: only) Strictly limited attachment types Pay special attention to length issues in implementation HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 207
244. Length No length limitations in CDA (none!) (unlike v2) Implementation Guides may fix lengths (not usual practice in HL7) v2 length practice is not really sustainable to v2.7 Always check anything you decompose into a relational database HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 208
245. v2 CDA migration Data comes inwards in both HL7 v2 and CDA. Data must be compared and/or reassembled from both Some CDA data has no equivalent in v2 (or vice versa) Other must be converted HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 209
246. Interconversion problems Inconsistent nullFlavor handling in v2 Scope mismatch between EI and II Mapping problems between CD and CWE FT Narrative (?) effectiveTime can’t be represented in v2 More mapping…. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 210
255. OWL toolsSpecifying Writing Transporting Transforming Storing Validating Displaying Mining/ Extraction HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 211
256. Implementing CDA? Biggest Issue: One profile / one set of templates Many Profiles / General CDA HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 212
257. RIMBAA matrix HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 213
258. Introducing greenCDA HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 214
259. The Problem Creation of an instance conforming to a particular CDA IG may require knowledge of: CDA R2 base specification; HL7 Version 3 data type specification; CDA templates defined in the particular IG; CDA templates referenced by the particular IG; Terminology code lists defined/referenced by the particular IG; Validation of an instance conforming to a particular CDA IG may require: W3C Schema validation; Schematron validation; HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 215
260. A Solution Create an “authoring schema” that simplifies the creation and validation of a particular CDA IG: Clinically meaningful XML element and attribute names; 100% transformable into conformant CDA IG; Hides certain CDA complexities (such as moodCodes, fixed attributes, etc). We call this strategy: greenCDA greenCDA schemas are modular, corresponding to CDA templates. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 216
261. The Process – build the greenCDA module HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 217
262. The Process – create a conformant instance HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 218
263. An example – build the greenCDA module Requirements greenCDAschema <result> <resultID> <resultDateTime> <resultType> <resultStatus> <resultValue> <resultInterpretation> <resultReferenceRange> </result> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 219
264. An example – create a conformant instance greenCDAinstance <result> <resultID> <resultDateTime> <resultType> <resultStatus> <resultValue> <resultInterpretation> <resultReferenceRange> </result> Conformant CDA instance HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 220
265. Methodology Begin with a complete set of data elements that need to be represented in CDA Must have business names and cardinality defined as well as a mapping to CDA constructs Example: HITSP C32/C83 Must include all required underlying CDA constructs HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 221
266. Methodology (cont) Create a simple XML structure based on the business names Stick to the basics of XML 1.0 + namespaces. Use minimal nesting Used primarily when constructs are repeatable, or for complex data types Lean towards elements vs. attributes Limit the use of complex types (don’t use them when a basic element definition will do the job). Facilitate the use of off the shelf XML data binding tools to make class generation easy in any programming language HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 222
267. Methodology (cont) Datatypes Datatypes will be bound early to avoid xsi:type Use elements and choice constructs where multiple datatypes are allowed For example: physicalQuantity or integer Datatypes will also be greened a bit to reduce complexity, but should be close to the base CDA types. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 223
268. Methodology (cont) Terminology Static value sets should be recorded in the XML schema Reduces (but does not entirely eliminate) the need for secondary validation Schematron and/or a terminology lookup service still needed for dynamic value sets HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 224
269. Methodology (cont) All GreenCDA modues must be transformable to full CDA Transform should be possible with XSLT (preferably 1.0) Source instance must contain sufficient data to populate all required CDA elements Some data may be implied by the constraints, so need not be physically present in the GreenCDA instance HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 225
270. Demonstration Instance Schema HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 226
271. Open Issues Issues with defining a greenCDA module? Consider adding business names into templates, so as to automate the greenCDA module generation. There are design considerations for the green modules in order to create corresponding java or dot net classes (that are used in the construction of a greenCDA instance). Formal definition of what needs to be defined up front to create a GreenCDA module The info in the HITSP C32/C83 tables is not 100% complete Goal is to support automation Narrative block Use existing CDA markup or XHTML? Is a narrative block required for all GreenCDA schemas? If optional, the CDA transform MUST have narrative generation capabilities. How does greenCDA overlap with other HL7 initiatives (microITS, hData, …)? What to include in the greenCDA for CCD Informative Ballot? Non-normative greenCDA xsd Corresponding non-normative greenCDA transform. Methodology that enables ability to transform any greenCDA instance into canonical form. Description of how local implementations can alter the greenCDA xsd if they want to extend; Make the point that greenCDA doesn’t even have to be XML, the xslt could instead be Java code, etc. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 227
272. What is required? <doc> <serviceEvent> <effectiveTimeLow value=“…”/> <effectiveTimeHigh value=“…”/> </serviceEvent> </doc> HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 228
273. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 229
274. Green CDA: Requirements Implementation Guide needs to be completely nailed down The more nailed down it is, the more useful Green CDA is The more nailed down the implementation guide is, the more specific to a particular use i.e. GreenCDA is a software methodology, not a ballotable standard HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 230
275. Validation Is CDA valid against the schema? Is the document valid against CDA? Are the data types valid? Is the document valid against it’s templates? Is the document valid against an implementation guide? HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 231
276. Validation Tools Schema +/- schematron Eclipse Instance Editor Alschuler Validator Templates Registry…. HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 232
277. Eclipse Instance Editor Demonstration HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 233
279. Template Registry Under development Database where CCD-type templates can be registered English definitions Schematrons Commercial(?) product from Alschuler Associates Will have a service API HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 235
288. OWL toolsSpecifying Writing Transporting Transforming Storing Validating Displaying Mining/ Extraction HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 236
289. Generation Language Demonstration (cda generation.ksp) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 237
290. HL7Connect V2 / CDA interface engine Free personal copy included on flash drive Only suitable for desktop / developer use HL7Connect COM library is free for use CDA reading / writing support CCD reading / writing support UCUM + LOINC Support Demonstration Knowledge base (UCUM / LOINC) + C# code HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 238
291. MIF “Model Interchange Format” HL7’s master internal format Not designed for production use But does contain all the definitions and documentation in one place And can be used by implementers HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 239
292. Implementing CDA Many meanings to “implement” Many ways to do things Constants: Knowledge of CDA specification Connectedness to CDA implementer community Ability to do mappings (analysis / implement) HL7 New Zealand - www.hl7.org.nz - Fundamentals of CDA & Implementing CDA (30-31 August 2010, Auckland) 240
Notas do Editor
Ancient historyCausing changeChoosing the right personPeople in standardsGrowing the workforce
3 sources of complexity (problem, business variability, incompetence / inappropriate solutions)Externalising complexityCompeting perspectives on simplicityBad metaphorsAll models are wrong
DisagreementAverage cost of existenceExamplesQualifications – not quite true