Canonical Resource Management Infrastructure Implementation Guide
1.0.0 - STU1

Publication Build: This will be filled in by the publication tooling

## : Example Logic Library - Module Definition - TTL Representation

Active as of 2019-09-03

Raw ttl | Download

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

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

     a fhir:Library ;
      fhir:nodeRole fhir:treeRoot ;
      fhir:id [ fhir:v "moduledefinition-example"] ; #
      fhir:meta [
        ( fhir:profile [
    fhir:v "http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-moduledefinitionlibrary"^^xsd:anyURI ;
    fhir:link <http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-moduledefinitionlibrary>     ] )
      ] ; #
      fhir:text [
    fhir:status [ fhir:v "generated" ] ;
    fhir:div "<div xmlns=\"http://www.w3.org/1999/xhtml\"><h2>Related Artifacts</h2><table class=\"grid\"><tr><td>depends-on</td><td>FHIR model information</td><td><code>http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1</code></td></tr><tr><td>depends-on</td><td>Library FHIRHelpers</td><td><code>http://fhir.org/guides/cqf/common/Library/FHIRHelpers|4.0.1</code></td></tr><tr><td>depends-on</td><td>Code system Diagnosis Role</td><td><a href=\"http://terminology.hl7.org/5.5.0/CodeSystem-diagnosis-role.html\">Diagnosis Role</a></td></tr><tr><td>depends-on</td><td>Value set Emergency Department Visit</td><td><code>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292</code></td></tr><tr><td>depends-on</td><td>Value set Psychiatric/Mental Health Patient</td><td><code>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299</code></td></tr><tr><td>depends-on</td><td>Value set Hospital Settings</td><td><code>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126</code></td></tr><tr><td>depends-on</td><td>Value set ONC Administrative Sex</td><td><code>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1</code></td></tr><tr><td>depends-on</td><td>Value set Race</td><td><code>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836</code></td></tr><tr><td>depends-on</td><td>Value set Ethnicity</td><td><code>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837</code></td></tr><tr><td>depends-on</td><td>Value set Payer</td><td><code>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591</code></td></tr></table><h2>Parameters</h2><table class=\"grid\"><tr><td>Measurement Period</td><td>in</td><td>0</td><td>1</td><td>Period</td></tr><tr><td>Patient</td><td>out</td><td>0</td><td>1</td><td>Patient</td></tr><tr><td>Inpatient Encounter</td><td>out</td><td>0</td><td>*</td><td>Encounter</td></tr><tr><td>Initial Population</td><td>out</td><td>0</td><td>*</td><td>Encounter</td></tr><tr><td>Measure Population</td><td>out</td><td>0</td><td>*</td><td>Encounter</td></tr><tr><td>Stratifier 1</td><td>out</td><td>0</td><td>*</td><td>Encounter</td></tr><tr><td>Stratifier 2</td><td>out</td><td>0</td><td>*</td><td>Encounter</td></tr><tr><td>Stratifier 3</td><td>out</td><td>0</td><td>*</td><td>Encounter</td></tr><tr><td>Stratifier 4</td><td>out</td><td>0</td><td>*</td><td>Encounter</td></tr><tr><td>SDE Ethnicity</td><td>out</td><td>0</td><td>*</td><td>Coding</td></tr><tr><td>SDE Payer</td><td>out</td><td>0</td><td>*</td><td>Resource</td></tr><tr><td>SDE Race</td><td>out</td><td>0</td><td>*</td><td>Coding</td></tr><tr><td>SDE Sex</td><td>out</td><td>0</td><td>1</td><td>Coding</td></tr></table><h2>Data Requirements</h2><table class=\"grid\"><tr><td colspan=\"2\"><b>Type</b>: <a href=\"http://hl7.org/fhir/R4/patient.html\">Patient</a> (http://example.org/fhir/us/qicore/StructureDefinition/qicore-patient)</td></tr></table><table class=\"grid\"><tr><td colspan=\"2\"><b>Type</b>: <a href=\"http://hl7.org/fhir/R4/encounter.html\">Encounter</a> (http://example.org/fhir/us/qicore/StructureDefinition/qicore-encounter)</td></tr><tr style=\"background-color: #efefef\"><td>Filter</td><td>Value</td></tr><tr><td>type</td><td>In ValueSet <a href=\"http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292\">http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292</a></td></tr></table><table class=\"grid\"><tr><td colspan=\"2\"><b>Type</b>: <a href=\"http://hl7.org/fhir/R4/condition.html\">Condition</a> (http://example.org/fhir/us/qicore/StructureDefinition/qicore-Condition)</td></tr><tr style=\"background-color: #efefef\"><td>Filter</td><td>Value</td></tr><tr><td>id</td><td>One of these codes: </td></tr></table><table class=\"grid\"><tr><td colspan=\"2\"><b>Type</b>: <a href=\"http://hl7.org/fhir/R4/coverage.html\">Coverage</a> (http://example.org/fhir/us/qicore/StructureDefinition/qicore-coverage)</td></tr><tr style=\"background-color: #efefef\"><td>Filter</td><td>Value</td></tr><tr><td>type</td><td>In ValueSet <a href=\"http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591\">http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591</a></td></tr></table><h2>Contents</h2></div>"
      ] ; #
      fhir:url [ fhir:v "http://hl7.org/fhir/uv/crmi/Library/moduledefinition-example"^^xsd:anyURI] ; #
      fhir:identifier ( [
    fhir:use [ fhir:v "official" ] ;
    fhir:system [ fhir:v "http://example.org/fhir/cqi/ecqm/Library/Identifier"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "EXMLogic" ]
      ] [
    fhir:system [ fhir:v "urn:ietf:rfc:3986"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "urn:oid:2.16.840.1.113883.4.642.40.38.28.7" ]
      ] ) ; #
      fhir:version [ fhir:v "1.0.0"] ; #
      fhir:name [ fhir:v "EXMLogicModuleDefinition"] ; #
      fhir:title [ fhir:v "Example Logic Library - Module Definition"] ; #
      fhir:status [ fhir:v "active"] ; #
      fhir:experimental [ fhir:v "true"^^xsd:boolean] ; #
      fhir:type [
        ( fhir:coding [
    fhir:system [ fhir:v "http://terminology.hl7.org/CodeSystem/library-type"^^xsd:anyURI ] ;
    fhir:code [ fhir:v "module-definition" ]     ] )
      ] ; #
      fhir:date [ fhir:v "2019-09-03"^^xsd:date] ; #
      fhir:publisher [ fhir:v "HL7 International / Clinical Decision Support"] ; #
      fhir:contact ( [
        ( fhir:telecom [
    fhir:system [ fhir:v "url" ] ;
    fhir:value [ fhir:v "http://www.hl7.org/Special/committees/dss" ]     ] )
      ] ) ; #
      fhir:description [ fhir:v "This library is used as an example module definition in the FHIR Quality Measure Implementation Guide"] ; #
      fhir:jurisdiction ( [
        ( fhir:coding [
    fhir:system [ fhir:v "http://unstats.un.org/unsd/methods/m49/m49.htm"^^xsd:anyURI ] ;
    fhir:code [ fhir:v "001" ] ;
    fhir:display [ fhir:v "World" ]     ] )
      ] ) ; #
      fhir:relatedArtifact ( [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "FHIR model information" ] ;
    fhir:resource [
    fhir:v "http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1"^^xsd:anyURI ;
    fhir:link <http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Library FHIRHelpers" ] ;
    fhir:resource [
    fhir:v "http://fhir.org/guides/cqf/common/Library/FHIRHelpers|4.0.1"^^xsd:anyURI ;
    fhir:link <http://fhir.org/guides/cqf/common/Library/FHIRHelpers|4.0.1>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Code system Diagnosis Role" ] ;
    fhir:resource [
    fhir:v "http://terminology.hl7.org/CodeSystem/diagnosis-role"^^xsd:anyURI ;
    fhir:link <http://terminology.hl7.org/CodeSystem/diagnosis-role>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Value set Emergency Department Visit" ] ;
    fhir:resource [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Value set Psychiatric/Mental Health Patient" ] ;
    fhir:resource [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Value set Hospital Settings" ] ;
    fhir:resource [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Value set ONC Administrative Sex" ] ;
    fhir:resource [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Value set Race" ] ;
    fhir:resource [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Value set Ethnicity" ] ;
    fhir:resource [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837>     ]
      ] [
    fhir:type [ fhir:v "depends-on" ] ;
    fhir:display [ fhir:v "Value set Payer" ] ;
    fhir:resource [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591>     ]
      ] ) ; #
      fhir:parameter ( [
    fhir:name [ fhir:v "Measurement Period" ] ;
    fhir:use [ fhir:v "in" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "1" ] ;
    fhir:type [ fhir:v "Period" ]
      ] [
    fhir:name [ fhir:v "Patient" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "1" ] ;
    fhir:type [ fhir:v "Patient" ]
      ] [
    fhir:name [ fhir:v "Inpatient Encounter" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Encounter" ]
      ] [
    fhir:name [ fhir:v "Initial Population" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Encounter" ]
      ] [
    fhir:name [ fhir:v "Measure Population" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Encounter" ]
      ] [
    fhir:name [ fhir:v "Stratifier 1" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Encounter" ]
      ] [
    fhir:name [ fhir:v "Stratifier 2" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Encounter" ]
      ] [
    fhir:name [ fhir:v "Stratifier 3" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Encounter" ]
      ] [
    fhir:name [ fhir:v "Stratifier 4" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Encounter" ]
      ] [
    fhir:name [ fhir:v "SDE Ethnicity" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Coding" ]
      ] [
    fhir:name [ fhir:v "SDE Payer" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Resource" ]
      ] [
    fhir:name [ fhir:v "SDE Race" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "*" ] ;
    fhir:type [ fhir:v "Coding" ]
      ] [
    fhir:name [ fhir:v "SDE Sex" ] ;
    fhir:use [ fhir:v "out" ] ;
    fhir:min [ fhir:v "0"^^xsd:integer ] ;
    fhir:max [ fhir:v "1" ] ;
    fhir:type [ fhir:v "Coding" ]
      ] ) ; #
      fhir:dataRequirement ( [
        ( fhir:extension [
    fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/cqf-fhirQueryPattern"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "Patient?_id={{context.patientId}}" ]     ] ) ;
    fhir:type [ fhir:v "Patient" ] ;
        ( fhir:profile [
    fhir:v "http://example.org/fhir/us/qicore/StructureDefinition/qicore-patient"^^xsd:anyURI ;
    fhir:link <http://example.org/fhir/us/qicore/StructureDefinition/qicore-patient>     ] ) ;
        ( fhir:mustSupport [
    fhir:v "extension('http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity')" ;
          ( fhir:extension [
    fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/rendered-value"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "ethnicity" ]       ] )     ] )
      ] [
        ( fhir:extension [
    fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/cqf-fhirQueryPattern"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "Encounter?status=finished&subject=Patient/{{context.patientId}}&type:in=http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292" ]     ] [
    fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/cqf-isSelective"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "true"^^xsd:boolean ]     ] [
          ( fhir:extension [
    fhir:url [ fhir:v "path"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "status" ]       ] [
    fhir:url [ fhir:v "comparator"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "eq" ]       ] [
    fhir:url [ fhir:v "value"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "finished" ]       ] ) ;
    fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/cqf-valueFilter"^^xsd:anyURI ]     ] ) ;
    fhir:type [ fhir:v "Encounter" ] ;
        ( fhir:profile [
    fhir:v "http://example.org/fhir/us/qicore/StructureDefinition/qicore-encounter"^^xsd:anyURI ;
    fhir:link <http://example.org/fhir/us/qicore/StructureDefinition/qicore-encounter>     ] ) ;
        ( fhir:codeFilter [
    fhir:path [ fhir:v "type" ] ;
    fhir:valueSet [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292>       ]     ] )
      ] [
    fhir:type [ fhir:v "Condition" ] ;
        ( fhir:profile [
    fhir:v "http://example.org/fhir/us/qicore/StructureDefinition/qicore-Condition"^^xsd:anyURI ;
    fhir:link <http://example.org/fhir/us/qicore/StructureDefinition/qicore-Condition>     ] ) ;
        ( fhir:codeFilter [
    fhir:path [ fhir:v "id" ]     ] )
      ] [
        ( fhir:extension [
    fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/cqf-fhirQueryPattern"^^xsd:anyURI ] ;
    fhir:value [ fhir:v "Coverage?policy-holder=Patient/{{context.patientId}}&type:in=http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591" ]     ] ) ;
    fhir:type [ fhir:v "Coverage" ] ;
        ( fhir:profile [
    fhir:v "http://example.org/fhir/us/qicore/StructureDefinition/qicore-coverage"^^xsd:anyURI ;
    fhir:link <http://example.org/fhir/us/qicore/StructureDefinition/qicore-coverage>     ] ) ;
        ( fhir:codeFilter [
    fhir:path [ fhir:v "type" ] ;
    fhir:valueSet [
    fhir:v "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591"^^xsd:anyURI ;
    fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591>       ]     ] )
      ] ) . #