Quality Measure Implementation Guide (STU4)
4.0.0-ballot - ballot US

This page is part of the Quality Measure STU2 for FHIR R4 Implementation Guide (v4.0.0-ballot: STU 4 Ballot 1) based on FHIR R4. The current version which supercedes this version is 3.0.0. For a full list of available versions, see the Directory of published versions

: Example Computable Library - 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:Resource.id [ fhir:value "EXMComputableLibrary"]; # 
  fhir:Resource.meta [
     fhir:Meta.profile [
       fhir:value "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/computable-library-cqfm";
       fhir:index 0;
       fhir:link <http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/computable-library-cqfm>     ]
  ]; # 
  fhir:DomainResource.text [
     fhir:Narrative.status [ fhir:value "extensions" ];
     fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n    <table class=\"grid dict\">\n        \n        <tr>\n            <th scope=\"row\"><b>Id: </b></th>\n            <td style=\"padding-left: 4px;\">EXMComputableLibrary</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Url: </b></th>\n            <td style=\"padding-left: 4px;\"><a href=\"http://hl7.org/fhir/us/cqfmeasures/Library/EXMComputableLibrary\">http://hl7.org/fhir/us/cqfmeasures/Library/EXMComputableLibrary</a></td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Version: </b></th>\n            <td style=\"padding-left: 4px;\">2.0.0</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Identifier: </b></th>\n            <td style=\"padding-left: 4px;\">\n                \n                \n                <p style=\"margin-bottom: 5px;\">\n                    <b>value: </b> <span>EXMComputableLogic</span>\n                </p>\n                \n            </td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Name: </b></th>\n            <td style=\"padding-left: 4px;\">EXMComputableLibrary</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Title: </b></th>\n            <td style=\"padding-left: 4px;\">Example Computable Library</td>\n        </tr>\n        \n        \n        \n        <tr>\n            <th scope=\"row\"><b>Status: </b></th>\n            <td style=\"padding-left: 4px;\">active</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Experimental: </b></th>\n            <td style=\"padding-left: 4px;\">true</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Type: </b></th>\n            <td style=\"padding-left: 4px;\">\n                \n                    \n                        \n                        <p style=\"margin-bottom: 5px;\">\n                            <b>system: </b> <span><a href=\"http://terminology.hl7.org/CodeSystem/library-type\">http://terminology.hl7.org/CodeSystem/library-type</a></span>\n                        </p>\n                        \n                        \n                        <p style=\"margin-bottom: 5px;\">\n                            <b>code: </b> <span>logic-library</span>\n                        </p>\n                        \n                        \n                    \n                \n                \n            </td>\n        </tr>\n        \n        \n        \n        <tr>\n            <th scope=\"row\"><b>Date: </b></th>\n            <td style=\"padding-left: 4px;\">2019-09-03</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Publisher: </b></th>\n            <td style=\"padding-left: 4px;\">Clinical Quality Information WG</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Description: </b></th>\n            <td style=\"padding-left: 4px;\"><div><p>This library is used as an example in the FHIR Quality Measure Implementation Guide</p>\n</div></td>\n        </tr>\n        \n        \n        \n        \n        <tr>\n            <th scope=\"row\"><b>Use Context: </b></th>\n            <td style=\"padding-left: 4px;\">\n                <table class=\"grid-dict\">\n                    <tr><th><b>code</b></th><th><b>value</b></th><th><b>display</b></th></tr>\n                    \n                      <tr>\n                        <td>program</td>\n                        <td>eh-cah</td>\n                        <td>EH/CAH</td>\n                      </tr>\n                    \n                </table>\n            </td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Jurisdiction: </b></th>\n            <td style=\"padding-left: 4px;\">US</td>\n        </tr>\n        \n        \n        \n        \n        \n        <tr>\n            <th scope=\"row\"><b>Approval Date: </b></th>\n            <td style=\"padding-left: 4px;\">2019-08-03</td>\n        </tr>\n        \n        \n        <tr>\n            <th scope=\"row\"><b>Last Review Date: </b></th>\n            <td style=\"padding-left: 4px;\">2019-08-03</td>\n        </tr>\n        \n        \n        \n        <tr>\n          <th scope=\"row\"><b>Related Artifacts: </b></th>\n          <td style=\"padding-left: 4px;\">\n            \n            \n            \n            <p><b>Dependencies</b></p>\n            <ul>\n              \n                <li><a href=\"http://fhir.org/guides/common/Library/FHIR-ModelInfo|4.0.1\">http://fhir.org/guides/common/Library/FHIR-ModelInfo|4.0.1</a></li>\n              \n                <li><a href=\"http://fhir.org/guides/common/Library/FHIRHelpers|4.0.1\">http://fhir.org/guides/common/Library/FHIRHelpers|4.0.1</a></li>\n              \n                <li><a href=\"http://terminology.hl7.org/CodeSystem/diagnosis-role\">http://terminology.hl7.org/CodeSystem/diagnosis-role</a></li>\n              \n                <li><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></li>\n              \n                <li><a href=\"http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299\">http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299</a></li>\n              \n                <li><a href=\"http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126\">http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126</a></li>\n              \n                <li><a href=\"http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1\">http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1</a></li>\n              \n                <li><a href=\"http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836\">http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836</a></li>\n              \n                <li><a href=\"http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837\">http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837</a></li>\n              \n                <li><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></li>\n              \n            </ul>\n            \n            \n            \n            \n            \n          </td>\n        </tr>\n        \n        \n        <tr>\n          <th scope=\"row\"><b>Parameters: </b></th>\n          <td style=\"padding-left: 4px;\">\n            <table class=\"grid-dict\">\n              <tr><th><b>Name</b></th><th><b>Type</b></th><th><b>Min</b></th><th><b>Max</b></th><th><b>In/Out</b></th></tr>\n              \n                <tr><th>Measurement Period</th><th>Period</th><th>0</th><th>1</th><th>in</th></tr>\n              \n                <tr><th>Patient</th><th>Patient</th><th>0</th><th>1</th><th>out</th></tr>\n              \n                <tr><th>Inpatient Encounter</th><th>Encounter</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>Initial Population</th><th>Encounter</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>Measure Population</th><th>Encounter</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>Stratifier 1</th><th>Encounter</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>Stratifier 2</th><th>Encounter</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>Stratifier 3</th><th>Encounter</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>Stratifier 4</th><th>Encounter</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>SDE Ethnicity</th><th>Coding</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>SDE Payer</th><th>Resource</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>SDE Race</th><th>Coding</th><th>0</th><th>*</th><th>out</th></tr>\n              \n                <tr><th>SDE Sex</th><th>Coding</th><th>0</th><th>1</th><th>out</th></tr>\n              \n            </table>\n          </td>\n        </tr>\n        \n        \n        <tr>\n          <th scope=\"row\"><b>Data Requirements:</b></th>\n          <td style=\"padding-left: 4px;\">\n            <table class=\"grid-dict\">\n              <tr><th><b>Type</b></th><th><b>Profile</b></th><th><b>MS</b></th><th><b>Code Filter</b></th></tr>\n              \n                <tr>\n                  <th>Encounter</th>\n                  <th>http://hl7.org/fhir/StructureDefinition/Encounter</th>\n                  <th/>\n                  <th>\n                    \n                  </th>\n                </tr>\n              \n                <tr>\n                  <th>Encounter</th>\n                  <th>http://hl7.org/fhir/StructureDefinition/Encounter</th>\n                  <th/>\n                  <th>\n                    \n                      <b>code filter: </b>\n                      \n                      <br/>\n                      \n                      \n                      <span style=\"padding-left: 4px;\">\n                          <b>path: </b><span>type</span>\n                      </span>\n                      \n                      <br/>\n                      \n                      \n                      \n                      <span style=\"padding-left: 4px;\">\n                          <b>value set: </b><span>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292</span>\n                      </span>\n                      \n                      \n                    \n                  </th>\n                </tr>\n              \n                <tr>\n                  <th>Condition</th>\n                  <th>http://hl7.org/fhir/StructureDefinition/Condition</th>\n                  <th/>\n                  <th>\n                    \n                      <b>code filter: </b>\n                      \n                      <br/>\n                      \n                      \n                      <span style=\"padding-left: 4px;\">\n                          <b>path: </b><span>id</span>\n                      </span>\n                      \n                      \n                      \n                      \n                    \n                  </th>\n                </tr>\n              \n                <tr>\n                  <th>Coverage</th>\n                  <th>http://hl7.org/fhir/StructureDefinition/Coverage</th>\n                  <th/>\n                  <th>\n                    \n                      <b>code filter: </b>\n                      \n                      <br/>\n                      \n                      \n                      <span style=\"padding-left: 4px;\">\n                          <b>path: </b><span>type</span>\n                      </span>\n                      \n                      <br/>\n                      \n                      \n                      \n                      <span style=\"padding-left: 4px;\">\n                          <b>value set: </b><span>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591</span>\n                      </span>\n                      \n                      \n                    \n                  </th>\n                </tr>\n              \n            </table>\n          </td>\n        </tr>\n        \n        \n        \n        <tr>\n          <td colspan=\"2\">\n            <table>\n              <tr><th><a id=\"cql-content\"><b>Content: </b></a> text/cql</th></tr>\n              <tr><td><pre><code class=\"language-cql\">library EXMComputableLibrary version '2.0.0'\r\n\r\n/*\r\nThis example is purely for illustration purposes to show how all the elements of a\r\nFHIR-based quality measure are represented. It is intentionally simplified to show\r\nspecific aspects of a measure, and is not intended as an example of a clinically\r\nmeaningful measure.\r\n*/\r\n\r\n/*\r\nNOTE: This is the same library as EXMLogic, being used to illustrate the different flavors of profiles:\r\n* Computable: Focusing on computable/design-time aspects\r\n* Executable: Focusing on run-time aspects\r\n* Publishable: Focusing on knowledge management aspects\r\n*/\r\n\r\nusing FHIR version '4.0.1'\r\n\r\ninclude FHIRHelpers version '4.0.1' called FHIRHelpers\r\n\r\ncodesystem &amp;quot;Diagnosis Role&amp;quot;: 'http://terminology.hl7.org/CodeSystem/diagnosis-role'\r\n\r\nvalueset &amp;quot;Emergency Department Visit&amp;quot; : 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292'\r\nvalueset &amp;quot;Psychiatric/Mental Health Patient&amp;quot; : 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299'\r\nvalueset &amp;quot;Hospital Settings&amp;quot; : 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126'\r\n\r\nvalueset &amp;quot;ONC Administrative Sex&amp;quot;: 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1'\r\nvalueset &amp;quot;Race&amp;quot;: 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836'\r\nvalueset &amp;quot;Ethnicity&amp;quot;: 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837'\r\nvalueset &amp;quot;Payer&amp;quot;: 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591'\r\n\r\ncode &amp;quot;Billing&amp;quot;: 'billing' from &amp;quot;Diagnosis Role&amp;quot; display 'Billing'\r\n\r\nparameter &amp;quot;Measurement Period&amp;quot; Interval&amp;lt;DateTime&amp;gt;\r\n\r\ncontext Patient\r\n\r\ndefine &amp;quot;Initial Population&amp;quot; :\r\n  &amp;quot;Inpatient Encounter&amp;quot; Encounter\r\n\r\ndefine &amp;quot;Measure Population&amp;quot; :\r\n  &amp;quot;Initial Population&amp;quot;\r\n\r\ndefine function &amp;quot;Measure Observation&amp;quot; (Encounter &amp;quot;Encounter&amp;quot; ) :\r\n  duration in minutes of &amp;quot;Related ED Visit&amp;quot;(Encounter).period\r\n\r\ndefine &amp;quot;Stratifier 1&amp;quot; :\r\n  &amp;quot;Inpatient Encounter&amp;quot; Encounter\r\n    where not (PrincipalDiagnosis(Encounter).code in &amp;quot;Psychiatric/Mental Health Patient&amp;quot;)\r\n\r\ndefine &amp;quot;Stratifier 2&amp;quot; :\r\n  &amp;quot;Inpatient Encounter&amp;quot; Encounter\r\n    where PrincipalDiagnosis(Encounter).code in &amp;quot;Psychiatric/Mental Health Patient&amp;quot;\r\n\r\ndefine &amp;quot;Stratifier 3&amp;quot; :\r\n  &amp;quot;Inpatient Encounter&amp;quot; Encounter\r\n    where PrincipalDiagnosis(Encounter) is null\r\n\r\ndefine &amp;quot;Stratifier 4&amp;quot; :\r\n  &amp;quot;Inpatient Encounter&amp;quot; Encounter\r\n    where PrincipalDiagnosis(Encounter) is null\r\n\r\ndefine &amp;quot;Inpatient Encounter&amp;quot; :\r\n  [&amp;quot;Encounter&amp;quot;] Encounter\r\n    where LengthInDays(Encounter.period) &amp;lt;= 120\r\n      and Encounter.period ends during &amp;quot;Measurement Period&amp;quot;\r\n\r\ndefine function &amp;quot;PrincipalDiagnosis&amp;quot;(Encounter Encounter):\r\n	(singleton from (Encounter.diagnosis D where D.use ~ ToConcept(&amp;quot;Billing&amp;quot;) and D.rank.value = 1)) PD\r\n		return singleton from ([Condition: id in &amp;quot;GetId&amp;quot;(PD.condition.reference)])\r\n\r\ndefine function &amp;quot;LengthInDays&amp;quot;(Value Interval&amp;lt;DateTime&amp;gt;):\r\n	difference in days between start of Value and end of Value\r\n\r\ndefine function &amp;quot;GetId&amp;quot;(uri String):\r\n	Last(Split(uri, '/'))\r\n\r\n//Measure Observation\r\ndefine function &amp;quot;Related ED Visit&amp;quot; (Encounter &amp;quot;Encounter&amp;quot; ) :\r\n  Last([&amp;quot;Encounter&amp;quot; : &amp;quot;Emergency Department Visit&amp;quot;] ED\r\n    where ED.status = 'finished'\r\n      and ED.period ends 1 hour or less before start of Encounter.period\r\n    sort by start of period )\r\n\r\ndefine &amp;quot;SDE Ethnicity&amp;quot;:\r\n  (flatten (\r\n    Patient.extension Extension\r\n      where Extension.url = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity'\r\n        return Extension.extension\r\n  )) E\r\n    where E.url = 'ombCategory'\r\n      or E.url = 'detailed'\r\n    return E.value as Coding\r\n\r\ndefine &amp;quot;SDE Payer&amp;quot;:\r\n    [Coverage: type in &amp;quot;Payer&amp;quot;] Payer\r\n      return {\r\n        code: Payer.type,\r\n        period: Payer.period\r\n      }\r\n\r\ndefine &amp;quot;SDE Race&amp;quot;:\r\n  (flatten (\r\n    Patient.extension Extension\r\n      where Extension.url = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race'\r\n        return Extension.extension\r\n  )) E\r\n    where E.url = 'ombCategory'\r\n      or E.url = 'detailed'\r\n    return E.value as Coding\r\n\r\ndefine &amp;quot;SDE Sex&amp;quot;:\r\n  case\r\n    when Patient.gender = 'male' then Code { code: 'M', system: 'http://hl7.org/fhir/v3/AdministrativeGender', display: 'Male' }\r\n    when Patient.gender = 'female' then Code { code: 'F', system: 'http://hl7.org/fhir/v3/AdministrativeGender', display: 'Female' }\r\n    else null\r\n  end\r\n</code></pre></td></tr>\n            </table>\n          </td>\n        </tr>\n        \n        \n        \n    </table>\n</div>"
  ]; # 
  fhir:Library.url [ fhir:value "http://hl7.org/fhir/us/cqfmeasures/Library/EXMComputableLibrary"]; # 
  fhir:Library.identifier [
     fhir:index 0;
     fhir:Identifier.use [ fhir:value "official" ];
     fhir:Identifier.system [ fhir:value "http://example.org/fhir/cqi/ecqm/Library/Identifier" ];
     fhir:Identifier.value [ fhir:value "EXMComputableLogic" ]
  ]; # 
  fhir:Library.version [ fhir:value "2.0.0"]; # 
  fhir:Library.name [ fhir:value "EXMComputableLibrary"]; # 
  fhir:Library.title [ fhir:value "Example Computable Library"]; # 
  fhir:Library.status [ fhir:value "active"]; # 
  fhir:Library.experimental [ fhir:value "true"^^xsd:boolean]; # 
  fhir:Library.type [
     fhir:CodeableConcept.coding [
       fhir:index 0;
       fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/library-type" ];
       fhir:Coding.code [ fhir:value "logic-library" ]     ]
  ]; # 
  fhir:Library.date [ fhir:value "2019-09-03"^^xsd:date]; # 
  fhir:Library.publisher [ fhir:value "Clinical Quality Information WG"]; # 
  fhir:Library.contact [
     fhir:index 0;
     fhir:ContactDetail.telecom [
       fhir:index 0;
       fhir:ContactPoint.system [ fhir:value "url" ];
       fhir:ContactPoint.value [ fhir:value "http://www.hl7.org/Special/committees/cqi" ]     ]
  ]; # 
  fhir:Library.description [ fhir:value "This library is used as an example in the FHIR Quality Measure Implementation Guide"]; # 
  fhir:Library.useContext [
     fhir:index 0;
     fhir:UsageContext.code [
       fhir:Coding.system [ fhir:value "http://terminology.hl7.org/CodeSystem/usage-context-type" ];
       fhir:Coding.code [ fhir:value "program" ]     ];
     fhir:UsageContext.valueCodeableConcept [
       fhir:CodeableConcept.coding [
         fhir:index 0;
         fhir:Coding.system [ fhir:value "http://hl7.org/fhir/us/cqfmeasures/CodeSystem/quality-programs" ];
         fhir:Coding.code [ fhir:value "eh-cah" ];
         fhir:Coding.display [ fhir:value "EH/CAH" ]       ]     ]
  ]; # 
  fhir:Library.jurisdiction [
     fhir:index 0;
     fhir:CodeableConcept.coding [
       fhir:index 0;
       fhir:Coding.system [ fhir:value "urn:iso:std:iso:3166" ];
       fhir:Coding.code [ fhir:value "US" ]     ]
  ]; # 
  fhir:Library.approvalDate [ fhir:value "2019-08-03"^^xsd:date]; # 
  fhir:Library.lastReviewDate [ fhir:value "2019-08-03"^^xsd:date]; # 
  fhir:Library.relatedArtifact [
     fhir:index 0;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://fhir.org/guides/common/Library/FHIR-ModelInfo|4.0.1";
       fhir:link <http://fhir.org/guides/common/Library/FHIR-ModelInfo|4.0.1>     ]
  ], [
     fhir:index 1;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://fhir.org/guides/common/Library/FHIRHelpers|4.0.1";
       fhir:link <http://fhir.org/guides/common/Library/FHIRHelpers|4.0.1>     ]
  ], [
     fhir:index 2;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://terminology.hl7.org/CodeSystem/diagnosis-role";
       fhir:link <http://terminology.hl7.org/CodeSystem/diagnosis-role>     ]
  ], [
     fhir:index 3;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292";
       fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292>     ]
  ], [
     fhir:index 4;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299";
       fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.299>     ]
  ], [
     fhir:index 5;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126";
       fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.126>     ]
  ], [
     fhir:index 6;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1";
       fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1>     ]
  ], [
     fhir:index 7;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836";
       fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.836>     ]
  ], [
     fhir:index 8;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837";
       fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.837>     ]
  ], [
     fhir:index 9;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.resource [
       fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591";
       fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591>     ]
  ]; # 
  fhir:Library.parameter [
     fhir:index 0;
     fhir:ParameterDefinition.name [ fhir:value "Measurement Period" ];
     fhir:ParameterDefinition.use [ fhir:value "in" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "Period" ]
  ], [
     fhir:index 1;
     fhir:ParameterDefinition.name [ fhir:value "Patient" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "Patient" ]
  ], [
     fhir:index 2;
     fhir:ParameterDefinition.name [ fhir:value "Inpatient Encounter" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Encounter" ]
  ], [
     fhir:index 3;
     fhir:ParameterDefinition.name [ fhir:value "Initial Population" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Encounter" ]
  ], [
     fhir:index 4;
     fhir:ParameterDefinition.name [ fhir:value "Measure Population" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Encounter" ]
  ], [
     fhir:index 5;
     fhir:ParameterDefinition.name [ fhir:value "Stratifier 1" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Encounter" ]
  ], [
     fhir:index 6;
     fhir:ParameterDefinition.name [ fhir:value "Stratifier 2" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Encounter" ]
  ], [
     fhir:index 7;
     fhir:ParameterDefinition.name [ fhir:value "Stratifier 3" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Encounter" ]
  ], [
     fhir:index 8;
     fhir:ParameterDefinition.name [ fhir:value "Stratifier 4" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Encounter" ]
  ], [
     fhir:index 9;
     fhir:ParameterDefinition.name [ fhir:value "SDE Ethnicity" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Coding" ]
  ], [
     fhir:index 10;
     fhir:ParameterDefinition.name [ fhir:value "SDE Payer" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Resource" ]
  ], [
     fhir:index 11;
     fhir:ParameterDefinition.name [ fhir:value "SDE Race" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "Coding" ]
  ], [
     fhir:index 12;
     fhir:ParameterDefinition.name [ fhir:value "SDE Sex" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0"^^xsd:integer ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "Coding" ]
  ]; # 
  fhir:Library.dataRequirement [
     fhir:index 0;
     fhir:DataRequirement.type [ fhir:value "Encounter" ];
     fhir:DataRequirement.profile [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Encounter";
       fhir:index 0;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Encounter>     ]
  ], [
     fhir:index 1;
     fhir:DataRequirement.type [ fhir:value "Encounter" ];
     fhir:DataRequirement.profile [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Encounter";
       fhir:index 0;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Encounter>     ];
     fhir:DataRequirement.codeFilter [
       fhir:index 0;
       fhir:DataRequirement.codeFilter.path [ fhir:value "type" ];
       fhir:DataRequirement.codeFilter.valueSet [
         fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292";
         fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292>       ]     ]
  ], [
     fhir:index 2;
     fhir:DataRequirement.type [ fhir:value "Condition" ];
     fhir:DataRequirement.profile [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Condition";
       fhir:index 0;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Condition>     ];
     fhir:DataRequirement.codeFilter [
       fhir:index 0;
       fhir:DataRequirement.codeFilter.path [ fhir:value "id" ]     ]
  ], [
     fhir:index 3;
     fhir:DataRequirement.type [ fhir:value "Coverage" ];
     fhir:DataRequirement.profile [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Coverage";
       fhir:index 0;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Coverage>     ];
     fhir:DataRequirement.codeFilter [
       fhir:index 0;
       fhir:DataRequirement.codeFilter.path [ fhir:value "type" ];
       fhir:DataRequirement.codeFilter.valueSet [
         fhir:value "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591";
         fhir:link <http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591>       ]     ]
  ]; # 
  fhir:Library.content [
     fhir:index 0;
     fhir:Attachment.contentType [ fhir:value "text/cql" ];
     fhir:Attachment.language [ fhir:value "AllLanguages" ];
     fhir:Attachment.data [ fhir:value "bGlicmFyeSBFWE1Db21wdXRhYmxlTGlicmFyeSB2ZXJzaW9uICcyLjAuMCcNCg0KLyoNClRoaXMgZXhhbXBsZSBpcyBwdXJlbHkgZm9yIGlsbHVzdHJhdGlvbiBwdXJwb3NlcyB0byBzaG93IGhvdyBhbGwgdGhlIGVsZW1lbnRzIG9mIGENCkZISVItYmFzZWQgcXVhbGl0eSBtZWFzdXJlIGFyZSByZXByZXNlbnRlZC4gSXQgaXMgaW50ZW50aW9uYWxseSBzaW1wbGlmaWVkIHRvIHNob3cNCnNwZWNpZmljIGFzcGVjdHMgb2YgYSBtZWFzdXJlLCBhbmQgaXMgbm90IGludGVuZGVkIGFzIGFuIGV4YW1wbGUgb2YgYSBjbGluaWNhbGx5DQptZWFuaW5nZnVsIG1lYXN1cmUuDQoqLw0KDQovKg0KTk9URTogVGhpcyBpcyB0aGUgc2FtZSBsaWJyYXJ5IGFzIEVYTUxvZ2ljLCBiZWluZyB1c2VkIHRvIGlsbHVzdHJhdGUgdGhlIGRpZmZlcmVudCBmbGF2b3JzIG9mIHByb2ZpbGVzOg0KKiBDb21wdXRhYmxlOiBGb2N1c2luZyBvbiBjb21wdXRhYmxlL2Rlc2lnbi10aW1lIGFzcGVjdHMNCiogRXhlY3V0YWJsZTogRm9jdXNpbmcgb24gcnVuLXRpbWUgYXNwZWN0cw0KKiBQdWJsaXNoYWJsZTogRm9jdXNpbmcgb24ga25vd2xlZGdlIG1hbmFnZW1lbnQgYXNwZWN0cw0KKi8NCg0KdXNpbmcgRkhJUiB2ZXJzaW9uICc0Lj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HVyZURlZmluaXRpb24vdXMtY29yZS1yYWNlJw0KICAgICAgICByZXR1cm4gRXh0ZW5zaW9uLmV4dGVuc2lvbg0KICApKSBFDQogICAgd2hlcmUgRS51cmwgPSAnb21iQ2F0ZWdvcnknDQogICAgICBvciBFLnVybCA9ICdkZXRhaWxlZCcNCiAgICByZXR1cm4gRS52YWx1ZSBhcyBDb2RpbmcNCg0KZGVmaW5lICJTREUgU2V4IjoNCiAgY2FzZQ0KICAgIHdoZW4gUGF0aWVudC5nZW5kZXIgPSAnbWFsZScgdGhlbiBDb2RlIHsgY29kZTogJ00nLCBzeXN0ZW06ICdodHRwOi8vaGw3Lm9yZy9maGlyL3YzL0FkbWluaXN0cmF0aXZlR2VuZGVyJywgZGlzcGxheTogJ01hbGUnIH0NCiAgICB3aGVuIFBhdGllbnQuZ2VuZGVyID0gJ2ZlbWFsZScgdGhlbiBDb2RlIHsgY29kZTogJ0YnLCBzeXN0ZW06ICdodHRwOi8vaGw3Lm9yZy9maGlyL3YzL0FkbWluaXN0cmF0aXZlR2VuZGVyJywgZGlzcGxheTogJ0ZlbWFsZScgfQ0KICAgIGVsc2UgbnVsbA0KICBlbmQNCg=="^^xsd:base64Binary ]
  ]. # 

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

 a owl:Ontology;
  owl:imports fhir:fhir.ttl.