@prefix fhir: <http://hl7.org/fhir/> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

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

[] a fhir:Library;
  fhir:Resource.id [ fhir:value "OpioidCDSREC06"], [ fhir:value "options"];
  fhir:DomainResource.extension [
     fhir:index 0;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/StructureDefinition/cqf-cqlOptions" ];
     fhir:Extension.value [
       fhir:Reference.reference [ fhir:value "#options" ]
     ]
  ], [
     fhir:index 1;
     fhir:Extension.url [ fhir:value "http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-softwaresystem" ];
     fhir:Extension.value [
       fhir:Reference.reference [ fhir:value "Device/cqf-tooling" ]
     ]
  ];
  fhir:Library.url [ fhir:value "http://fhir.org/guides/cdc/opioid-cds/Library/OpioidCDSREC06"];
  fhir:Library.version [ fhir:value "2022.1.0"];
  fhir:Library.name [ fhir:value "OpioidCDSREC06"];
  fhir:Library.title [ fhir:value "Library - Recommendation #6 - Prescribe Lowest Effective Dose and Duration"];
  fhir:Library.status [ fhir:value "active"];
  fhir:Library.experimental [ fhir:value "true"];
  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 "2025-12-31T04:14:52+00:00"];
  fhir:Library.publisher [ fhir:value "Centers for Disease Control and Prevention (CDC)"];
  fhir:Library.contact [
     fhir:index 0;
     fhir:ContactDetail.telecom [
       fhir:index 0;
       fhir:ContactPoint.system [ fhir:value "url" ];
       fhir:ContactPoint.value [ fhir:value "https://www.cdc.gov" ]
     ]
  ];
  fhir:Library.jurisdiction [
     fhir:index 0;
     fhir:CodeableConcept.coding [ fhir:index 0 ]
  ];
  fhir:Library.relatedArtifact [
     fhir:index 0;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.display [ fhir:value "FHIR model information" ];
     fhir:RelatedArtifact.resource [ fhir:value "http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1" ]
  ], [
     fhir:index 1;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.display [ fhir:value "Library FHIRHelpers" ];
     fhir:RelatedArtifact.resource [ fhir:value "http://fhir.org/guides/cdc/opioid-cds/Library/FHIRHelpers|4.0.1" ]
  ], [
     fhir:index 2;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.display [ fhir:value "Library Common" ];
     fhir:RelatedArtifact.resource [ fhir:value "http://fhir.org/guides/cdc/opioid-cds/Library/OpioidCDSCommon|2022.1.0" ]
  ], [
     fhir:index 3;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.display [ fhir:value "Library Config" ];
     fhir:RelatedArtifact.resource [ fhir:value "http://fhir.org/guides/cdc/opioid-cds/Library/OpioidCDSCommonConfig|2022.1.0" ]
  ], [
     fhir:index 4;
     fhir:RelatedArtifact.type [ fhir:value "depends-on" ];
     fhir:RelatedArtifact.display [ fhir:value "Library Routines" ];
     fhir:RelatedArtifact.resource [ fhir:value "http://fhir.org/guides/cdc/opioid-cds/Library/OpioidCDSRoutines|2022.1.0" ]
  ];
  fhir:Library.parameter [
     fhir:index 0;
     fhir:ParameterDefinition.name [ fhir:value "ContextPrescriptions" ];
     fhir:ParameterDefinition.use [ fhir:value "in" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "MedicationRequest" ]
  ], [
     fhir:index 1;
     fhir:ParameterDefinition.name [ fhir:value "Patient" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "Patient" ]
  ], [
     fhir:index 2;
     fhir:ParameterDefinition.name [ fhir:value "Acute Pain Opioid Analgesic with Ambulatory Misuse Potential Prescriptions" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "*" ];
     fhir:ParameterDefinition.type [ fhir:value "MedicationRequest" ]
  ], [
     fhir:index 3;
     fhir:ParameterDefinition.name [ fhir:value "Patient Is Being Prescribed Opioid Analgesic with Ambulatory Misuse Potential for Acute Pain" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "boolean" ]
  ], [
     fhir:index 4;
     fhir:ParameterDefinition.name [ fhir:value "Order is for Long-Acting Opioid" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "boolean" ]
  ], [
     fhir:index 5;
     fhir:ParameterDefinition.name [ fhir:value "Inclusion Criteria" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "boolean" ]
  ], [
     fhir:index 6;
     fhir:ParameterDefinition.name [ fhir:value "Exclusion Criteria" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "boolean" ]
  ], [
     fhir:index 7;
     fhir:ParameterDefinition.name [ fhir:value "Is Recommendation Applicable?" ];
     fhir:ParameterDefinition.use [ fhir:value "out" ];
     fhir:ParameterDefinition.min [ fhir:value "0" ];
     fhir:ParameterDefinition.max [ fhir:value "1" ];
     fhir:ParameterDefinition.type [ fhir:value "boolean" ]
  ];
  fhir:Library.dataRequirement [
     fhir:index 0;
     fhir:DataRequirement.type [ fhir:value "Patient" ];
     fhir:DataRequirement.profile [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Patient";
       fhir:index 0
     ]
  ];
  fhir:Library.content [
     fhir:index 0;
     fhir:Attachment.contentType [ fhir:value "text/cql" ];
     fhir:Attachment.data [ fhir:value "[encoded data, 4376 characters]" ]
  ], [
     fhir:index 1;
     fhir:Attachment.contentType [ fhir:value "application/elm+xml" ];
     fhir:Attachment.data [ fhir:value "[encoded data, 28264 characters]" ]
  ], [
     fhir:index 2;
     fhir:Attachment.contentType [ fhir:value "application/elm+json" ];
     fhir:Attachment.data [ fhir:value "[encoded data, 47256 characters]" ]
  ] .

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

