SGHI FHIR Profile Implementation Guide
0.1.0 - ci-build

SGHI FHIR Profile Implementation Guide, published by Kathurima Kimathi. This guide is not an authorized publication; it is the continuous build for version 0.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/savannahghi/sil_fhir_profile_ig/ and changes regularly. See the Directory of published versions

## : Composition Transforms: R4 to SGHI R5 - TTL Representation

Active as of 2026-05-21

Raw ttl | Download

    @prefix fhir: <http://hl7.org/fhir/> .
    @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 -------------------------------------------------------------------

     a fhir:StructureMap ;
      fhir:nodeRole fhir:treeRoot ;
      fhir:id [ fhir:v "Composition4toSGHI5"] ; #
      fhir:text [
    fhir:status [ fhir:v "generated" ] ;
    fhir:div [ fhir:v "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p class=\"res-header-id\"><b>Generated Narrative: StructureMap Composition4toSGHI5</b></p><a name=\"Composition4toSGHI5\"> </a><a name=\"hcComposition4toSGHI5\"> </a><pre class=\"fml\">#xD;\n<span style=\"color: #cc00cc\">/// <b>url</b> = </span><span style=\"color: blue\">'https://fhir.slade360.co.ke/fhir/StructureMap/Composition4toSGHI5'</span>#xD;\n<span style=\"color: #cc00cc\">/// <b>name</b> = </span><span style=\"color: blue\">'Composition4toSGHI5'</span>#xD;\n<span style=\"color: #cc00cc\">/// <b>title</b> = </span><span style=\"color: blue\">'Composition Transforms: R4 to SGHI R5'</span>#xD;\n<span style=\"color: #cc00cc\">/// <b>status</b> = </span><span style=\"color: blue\">'active'</span>#xD;\n#xD;\n<b>uses</b><span style=\"color: navy\"> \"</span>http://hl7.org/fhir/4.0/StructureDefinition/Composition<span style=\"color: navy\">\" </span><b>alias </b>CompositionR4 <b>as </b><b>source</b>#xD;\n<b>uses</b><span style=\"color: navy\"> \"</span><a href=\"StructureDefinition-composition.html\" title=\"SGHI Composition\">https://fhir.slade360.co.ke/fhir/StructureDefinition/composition</a><span style=\"color: navy\">\" </span><b>alias </b>SGHIComposition <b>as </b><b>target</b>#xD;\n#xD;\n<b>imports</b><span style=\"color: navy\"> \"</span>http://hl7.org/fhir/StructureMap/*4to5<span style=\"color: navy\">\"#xD;\n</span>#xD;\n<b>group </b>SGHIComposition<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span><span style=\"color: navy\"> : </span>CompositionR4, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\"> : </span>SGHIComposition<span style=\"color: navy\">)</span><b> &lt;&lt;type+&gt;&gt;</b><span style=\"color: navy\"> {#xD;\n</span>  src.id<b> as </b><span style=\"color: maroon\">uuid</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.id = <span style=\"color: maroon\">uuid</span><span style=\"color: navy\">;</span>#xD;\n  src.active<span style=\"color: navy\"><b> -&gt; </b></span>tgt.active<span style=\"color: navy\">;</span>#xD;\n  src.language<span style=\"color: navy\"><b> -&gt; </b></span>tgt.language<span style=\"color: navy\">;</span>#xD;\n  src<span style=\"color: navy\"><b> -&gt; </b></span>tgt.meta<b> as </b><span style=\"color: maroon\">t_meta</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>    src<span style=\"color: navy\"><b> -&gt; </b></span>t_meta.profile = <span style=\"color: blue\">'https://fhir.slade360.co.ke/fhir/StructureDefinition/composition'</span> <i>\"addprofile\"</i><span style=\"color: navy\">;</span>#xD;\n  <span style=\"color: navy\">}</span> <i>\"addtometa\"</i><span style=\"color: navy\">;</span>#xD;\n  src<b> where </b>text.exists().not()<span style=\"color: navy\"><b> -&gt; </b></span>tgt.text = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Narrative'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">t_text</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>    src<span style=\"color: navy\"><b> -&gt; </b></span>t_text.status = <span style=\"color: blue\">'generated'</span> <i>\"settextstatus\"</i><span style=\"color: navy\">;</span>#xD;\n    src<span style=\"color: navy\"><b> -&gt; </b></span>t_text.div = <span style=\"color: blue\">'&lt;div xmlns=\\\"http://www.w3.org/1999/xhtml\\\"&gt;&lt;h1&gt;Generated text&lt;/h1&gt;&lt;/div&gt;'</span> <i>\"settextdiv\"</i><span style=\"color: navy\">;</span>#xD;\n  <span style=\"color: navy\">}</span> <i>\"createhardcodedtext\"</i><span style=\"color: navy\">;</span>#xD;\n  src<span style=\"color: navy\"><b> -&gt; </b></span>tgt.text = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Narrative'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">ttt</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>    src.text<b> as </b><span style=\"color: maroon\">st</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>      st.status<b> as </b><span style=\"color: maroon\">s</span><span style=\"color: navy\"><b> -&gt; </b></span>ttt.status = <span style=\"color: maroon\">s</span><span style=\"color: navy\">;</span>#xD;\n      st.div<b> as </b><span style=\"color: maroon\">d</span><span style=\"color: navy\"><b> -&gt; </b></span>ttt.div = <span style=\"color: navy\">(</span>'&lt;div xmlns=\\\"http://www.w3.org/1999/xhtml\\\"&gt;&lt;p&gt;' + d + '&lt;/p&gt;&lt;/div&gt;'<span style=\"color: navy\">)</span> <i>\"wraptextinhtml\"</i><span style=\"color: navy\">;</span>#xD;\n    <span style=\"color: navy\">}</span><span style=\"color: navy\">;</span>#xD;\n  <span style=\"color: navy\">}</span> <i>\"setting text\"</i><span style=\"color: navy\">;</span>#xD;\n  src.id<b> as </b><span style=\"color: maroon\">s_id</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.identifier = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Identifier'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">t_ident</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>    s_id<b> as </b><span style=\"color: maroon\">uuid</span><span style=\"color: navy\"><b> -&gt; </b></span>t_ident.value = <span style=\"color: maroon\">uuid</span> <i>\"copyid\"</i><span style=\"color: navy\">;</span>#xD;\n    src<span style=\"color: navy\"><b> -&gt; </b></span>t_ident.use = <span style=\"color: blue\">'official'</span> <i>\"setuse\"</i><span style=\"color: navy\">;</span>#xD;\n    src<span style=\"color: navy\"><b> -&gt; </b></span>t_ident.system = <span style=\"color: blue\">'https://fhir.slade360.co.ke/fhir/CodeSystem/identifier-codesystem'</span> <i>\"setsystem\"</i><span style=\"color: navy\">;</span>#xD;\n    src<span style=\"color: navy\"><b> -&gt; </b></span>t_ident.type = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'CodeableConcept'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">t_type</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>      src<span style=\"color: navy\"><b> -&gt; </b></span>t_type.coding = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Coding'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">t_code</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>        src<span style=\"color: navy\"><b> -&gt; </b></span>t_code.system = <span style=\"color: blue\">'https://fhir.slade360.co.ke/fhir/CodeSystem/identifier-codesystem'</span> <i>\"typesystem\"</i><span style=\"color: navy\">;</span>#xD;\n        src<span style=\"color: navy\"><b> -&gt; </b></span>t_code.code = <span style=\"color: blue\">'fhir-id'</span> <i>\"typecode\"</i><span style=\"color: navy\">;</span>#xD;\n        src<span style=\"color: navy\"><b> -&gt; </b></span>t_code.display = <span style=\"color: blue\">'FHIR Id'</span> <i>\"typedisplay\"</i><span style=\"color: navy\">;</span>#xD;\n      <span style=\"color: navy\">}</span> <i>\"initcoding\"</i><span style=\"color: navy\">;</span>#xD;\n    <span style=\"color: navy\">}</span> <i>\"inittype\"</i><span style=\"color: navy\">;</span>#xD;\n    src.meta<b> as </b><span style=\"color: maroon\">sm</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>      sm.tag last<b> as </b><span style=\"color: maroon\">st</span><span style=\"color: navy\"><b> -&gt; </b></span>t_ident.assigner = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Reference'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">ta</span><b> then </b>TransformAssigner<span style=\"color: navy\">(</span><span style=\"color: maroon\">st</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">ta</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n    <span style=\"color: navy\">}</span> <i>\"setting owner\"</i><span style=\"color: navy\">;</span>#xD;\n  <span style=\"color: navy\">}</span> <i>\"addfhirididentifier\"</i><span style=\"color: navy\">;</span>#xD;\n  src.status<span style=\"color: navy\"><b> -&gt; </b></span>tgt.status<span style=\"color: navy\">;</span>#xD;\n  src.type<b> as </b><span style=\"color: maroon\">stype</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.type<b> as </b><span style=\"color: maroon\">ttype</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>    stype.coding<b> as </b><span style=\"color: maroon\">scoding</span><span style=\"color: navy\"><b> -&gt; </b></span>ttype.coding<b> as </b><span style=\"color: maroon\">tcoding</span><b> then </b>TransformCoding<span style=\"color: navy\">(</span><span style=\"color: maroon\">scoding</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">tcoding</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n    stype.text<span style=\"color: navy\"><b> -&gt; </b></span>ttype.text<span style=\"color: navy\">;</span>#xD;\n  <span style=\"color: navy\">}</span><span style=\"color: navy\">;</span>#xD;\n  src.category<b> as </b><span style=\"color: maroon\">sg</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.category<b> as </b><span style=\"color: maroon\">tg</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>    sg.coding<b> as </b><span style=\"color: maroon\">sc</span><span style=\"color: navy\"><b> -&gt; </b></span>tg.coding<b> as </b><span style=\"color: maroon\">tc</span><b> then </b>TransformCoding<span style=\"color: navy\">(</span><span style=\"color: maroon\">sc</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">tc</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n    sg.text<span style=\"color: navy\"><b> -&gt; </b></span>tg.text<span style=\"color: navy\">;</span>#xD;\n  <span style=\"color: navy\">}</span><span style=\"color: navy\">;</span>#xD;\n  src.author<b> as </b><span style=\"color: maroon\">sat</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.author<b> as </b><span style=\"color: maroon\">tat</span><b> then </b>TransformReference<span style=\"color: navy\">(</span><span style=\"color: maroon\">sat</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">tat</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n  src.subject<b> as </b><span style=\"color: maroon\">sb</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.subject<b> as </b><span style=\"color: maroon\">tb</span><b> then </b>TransformReference<span style=\"color: navy\">(</span><span style=\"color: maroon\">sb</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">tb</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n  src.encounter<b> as </b><span style=\"color: maroon\">se</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.encounter<b> as </b><span style=\"color: maroon\">te</span><b> then </b>TransformReference<span style=\"color: navy\">(</span><span style=\"color: maroon\">se</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">te</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n  src.title<span style=\"color: navy\"><b> -&gt; </b></span>tgt.name<span style=\"color: navy\">;</span>#xD;\n  src.title<span style=\"color: navy\"><b> -&gt; </b></span>tgt.title<span style=\"color: navy\">;</span>#xD;\n  src.date<span style=\"color: navy\"><b> -&gt; </b></span>tgt.date<span style=\"color: navy\">;</span>#xD;\n  src.section<b> as </b><span style=\"color: maroon\">sct</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.section<b> as </b><span style=\"color: maroon\">tct</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>    sct.author<b> as </b><span style=\"color: maroon\">sa</span><span style=\"color: navy\"><b> -&gt; </b></span>tct.author<b> as </b><span style=\"color: maroon\">ta</span><b> then </b>TransformReference<span style=\"color: navy\">(</span><span style=\"color: maroon\">sa</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">ta</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n    sct.code<b> as </b><span style=\"color: maroon\">scc</span><span style=\"color: navy\"><b> -&gt; </b></span>tct.code = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'CodeableConcept'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">tcc</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>      scc.coding<b> as </b><span style=\"color: maroon\">sc</span><span style=\"color: navy\"><b> -&gt; </b></span>tcc.coding<b> as </b><span style=\"color: maroon\">tc</span><b> then </b>TransformCoding<span style=\"color: navy\">(</span><span style=\"color: maroon\">sc</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">tc</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n    <span style=\"color: navy\">}</span><span style=\"color: navy\">;</span>#xD;\n    sct.text<b> as </b><span style=\"color: maroon\">sdiv</span><span style=\"color: navy\"><b> -&gt; </b></span>tct.text<b> as </b><span style=\"color: maroon\">tdiv</span><b> then</b><span style=\"color: navy\"> {#xD;\n</span>      sdiv.status<span style=\"color: navy\"><b> -&gt; </b></span>tdiv.status<span style=\"color: navy\">;</span>#xD;\n      sdiv.id<span style=\"color: navy\"><b> -&gt; </b></span>tdiv.id<span style=\"color: navy\">;</span>#xD;\n      sdiv.div<b> as </b><span style=\"color: maroon\">div</span><span style=\"color: navy\"><b> -&gt; </b></span>tdiv.div = <span style=\"color: navy\">(</span>'&lt;div xmlns=\\\"http://www.w3.org/1999/xhtml\\\"&gt;&lt;p&gt;' + div + '&lt;/p&gt;&lt;/div&gt;'<span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n    <span style=\"color: navy\">}</span><span style=\"color: navy\">;</span>#xD;\n    sct.title<span style=\"color: navy\"><b> -&gt; </b></span>tct.title<span style=\"color: navy\">;</span>#xD;\n  <span style=\"color: navy\">}</span><span style=\"color: navy\">;</span>#xD;\n<span style=\"color: navy\">}#xD;\n#xD;\n</span><b>group </b>TransformAssigner<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\">)</span><b> &lt;&lt;types&gt;&gt;</b><span style=\"color: navy\"> {#xD;\n</span>  src.code<b> as </b><span style=\"color: maroon\">code</span><span style=\"color: navy\"><b> -&gt; </b></span>tgt.reference = <b>append</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'Organization/'</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">code</span><span style=\"color: navy\">)</span><span style=\"color: navy\">;</span>#xD;\n  src<b> where </b>display.exists().not()<span style=\"color: navy\"><b> -&gt; </b></span>tgt.display = <span style=\"color: blue\">'Unknown display'</span> <i>\"setting default display\"</i><span style=\"color: navy\">;</span>#xD;\n  src.display<span style=\"color: navy\"><b> -&gt; </b></span>tgt.display<span style=\"color: navy\">;</span>#xD;\n  src.code<span style=\"color: navy\"><b> -&gt; </b></span>tgt.id<span style=\"color: navy\">;</span>#xD;\n<span style=\"color: navy\">}#xD;\n#xD;\n</span><b>group </b>TransformReference<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\">)</span><b> &lt;&lt;types&gt;&gt;</b><span style=\"color: navy\"> {#xD;\n</span>  src.id<span style=\"color: navy\"><b> -&gt; </b></span>tgt.id<span style=\"color: navy\">;</span>#xD;\n  src.reference<span style=\"color: navy\"><b> -&gt; </b></span>tgt.reference<span style=\"color: navy\">;</span>#xD;\n  src.display<span style=\"color: navy\"><b> -&gt; </b></span>tgt.display<span style=\"color: navy\">;</span>#xD;\n  src<b> where </b>display.exists().not()<span style=\"color: navy\"><b> -&gt; </b></span>tgt.display = <span style=\"color: blue\">'Unknown display'</span> <i>\"setting display\"</i><span style=\"color: navy\">;</span>#xD;\n<span style=\"color: navy\">}#xD;\n#xD;\n</span><b>group </b>TransformCoding<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\">)</span><b> &lt;&lt;types&gt;&gt;</b><span style=\"color: navy\"> {#xD;\n</span>  src.code<span style=\"color: navy\"><b> -&gt; </b></span>tgt.code<span style=\"color: navy\">;</span>#xD;\n  src.display<span style=\"color: navy\"><b> -&gt; </b></span>tgt.display<span style=\"color: navy\">;</span>#xD;\n  src<b> where </b>display.exists().not()<span style=\"color: navy\"><b> -&gt; </b></span>tgt.display = <span style=\"color: blue\">'Unknown display'</span> <i>\"settingdefaultdisplay\"</i><span style=\"color: navy\">;</span>#xD;\n  src.system<span style=\"color: navy\"><b> -&gt; </b></span>tgt.system = <span style=\"color: blue\">'http://loinc.org'</span><span style=\"color: navy\">;</span>#xD;\n<span style=\"color: navy\">}#xD;\n#xD;\n</span></pre></div>"^^rdf:XMLLiteral ]
      ] ; #
      fhir:url [
    fhir:v "https://fhir.slade360.co.ke/fhir/StructureMap/Composition4toSGHI5"^^xsd:anyURI ;
    fhir:l <https://fhir.slade360.co.ke/fhir/StructureMap/Composition4toSGHI5>
      ] ; #
      fhir:version [ fhir:v "0.1.0"] ; #
      fhir:name [ fhir:v "Composition4toSGHI5"] ; #
      fhir:title [ fhir:v "Composition Transforms: R4 to SGHI R5"] ; #
      fhir:status [ fhir:v "active"] ; #
      fhir:date [ fhir:v "2026-05-21T09:38:13+00:00"^^xsd:dateTime] ; #
      fhir:publisher [ fhir:v "Kathurima Kimathi"] ; #
      fhir:contact ( [
    fhir:name [ fhir:v "Kathurima Kimathi" ] ;
        ( fhir:telecom [
    fhir:system [ fhir:v "url" ] ;
    fhir:value [ fhir:v "https://www.linkedin.com/in/kathurima-kimathi/" ]     ] [
    fhir:system [ fhir:v "email" ] ;
    fhir:value [ fhir:v "kathurimakimathi415@gmail.com" ]     ] )
      ] [
    fhir:name [ fhir:v "Oscar John" ] ;
        ( fhir:telecom [
    fhir:system [ fhir:v "email" ] ;
    fhir:value [ fhir:v "oscarjohnotieno@gmail.com" ] ;
    fhir:use [ fhir:v "work" ]     ] )
      ] [
    fhir:name [ fhir:v "Kennedy Omondi" ] ;
        ( fhir:telecom [
    fhir:system [ fhir:v "email" ] ;
    fhir:value [ fhir:v "kennankole@gmail.com" ] ;
    fhir:use [ fhir:v "work" ]     ] )
      ] ) ; #
      fhir:description [ fhir:v "CompositionTransformsR4toSGHIR5"] ; #
      fhir:structure ( [
    fhir:url [
    fhir:v "http://hl7.org/fhir/4.0/StructureDefinition/Composition"^^xsd:anyURI ;
    fhir:l <http://hl7.org/fhir/4.0/StructureDefinition/Composition>     ] ;
    fhir:mode [ fhir:v "source" ] ;
    fhir:alias [ fhir:v "CompositionR4" ]
      ] [
    fhir:url [
    fhir:v "https://fhir.slade360.co.ke/fhir/StructureDefinition/composition"^^xsd:anyURI ;
    fhir:l <https://fhir.slade360.co.ke/fhir/StructureDefinition/composition>     ] ;
    fhir:mode [ fhir:v "target" ] ;
    fhir:alias [ fhir:v "SGHIComposition" ]
      ] ) ; #
      fhir:import ( [
    fhir:v "http://hl7.org/fhir/StructureMap/*4to5"^^xsd:anyURI ;
    fhir:l <http://hl7.org/fhir/StructureMap/*4to5>
      ] ) ; #
      fhir:group ( [
    fhir:name [ fhir:v "SGHIComposition" ] ;
    fhir:typeMode [ fhir:v "type-and-types" ] ;
        ( fhir:input [
    fhir:name [ fhir:v "src" ] ;
    fhir:type [ fhir:v "CompositionR4" ] ;
    fhir:mode [ fhir:v "source" ]     ] [
    fhir:name [ fhir:v "tgt" ] ;
    fhir:type [ fhir:v "SGHIComposition" ] ;
    fhir:mode [ fhir:v "target" ]     ] ) ;
        ( fhir:rule [
    fhir:name [ fhir:v "id" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:variable [ fhir:v "uuid" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:transform [ fhir:v "copy" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "uuid"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "active" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "active" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "active" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "language" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "language" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "language" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "addtometa" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "meta" ] ;
    fhir:variable [ fhir:v "t_meta" ]       ] ) ;
          ( fhir:rule [
    fhir:name [ fhir:v "addprofile" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "t_meta" ] ;
    fhir:element [ fhir:v "profile" ] ;
    fhir:transform [ fhir:v "copy" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "https://fhir.slade360.co.ke/fhir/StructureDefinition/composition"             ]           ] )         ] )       ] )     ] [
    fhir:name [ fhir:v "createhardcodedtext" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:condition [ fhir:v "text.exists().not()" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "t_text" ] ;
    fhir:transform [ fhir:v "create" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Narrative"           ]         ] )       ] ) ;
          ( fhir:rule [
    fhir:name [ fhir:v "settextstatus" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "t_text" ] ;
    fhir:element [ fhir:v "status" ] ;
    fhir:transform [ fhir:v "copy" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "generated"             ]           ] )         ] )       ] [
    fhir:name [ fhir:v "settextdiv" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "t_text" ] ;
    fhir:element [ fhir:v "div" ] ;
    fhir:transform [ fhir:v "copy" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "<div xmlns=\"http://www.w3.org/1999/xhtml\"><h1>Generated text</h1></div>"             ]           ] )         ] )       ] )     ] [
    fhir:name [ fhir:v "setting text" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "ttt" ] ;
    fhir:transform [ fhir:v "create" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Narrative"           ]         ] )       ] ) ;
          ( fhir:rule [
    fhir:name [ fhir:v "text" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "st" ]         ] ) ;
            ( fhir:rule [
    fhir:name [ fhir:v "status" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "st" ] ;
    fhir:element [ fhir:v "status" ] ;
    fhir:variable [ fhir:v "s" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "ttt" ] ;
    fhir:element [ fhir:v "status" ] ;
    fhir:transform [ fhir:v "copy" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "s"               ]             ] )           ] )         ] [
    fhir:name [ fhir:v "wraptextinhtml" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "st" ] ;
    fhir:element [ fhir:v "div" ] ;
    fhir:variable [ fhir:v "d" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "ttt" ] ;
    fhir:element [ fhir:v "div" ] ;
    fhir:transform [ fhir:v "evaluate" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "'<div xmlns=\\\"http://www.w3.org/1999/xhtml\\\"><p>' + d + '</p></div>'"               ]             ] )           ] )         ] )       ] )     ] [
    fhir:name [ fhir:v "addfhirididentifier" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:variable [ fhir:v "s_id" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "identifier" ] ;
    fhir:variable [ fhir:v "t_ident" ] ;
    fhir:transform [ fhir:v "create" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Identifier"           ]         ] )       ] ) ;
          ( fhir:rule [
    fhir:name [ fhir:v "copyid" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "s_id" ] ;
    fhir:variable [ fhir:v "uuid" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "t_ident" ] ;
    fhir:element [ fhir:v "value" ] ;
    fhir:transform [ fhir:v "copy" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "uuid"             ]           ] )         ] )       ] [
    fhir:name [ fhir:v "setuse" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "t_ident" ] ;
    fhir:element [ fhir:v "use" ] ;
    fhir:transform [ fhir:v "copy" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "official"             ]           ] )         ] )       ] [
    fhir:name [ fhir:v "setsystem" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "t_ident" ] ;
    fhir:element [ fhir:v "system" ] ;
    fhir:transform [ fhir:v "copy" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "https://fhir.slade360.co.ke/fhir/CodeSystem/identifier-codesystem"             ]           ] )         ] )       ] [
    fhir:name [ fhir:v "inittype" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "t_ident" ] ;
    fhir:element [ fhir:v "type" ] ;
    fhir:variable [ fhir:v "t_type" ] ;
    fhir:transform [ fhir:v "create" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "CodeableConcept"             ]           ] )         ] ) ;
            ( fhir:rule [
    fhir:name [ fhir:v "initcoding" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "src" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "t_type" ] ;
    fhir:element [ fhir:v "coding" ] ;
    fhir:variable [ fhir:v "t_code" ] ;
    fhir:transform [ fhir:v "create" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Coding"               ]             ] )           ] ) ;
              ( fhir:rule [
    fhir:name [ fhir:v "typesystem" ] ;
                ( fhir:source [
    fhir:context [ fhir:v "src" ]             ] ) ;
                ( fhir:target [
    fhir:context [ fhir:v "t_code" ] ;
    fhir:element [ fhir:v "system" ] ;
    fhir:transform [ fhir:v "copy" ] ;
                  ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "https://fhir.slade360.co.ke/fhir/CodeSystem/identifier-codesystem"                 ]               ] )             ] )           ] [
    fhir:name [ fhir:v "typecode" ] ;
                ( fhir:source [
    fhir:context [ fhir:v "src" ]             ] ) ;
                ( fhir:target [
    fhir:context [ fhir:v "t_code" ] ;
    fhir:element [ fhir:v "code" ] ;
    fhir:transform [ fhir:v "copy" ] ;
                  ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "fhir-id"                 ]               ] )             ] )           ] [
    fhir:name [ fhir:v "typedisplay" ] ;
                ( fhir:source [
    fhir:context [ fhir:v "src" ]             ] ) ;
                ( fhir:target [
    fhir:context [ fhir:v "t_code" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:transform [ fhir:v "copy" ] ;
                  ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "FHIR Id"                 ]               ] )             ] )           ] )         ] )       ] [
    fhir:name [ fhir:v "setting owner" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "meta" ] ;
    fhir:variable [ fhir:v "sm" ]         ] ) ;
            ( fhir:rule [
    fhir:name [ fhir:v "tag" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "sm" ] ;
    fhir:element [ fhir:v "tag" ] ;
    fhir:listMode [ fhir:v "last" ] ;
    fhir:variable [ fhir:v "st" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "t_ident" ] ;
    fhir:element [ fhir:v "assigner" ] ;
    fhir:variable [ fhir:v "ta" ] ;
    fhir:transform [ fhir:v "create" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Reference"               ]             ] )           ] ) ;
              ( fhir:dependent [
    fhir:name [ fhir:v "TransformAssigner" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "st"               ]             ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "ta"               ]             ] )           ] )         ] )       ] )     ] [
    fhir:name [ fhir:v "status" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "status" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "status" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "type" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "type" ] ;
    fhir:variable [ fhir:v "stype" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "type" ] ;
    fhir:variable [ fhir:v "ttype" ]       ] ) ;
          ( fhir:rule [
    fhir:name [ fhir:v "coding" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "stype" ] ;
    fhir:element [ fhir:v "coding" ] ;
    fhir:variable [ fhir:v "scoding" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "ttype" ] ;
    fhir:element [ fhir:v "coding" ] ;
    fhir:variable [ fhir:v "tcoding" ]         ] ) ;
            ( fhir:dependent [
    fhir:name [ fhir:v "TransformCoding" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "scoding"             ]           ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "tcoding"             ]           ] )         ] )       ] [
    fhir:name [ fhir:v "text" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "stype" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "vvv" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "ttype" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]         ] ) ;
            ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"             ]           ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"             ]           ] )         ] )       ] )     ] [
    fhir:name [ fhir:v "category" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "category" ] ;
    fhir:variable [ fhir:v "sg" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "category" ] ;
    fhir:variable [ fhir:v "tg" ]       ] ) ;
          ( fhir:rule [
    fhir:name [ fhir:v "coding" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "sg" ] ;
    fhir:element [ fhir:v "coding" ] ;
    fhir:variable [ fhir:v "sc" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "tg" ] ;
    fhir:element [ fhir:v "coding" ] ;
    fhir:variable [ fhir:v "tc" ]         ] ) ;
            ( fhir:dependent [
    fhir:name [ fhir:v "TransformCoding" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "sc"             ]           ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "tc"             ]           ] )         ] )       ] [
    fhir:name [ fhir:v "text" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "sg" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "vvv" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "tg" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]         ] ) ;
            ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"             ]           ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"             ]           ] )         ] )       ] )     ] [
    fhir:name [ fhir:v "author" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "author" ] ;
    fhir:variable [ fhir:v "sat" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "author" ] ;
    fhir:variable [ fhir:v "tat" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "TransformReference" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "sat"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "tat"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "subject" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "subject" ] ;
    fhir:variable [ fhir:v "sb" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "subject" ] ;
    fhir:variable [ fhir:v "tb" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "TransformReference" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "sb"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "tb"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "encounter" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "encounter" ] ;
    fhir:variable [ fhir:v "se" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "encounter" ] ;
    fhir:variable [ fhir:v "te" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "TransformReference" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "se"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "te"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "title" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "title" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "name" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "title" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "title" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "title" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "date" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "date" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "date" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "section" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "section" ] ;
    fhir:variable [ fhir:v "sct" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "section" ] ;
    fhir:variable [ fhir:v "tct" ]       ] ) ;
          ( fhir:rule [
    fhir:name [ fhir:v "author" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "sct" ] ;
    fhir:element [ fhir:v "author" ] ;
    fhir:variable [ fhir:v "sa" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "tct" ] ;
    fhir:element [ fhir:v "author" ] ;
    fhir:variable [ fhir:v "ta" ]         ] ) ;
            ( fhir:dependent [
    fhir:name [ fhir:v "TransformReference" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "sa"             ]           ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "ta"             ]           ] )         ] )       ] [
    fhir:name [ fhir:v "code" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "sct" ] ;
    fhir:element [ fhir:v "code" ] ;
    fhir:variable [ fhir:v "scc" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "tct" ] ;
    fhir:element [ fhir:v "code" ] ;
    fhir:variable [ fhir:v "tcc" ] ;
    fhir:transform [ fhir:v "create" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "CodeableConcept"             ]           ] )         ] ) ;
            ( fhir:rule [
    fhir:name [ fhir:v "coding" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "scc" ] ;
    fhir:element [ fhir:v "coding" ] ;
    fhir:variable [ fhir:v "sc" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "tcc" ] ;
    fhir:element [ fhir:v "coding" ] ;
    fhir:variable [ fhir:v "tc" ]           ] ) ;
              ( fhir:dependent [
    fhir:name [ fhir:v "TransformCoding" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "sc"               ]             ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "tc"               ]             ] )           ] )         ] )       ] [
    fhir:name [ fhir:v "text" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "sct" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "sdiv" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "tct" ] ;
    fhir:element [ fhir:v "text" ] ;
    fhir:variable [ fhir:v "tdiv" ]         ] ) ;
            ( fhir:rule [
    fhir:name [ fhir:v "status" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "sdiv" ] ;
    fhir:element [ fhir:v "status" ] ;
    fhir:variable [ fhir:v "vvv" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "tdiv" ] ;
    fhir:element [ fhir:v "status" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]           ] ) ;
              ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"               ]             ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"               ]             ] )           ] )         ] [
    fhir:name [ fhir:v "id" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "sdiv" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:variable [ fhir:v "vvv" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "tdiv" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]           ] ) ;
              ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"               ]             ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"               ]             ] )           ] )         ] [
    fhir:name [ fhir:v "div" ] ;
              ( fhir:source [
    fhir:context [ fhir:v "sdiv" ] ;
    fhir:element [ fhir:v "div" ] ;
    fhir:variable [ fhir:v "div" ]           ] ) ;
              ( fhir:target [
    fhir:context [ fhir:v "tdiv" ] ;
    fhir:element [ fhir:v "div" ] ;
    fhir:transform [ fhir:v "evaluate" ] ;
                ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "'<div xmlns=\\\"http://www.w3.org/1999/xhtml\\\"><p>' + div + '</p></div>'"               ]             ] )           ] )         ] )       ] [
    fhir:name [ fhir:v "title" ] ;
            ( fhir:source [
    fhir:context [ fhir:v "sct" ] ;
    fhir:element [ fhir:v "title" ] ;
    fhir:variable [ fhir:v "vvv" ]         ] ) ;
            ( fhir:target [
    fhir:context [ fhir:v "tct" ] ;
    fhir:element [ fhir:v "title" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]         ] ) ;
            ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
              ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"             ]           ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"             ]           ] )         ] )       ] )     ] )
      ] [
    fhir:name [ fhir:v "TransformAssigner" ] ;
    fhir:typeMode [ fhir:v "types" ] ;
        ( fhir:input [
    fhir:name [ fhir:v "src" ] ;
    fhir:mode [ fhir:v "source" ]     ] [
    fhir:name [ fhir:v "tgt" ] ;
    fhir:mode [ fhir:v "target" ]     ] ) ;
        ( fhir:rule [
    fhir:name [ fhir:v "code" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "code" ] ;
    fhir:variable [ fhir:v "code" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "reference" ] ;
    fhir:transform [ fhir:v "append" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Organization/"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "code"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "setting default display" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:condition [ fhir:v "display.exists().not()" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:transform [ fhir:v "copy" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Unknown display"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "display" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "code" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "code" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] )
      ] [
    fhir:name [ fhir:v "TransformReference" ] ;
    fhir:typeMode [ fhir:v "types" ] ;
        ( fhir:input [
    fhir:name [ fhir:v "src" ] ;
    fhir:mode [ fhir:v "source" ]     ] [
    fhir:name [ fhir:v "tgt" ] ;
    fhir:mode [ fhir:v "target" ]     ] ) ;
        ( fhir:rule [
    fhir:name [ fhir:v "id" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "id" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "reference" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "reference" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "reference" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "display" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "setting display" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:condition [ fhir:v "display.exists().not()" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:transform [ fhir:v "copy" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Unknown display"           ]         ] )       ] )     ] )
      ] [
    fhir:name [ fhir:v "TransformCoding" ] ;
    fhir:typeMode [ fhir:v "types" ] ;
        ( fhir:input [
    fhir:name [ fhir:v "src" ] ;
    fhir:mode [ fhir:v "source" ]     ] [
    fhir:name [ fhir:v "tgt" ] ;
    fhir:mode [ fhir:v "target" ]     ] ) ;
        ( fhir:rule [
    fhir:name [ fhir:v "code" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "code" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "code" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "display" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:variable [ fhir:v "vvv" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:variable [ fhir:v "vvv" ] ;
    fhir:transform [ fhir:v "create" ]       ] ) ;
          ( fhir:dependent [
    fhir:name [ fhir:v "DefaultMappingGroupAnonymousAlias" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] [
    fhir:value [
    a fhir:Id ;
    fhir:v "vvv"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "settingdefaultdisplay" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:condition [ fhir:v "display.exists().not()" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "display" ] ;
    fhir:transform [ fhir:v "copy" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "Unknown display"           ]         ] )       ] )     ] [
    fhir:name [ fhir:v "system" ] ;
          ( fhir:source [
    fhir:context [ fhir:v "src" ] ;
    fhir:element [ fhir:v "system" ]       ] ) ;
          ( fhir:target [
    fhir:context [ fhir:v "tgt" ] ;
    fhir:element [ fhir:v "system" ] ;
    fhir:transform [ fhir:v "copy" ] ;
            ( fhir:parameter [
    fhir:value [
    a fhir:String ;
    fhir:v "http://loinc.org"           ]         ] )       ] )     ] )
      ] ) . #