CMS FHIR Quality Measure Development IG
0.8.0-cibuild - CI Build
CMS FHIR Quality Measure Development IG, published by Centers for Medicare & Medicaid Services (CMS). This guide is not an authorized publication; it is the continuous build for version 0.8.0-cibuild built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/cqframework/cms-qmd/ and changes regularly. See the Directory of published versions
This topic provides an index of the shared libraries used in QICore and USQualityCore, and where refactored content from those shared libraries can be found in the refactored versions.
This index lists all the shared libraries used by measures. Note that for QICore measures, all shared libraries were developed and published in MADiE, whereas for US Quality Core measures, a core set of shared libraries are published as part of HL7 or ONC implementation guides and made available through the NPM packages for those implementation guides. Libraries available in published implementation guides are listed in the table below with the namespace and name of the library, and linked to the published content for that library.
The remaining libraries are expected to still be developed in MADiE, but are included in the proposed set of refactored measures for reference, testing, and to support the development of this guidance. A third group — ClaimCommon, ClaimElements, and MedicationCommon — is drafted in this guide itself, supplying functions that no published library provides yet; the status, use, and type functions in ClaimCommon and all of MedicationCommon are intended for proposal to FHIRCommon. The version numbers of those libraries are suggested based on both a Major and Minor version increment for each library (for example, AdultOutpatientEncounters in QICore is version 4.19.000, whereas the suggested refactoring is 5.1.000). The content for these libraries is suggested, and it is expected that these libraries will be developed in MADiE once full US Quality Core support is available. Measure developers can use the content as a starting point for that development if desired.
Note also that the dqm-content-cms-2026 repository has minor increments for each of these libraries as well with the full update to the 0.5.0 published release. Those increments will be pulled into the cms-2025 repository once discrepancy testing has completed.
| Library | QI Core version | US Quality Core version |
|---|---|---|
| AdultOutpatientEncounters | 4.19.000 | 5.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| AdvancedIllnessandFrailty | 1.27.000 | 2.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| AHAOverall | 4.1.000 | 5.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| AlaraCommonFunctions | 1.10.000 | 2.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| Antibiotic | 1.11.000 | 2.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| ClaimCommon | - | 0.3.000 0.3.000 currently published in MADiE |
| ClaimElements | - | 0.3.000 0.3.000 currently published in MADiE |
| CQMCommon | 4.1.000 | 5.2.000 5.2.000 currently published in MADiE |
| CQMConcepts | - | 0.2.000 0.2.000 currently published in MADiE; part of the layer-based replacement for CQMCommon — measure developers should consider whether to adopt these libraries or keep the CQMCommon shared library |
| CQMElements | - | 0.2.000 0.2.000 currently published in MADiE; part of the layer-based replacement for CQMCommon — measure developers should consider whether to adopt these libraries or keep the CQMCommon shared library |
| CQMInferences | - | 0.2.000 0.2.000 currently published in MADiE; part of the layer-based replacement for CQMCommon — measure developers should consider whether to adopt these libraries or keep the CQMCommon shared library |
| CumulativeMedicationDuration | 6.0.000 | hl7.fhir.us.cql.CumulativeMedicationDuration version ‘2.0.0’ |
| FHIRHelpers | 4.4.000 | hl7.fhir.uv.cql.FHIRHelpers version ‘4.0.1’ |
| FHIRCommon | - | hl7.fhir.uv.cql.FHIRCommon version ‘2.0.0’ |
| Hospice | 6.18.000 | 7.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| MedicationCommon | - | 0.1.0 draft content in this guide; needs review and authoring in MADiE |
| NHSNHelpers | 0.1.000 | 1.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| PalliativeCare | 1.18.000 | 2.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| PCMaternal | 5.25.000 | 6.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| QICoreCommon | 4.0.000 | refactored into FHIRCommon, USCoreCommon, and USQualityCoreCommon |
| Status | 1.15.000 | 2.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| SupplementalDataElements | 5.1.000 | 6.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| TJCOverall | 8.25.000 | 9.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| VTE | 8.18.000 | 9.1.000 proposed draft content in Github; needs review and authoring in MADiE |
| USCoreCommon | - | hl7.fhir.us.cql.USCoreCommon version ‘2.0.0’ |
| USCoreElements | - | hl7.fhir.us.cql.USCoreElements version ‘2.0.0’ |
| USQualityCoreCommon | - | fhir.onc.”us-quality-core”.USQualityCoreCommon version ‘0.5.0’ |
This index lists functions from the QICore-based library versions and where they are now following the refactor.
| Library | Prior version or name | New version or location |
|---|---|---|
| CQMCommon | 4.1.000 | 5.1.000 |
| QICoreCommon | deprecated | FHIRCommon, USCoreCommon, or USQualityCoreCommon |
| CumulativeMedicationDuration | 6.0.000 | hl7.fhir.us.cql.CumulativeMedicationDuration 2.0.0 |
| Status | 1.15.000 | 2.1.000 |
Notes on the libraries above:
edVisit() and hospitalization() fluent functions instead. The claim navigation functions have moved to ClaimCommon and ClaimElements.QICoreCommon is deprecated. Its functions are now distributed across three libraries:
| QICoreCommon function | New location |
|---|---|
| isActive() | FHIRCommon |
| hasCategory(Condition, Code) | FHIRCommon |
| isProblemListItem() | FHIRCommon |
| isEncounterDiagnosis() | FHIRCommon |
| hasCategory(Observation, Code) | FHIRCommon |
| isSocialHistory() | FHIRCommon |
| isVitalSign() | FHIRCommon |
| isImaging() | FHIRCommon |
| isLaboratory() | FHIRCommon |
| isProcedure() | FHIRCommon |
| isSurvey() | FHIRCommon |
| isExam() | FHIRCommon |
| isTherapy() | FHIRCommon |
| isActivity() | FHIRCommon |
| isCommunity() | FHIRCommon |
| isDischarge() | FHIRCommon |
| references() | FHIRCommon |
| toInterval() | FHIRCommon |
| abatementInterval() | FHIRCommon |
| prevalenceInterval() | FHIRCommon |
| includesCode() | FHIRCommon |
| HasStart() / hasStart() | FHIRCommon |
| HasEnd() / hasEnd() | FHIRCommon |
| Latest() / latest() | FHIRCommon |
| Earliest() / earliest() | FHIRCommon |
| getId() | USQualityCoreCommon |
| “Interval To Day Numbers” / toDayNumbers() | USQualityCoreCommon |
| “Days In Period” / daysInPeriod() | USQualityCoreCommon |
| doNotPerform(DeviceNotRequested) | USQualityCoreCommon |
| DeviceNotRequested.doNotPerformReason() | USQualityCoreCommon |
| DeviceNotRequested.doNotPerform() | USQualityCoreCommon |
| DeviceNotRequested.code() | USQualityCoreCommon |
| CommunicationNotDone.recorded() | USQualityCoreCommon |
| CommunicationNotDone.topic() | USQualityCoreCommon |
| ImmunizationNotDone.vaccineCode() | USQualityCoreCommon |
| MedicationAdministrationNotDone.recorded() | USQualityCoreCommon |
| MedicationAdministrationNotDone.medication() | USQualityCoreCommon |
| MedicationDispenseDeclined.recorded() | USQualityCoreCommon |
| MedicationDispenseDeclined.medication() | USQualityCoreCommon |
| MedicationNotRequested.medication() | USQualityCoreCommon |
| ObservationCancelled.notDoneReason() | USQualityCoreCommon |
| ObservationCancelled.code() | USQualityCoreCommon |
| ProcedureNotDone.recorded() | USQualityCoreCommon |
| ProcedureNotDone.code() | USQualityCoreCommon |
| ServiceNotRequested.reasonRefused() | USQualityCoreCommon |
| ServiceNotRequested.code() | USQualityCoreCommon |
| TaskRejected.code() | USQualityCoreCommon |
| isHealthConcern() | USCoreCommon |
This index lists every element that QI Core STU6 and US Quality Core 0.5.0 represent as an extension rather than as a core FHIR element, and shows where each one landed in the refactor. Extensions reach these profiles from three places: inherited from US Core 6.1.0, defined by the IG itself, or borrowed from base FHIR and SDC. Each is covered below. For the remaining slices — those discriminated by value or pattern rather than by extension URL — see the Slice Index.
Profile names map one-to-one between the two IGs: QICore<Name> in QI Core STU6 becomes USQualityCore<Name> in US Quality Core 0.5.0. Both IGs publish 57 profiles and 8 extension definitions, and every extension slice is at the same element path with the same slice name in both. The profile column below gives the US Quality Core name; prefix it with QICore instead of USQualityCore for the QI Core STU6 equivalent.
Extensions inherited from US Core 6.1.0
QI Core STU6 and US Quality Core 0.5.0 both depend on US Core 6.1.0, so this layer is identical in both IGs and was not touched by the refactor. US Core 6.1.0 publishes 49 profiles and 10 extension definitions.
Only four US Core profiles slice extensions into their content, 16 slices in total. Every one of them is inherited unchanged (i.e. Preserved) by the corresponding US Quality Core profile, and each appears in the by-profile table further below.
| US Core 6.1.0 profile | Extension slices | Inherited by | Preserved |
|---|---|---|---|
| USCoreConditionEncounterDiagnosis | 1 | USQualityCoreConditionEncounterDiagnosis | 1 of 1 |
| USCoreConditionProblemsHealthConcerns | 1 | USQualityCoreConditionProblemsHealthConcerns | 1 of 1 |
| USCorePatient | 6 | USQualityCorePatient | 6 of 6 |
| USCoreQuestionnaireResponse | 8 | USQualityCoreQuestionnaireResponse | 8 of 8 |
The 10 extension definitions US Core 6.1.0 publishes, and where each one is used:
| US Core 6.1.0 extension | Allowed context | Sliced into | CQL accessor |
|---|---|---|---|
| us-core-birthsex | Patient |
us-core-patient → Patient.extension:birthsex |
birthSex() |
| us-core-direct | ContactPoint |
not sliced into any profile | none |
| us-core-ethnicity | Patient, RelatedPerson, Person, Practitioner, FamilyMemberHistory |
us-core-patient → Patient.extension:ethnicity |
ethnicity() |
| us-core-extension-questionnaire-uri | QuestionnaireResponse.questionnaire |
us-core-questionnaireresponse → QuestionnaireResponse.questionnaire.extension:url |
none |
| us-core-genderIdentity | Patient, RelatedPerson, Person, Practitioner |
us-core-patient → Patient.extension:genderIdentity |
none |
| us-core-jurisdiction | Element |
not sliced into any profile | none |
| us-core-race | Patient, RelatedPerson, Person, Practitioner, FamilyMemberHistory |
us-core-patient → Patient.extension:race |
race() |
| us-core-sex | Patient |
us-core-patient → Patient.extension:sex |
sex() (deprecated) use individualSex() |
| us-core-tribal-affiliation | Patient, RelatedPerson, Person, Practitioner, FamilyMemberHistory |
us-core-patient → Patient.extension:tribalAffiliation |
tribalAffiliation() |
| uscdi-requirement | ElementDefinition |
tooling only — applied to ElementDefinition in 48 US Core StructureDefinitions |
— |
us-core-direct and us-core-jurisdiction are published but not sliced into any US Core profile, so they never reach QI Core or US Quality Core by inheritance; they remain available for direct use. uscdi-requirement is the US Core counterpart of qicore-keyelement/uscdiplusquality — it annotates ElementDefinition, not patient data.
Note the allowed contexts: race, ethnicity, and tribalAffiliation are also legal on RelatedPerson, Person, Practitioner, and FamilyMemberHistory, but US Core slices them only into us-core-patient. USQualityCoreRelatedPerson and USQualityCorePractitioner therefore do not declare them, and the USCoreCommon accessors are all typed to FHIR.Patient.
Extension definitions published by the IG
The extensions QI Core defined itself were renamed from qicore-* to us-quality-core-* and moved to the http://fhir.org/guides/onc/us-quality-core/StructureDefinition/ canonical base. Nothing was dropped and nothing was added.
| QI Core STU6 | US Quality Core 0.5.0 | Context |
|---|---|---|
| qicore-doNotPerformReason | us-quality-core-doNotPerformReason | Resource |
| qicore-encounter-diagnosisPresentOnAdmission | us-quality-core-encounter-diagnosisPresentOnAdmission | Encounter.diagnosis |
| qicore-isElective | us-quality-core-isElective | ServiceRequest |
| qicore-notDoneReason | us-quality-core-notDoneReason | Resource |
| qicore-notDoneValueSet | us-quality-core-notDoneValueSet | CodeableConcept |
| qicore-recorded | us-quality-core-recorded | Resource |
| qicore-servicerequest-appropriatenessScore | us-quality-core-servicerequest-appropriatenessScore | ServiceRequest |
| qicore-keyelement | uscdiplusquality | ElementDefinition, ElementDefinition.type.targetProfile, ElementDefinition.type |
isElective and servicerequest-appropriatenessScore are defined but not used by any profile in either IG. qicore-keyelement/uscdiplusquality is a tooling extension applied to ElementDefinition inside every profile to flag key elements; it is not a data element and does not appear in the table below.
Extension-backed elements, by profile
19 of the 57 US Quality Core profiles carry extension-backed elements (18 of the 57 in QI Core STU6). The remaining 38 profiles have none.
Extensions borrowed from base FHIR, US Core, and SDC are marked unchanged — the same canonical URL is used in both IGs.
| Profile | Element | Card. | Extension | CQL accessor in US Quality Core |
|---|---|---|---|---|
| AllergyIntolerance | AllergyIntolerance.extension:resolutionAge |
0..1 | allergyintolerance-resolutionAge (unchanged) | resolutionAge() |
| CommunicationNotDone | Communication.extension:recorded |
1..1 | qicore-recorded → us-quality-core-recorded | recorded() |
Communication.topic.extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | topic() | |
| ConditionEncounterDiagnosis | Condition.extension:assertedDate |
0..1 | condition-assertedDate (unchanged) | assertedDate() |
| ConditionProblemsHealthConcerns | Condition.extension:assertedDate |
0..1 | condition-assertedDate (unchanged) | assertedDate() |
| DeviceNotRequested | DeviceRequest.extension:doNotPerformReason |
1..1 | qicore-doNotPerformReason → us-quality-core-doNotPerformReason | doNotPerformReason() |
DeviceRequest.modifierExtension:doNotPerform |
1..1 | extension-DeviceRequest.doNotPerform (R5 cross-version, unchanged) |
doNotPerform() | |
DeviceRequest.code[x].extension:doNotPerformValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | code() | |
| DeviceRequest | DeviceRequest.modifierExtension:doNotPerform |
0..1 | extension-DeviceRequest.doNotPerform (R5 cross-version, unchanged) |
doNotPerform() ⚠ |
| Encounter | Encounter.diagnosis.extension:diagnosisPresentOnAdmission new in 0.5.0 |
0..1 | qicore-encounter-diagnosisPresentOnAdmission → us-quality-core-encounter-diagnosisPresentOnAdmission | presentOnAdmission() |
| FamilyMemberHistory | FamilyMemberHistory.condition.extension:condition-abatement |
0..1 | familymemberhistory-abatement (unchanged) | abatement() ⚠ |
FamilyMemberHistory.condition.extension:condition-severity |
0..1 | familymemberhistory-severity (unchanged) | severity() ⚠ | |
| ImmunizationNotDone | Immunization.vaccineCode.extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | vaccineCode() |
| MedicationAdministrationNotDone | MedicationAdministration.extension:recorded |
1..1 | qicore-recorded → us-quality-core-recorded | recorded() |
MedicationAdministration.medication[x].extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | medication() | |
| MedicationDispenseDeclined | MedicationDispense.extension:recorded |
1..1 | qicore-recorded → us-quality-core-recorded | recorded() |
MedicationDispense.medication[x].extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | medication() | |
| MedicationNotRequested | MedicationRequest.medication[x].extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | medication() |
| ObservationCancelled | Observation.extension:notDoneReason |
1..1 | qicore-notDoneReason → us-quality-core-notDoneReason | notDoneReason() |
Observation.code.extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | code() | |
| Patient | Patient.extension:race |
0..1 | us-core-race (unchanged) | race() |
Patient.extension:ethnicity |
0..1 | us-core-ethnicity (unchanged) | ethnicity() | |
Patient.extension:tribalAffiliation |
0..* | us-core-tribal-affiliation (unchanged) | tribalAffiliation() | |
Patient.extension:birthsex |
0..1 | us-core-birthsex (unchanged) | birthSex() | |
Patient.extension:sex |
0..1 | us-core-sex (unchanged) | sex() | |
Patient.extension:genderIdentity |
0..* | us-core-genderIdentity (unchanged) | none | |
Patient.telecom.extension:telecom-preferred |
0..1 | iso21090-preferred (unchanged) | none | |
Patient.address.extension:address-preferred |
0..1 | iso21090-preferred (unchanged) | none | |
| Procedure | Procedure.extension:recorded |
0..1 | qicore-recorded → us-quality-core-recorded | recorded() |
| ProcedureNotDone | Procedure.extension:recorded |
1..1 | qicore-recorded → us-quality-core-recorded | recorded() |
Procedure.code.extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | code() | |
| QuestionnaireResponse | QuestionnaireResponse.extension:signature |
0..* | questionnaireresponse-signature (unchanged) | none |
QuestionnaireResponse.extension:completionMode |
0..1 | questionnaireresponse-completionMode (unchanged) | none | |
QuestionnaireResponse.questionnaire.extension:questionnaireDisplay |
0..1 | display (unchanged) | none | |
QuestionnaireResponse.questionnaire.extension:url |
0..1 | us-core-extension-questionnaire-uri (unchanged) | none | |
QuestionnaireResponse.item.extension:itemMedia |
0..1 | sdc-questionnaire-itemMedia (unchanged) | none | |
QuestionnaireResponse.item.extension:ItemSignature |
0..* | questionnaireresponse-signature (unchanged) | none | |
QuestionnaireResponse.item.answer.extension:itemAnswerMedia |
0..1 | sdc-questionnaire-itemAnswerMedia (unchanged) | none | |
QuestionnaireResponse.item.answer.extension:ordinalValue |
0..1 | ordinalValue (unchanged) | none | |
| ServiceNotRequested | ServiceRequest.extension:reasonRefused |
1..1 | qicore-doNotPerformReason → us-quality-core-doNotPerformReason | reasonRefused() |
ServiceRequest.code.extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | code() | |
| TaskRejected | Task.code.extension:notDoneValueSet |
0..1 | qicore-notDoneValueSet → us-quality-core-notDoneValueSet | code() |
Notes on accessing extensions from CQL
The QICore 6.0.0 model info surfaced extensions as named model elements, so CQL could write Patient.race or ProcedureNotDone.recorded directly — 25 classes carried such elements. The USQualityCore 0.5.0 model info does not: no element in it declares an extension target, and neither does the USCore 6.1.0-derived model info it builds on. All extension access is now through fluent functions, so the same expressions become Patient.race() and ProcedureNotDone.recorded(). The last column above names the function and the library that defines it.
Extensions with no accessor in either common library must be read with the generic ext() function from FHIRCommon, for example:
define fluent function preferred(element FHIR.Element):
element.ext('http://hl7.org/fhir/StructureDefinition/iso21090-preferred').value as FHIR.boolean
The three complex US Core extensions do not return a simple value. race(), ethnicity(), and tribalAffiliation() each return a tuple assembled from the extension’s sub-extensions:
Patient.race() // { ombCategory: List<Coding>, detailed: List<Coding>, text: String }
Patient.ethnicity() // { ombCategory: Coding, detailed: List<Coding>, text: String }
Patient.tribalAffiliation() // { tribalAffiliation: CodeableConcept, isEnrolled: Boolean }
Notes on the above content:
diagnosisPresentOnAdmission is now accessible. QI Core STU6 defined qicore-encounter-diagnosisPresentOnAdmission but had removed it from QICoreEncounter in favor of accessing present on admission in the QICoreClaim profile (see the Present On Admission authoring pattern). US Quality Core 0.5.0 slices it into USQualityCoreEncounter.diagnosis and provides presentOnAdmission().MedicationDispenseDeclined.medication is now accessible. The QICore 6.0.0 model info mapped it to a plain value with no notDoneValueSet target, unlike the other negation profiles. USQualityCoreCommon.medication() covers it.abatement() and severity() do not resolve in 0.5.0. Both are declared against hl7.org/fhir/StructureDefinition/familymemberhistory-* — the http:// scheme is missing, so the URL will not match the extension on the instance. The profile slices themselves are correct. In addition, doNotPerform() does not resolve against a DeviceRequest, it is only defined for the DeviceNotRequested profile. These issues have all been addressed by adding overloads for these functions to the CQMCommon library, and tickets to address these issues in the source content are being filed.individualSex() targets an extension US Core 6.1.0 does not define. USCoreCommon reads us-core-individual-sex, which was introduced after 6.1.0. It coalesces with us-core-sex, so it still resolves against 6.1.0 data; sex() itself is marked @deprecated in favor of it.sexParameterForClinicalUse() reads a base FHIR extension that no profile slices. It targets http://hl7.org/fhir/StructureDefinition/patient-sexParameterForClinicalUse, which is not part of US Core 6.1.0 and is not declared on any QI Core or US Quality Core profile.The Extension Index above covers every element that the profiles represent as an extension. This index covers the remaining slices — the value- and pattern-discriminated slices on category, identifier, class, component, and code.coding. They follow exactly the same story as the extensions: the profiles are unchanged, but the model info no longer surfaces the slice as an element.
Every non-extension slice in QI Core STU6 is present at the same element path with the same slice name in US Quality Core 0.5.0. Nothing was added, removed, or renamed at the profile level. The difference is entirely in the model info: the QICore 6.0.0 model info was profile-informed, so it flattened each slice into a named model element, and CQL could write Coverage.memberid or Observation.VSCat directly. Neither the USQualityCore 0.5.0 model info nor the USCore 6.1.0-derived model info it builds on declares a single slice element — no element in either one carries a slice target. All slice access is now through fluent functions. Where no published library supplies one, a function is drafted in CQMConcepts in this guide, annotated with the library it is being proposed for; those are marked proposed in the tables below.
Note that most of these slice names are not valid CQL identifiers and had to be quoted (Condition."us-core"). Note also that, apart from VSCat, none of them carried a navigation target in the QICore 6.0.0 model info either, so in practice the QI Core expression resolved to a path named after the slice rather than to the sliced content. For those elements the refactor did not remove working access so much as remove the appearance of it.
Category slices
| Profile | Slice | Accessor in US Quality Core |
|---|---|---|
| ConditionEncounterDiagnosis | Condition.category:us-core |
isEncounterDiagnosis() |
| ConditionProblemsHealthConcerns | Condition.category:us-core |
isProblemListItem(), isHealthConcern() |
Condition.category:screening-assessment |
isScreeningAssessment() (CQMConcepts, proposed for USCoreCommon) | |
| LaboratoryResultObservation | Observation.category:us-core |
isLaboratory() |
| ObservationClinicalResult | Observation.category:us-core |
hasCategory(Observation, Code) |
| SimpleObservation | Observation.category:us-core |
hasCategory(Observation, Code) |
| ObservationScreeningAssessment | Observation.category:survey |
isSurvey() |
Observation.category:screening-assessment |
isScreeningAssessment() (CQMConcepts, proposed for USCoreCommon) | |
| MedicationRequest | MedicationRequest.category:us-core |
isCommunity(), isDischarge(), hasCategory(MedicationRequest, Code) |
| MedicationNotRequested | MedicationRequest.category:us-core |
isCommunity(), isDischarge(), hasCategory(MedicationRequest, Code) |
| CarePlan | CarePlan.category:AssessPlan |
isAssessPlan() (CQMConcepts, proposed for USCoreCommon), hasCategory(CarePlan, Code) (CQMConcepts, proposed for FHIRCommon) |
| DiagnosticReportLab | DiagnosticReport.category:LaboratorySlice |
isLaboratory(DiagnosticReport) (CQMConcepts, proposed for FHIRCommon) |
| DiagnosticReportNote | DiagnosticReport.category:us-core |
hasCategory(DiagnosticReport, Code) (CQMConcepts, proposed for FHIRCommon) |
| ServiceRequest | ServiceRequest.category:us-core |
hasCategory(ServiceRequest, Code) (CQMConcepts, proposed for FHIRCommon) |
| ServiceNotRequested | ServiceRequest.category:us-core |
hasCategory(ServiceRequest, Code) (CQMConcepts, proposed for FHIRCommon) |
Identifier and class slices
| Profile | Slice | Accessor in US Quality Core |
|---|---|---|
| Coverage | Coverage.identifier:memberid |
memberID() |
Coverage.class:group |
groupNumber() (CQMConcepts, proposed for USCoreElements) | |
Coverage.class:plan |
planNumber() (CQMConcepts, proposed for USCoreElements) | |
| Organization | Organization.identifier:NPI |
npi(Organization) (CQMConcepts, proposed for USCoreElements) |
Organization.identifier:CLIA |
clia() (CQMConcepts, proposed for USCoreElements) | |
Organization.identifier:NAIC |
naic() (CQMConcepts, proposed for USCoreElements) | |
Organization.identifier:ccn |
ccn() (CQMConcepts, proposed for USQualityCoreCommon) | |
Organization.identifier:ein |
ein(Organization) (CQMConcepts, proposed for USQualityCoreCommon) | |
| Practitioner | Practitioner.identifier:NPI |
npi(Practitioner) (CQMConcepts, proposed for USCoreElements) |
Practitioner.identifier:ein |
ein(Practitioner) (CQMConcepts, proposed for USQualityCoreCommon) |
ccn and ein are QI Core additions carried into US Quality Core; the rest are inherited from US Core 6.1.0. USCoreElements also supplies memberID(), policyNumber(), and medicalRecordNumber(), which read identifiers by type rather than by system.
Slices on US Core profiles used directly
Neither QI Core nor US Quality Core profiles the US Core vital signs, occupation, or smoking status profiles — they are used as published. The QICore 6.0.0 model info flattened them in anyway (as USCoreBloodPressureProfile and so on) and exposed their slices; the USCore 6.1.0-derived model info does not.
| US Core 6.1.0 profile | Slice | Accessor |
|---|---|---|
| us-core-vital-signs and the 12 profiles derived from it | Observation.category:VSCat |
isVitalSign() |
| us-core-blood-pressure | Observation.component:systolic |
systolic() |
Observation.component:diastolic |
diastolic() | |
| us-core-pulse-oximetry | Observation.code.coding:PulseOx |
isPulseOximetry() (CQMConcepts, proposed for USCoreCommon) |
Observation.code.coding:O2Sat |
isPulseOximetry() (CQMConcepts, proposed for USCoreCommon) | |
Observation.component:FlowRate |
flowRate() (CQMConcepts, proposed for USCoreCommon) | |
Observation.component:Concentration |
concentration() (CQMConcepts, proposed for USCoreCommon) | |
| us-core-smokingstatus | Observation.category:SocialHistory |
isSocialHistory() |
| us-core-observation-pregnancystatus | Observation.category:SocialHistory |
isSocialHistory() |
| us-core-observation-pregnancyintent | Observation.category:SocialHistory |
isSocialHistory() |
| us-core-observation-occupation | Observation.category:socialhistory |
isSocialHistory() |
Observation.component:industry |
industry() (CQMConcepts, proposed for USCoreCommon) |
Notes on accessing slices from CQL
Use the named function for the slice. The functions marked proposed follow the shape the published libraries already use for the equivalent slices - a hasCategory() overload and an is prefixed predicate for category slices, following FHIRCommon, and a singleton from accessor for component slices, following the USCoreCommon systolic() and diastolic() functions. Each one filters the unsliced element on the slice discriminator, matching what the profile declares:
codesystem "USCoreCarePlanCategoryCodes": 'http://hl7.org/fhir/us/core/CodeSystem/careplan-category'
code "Assess and Plan": 'assess-plan' from "USCoreCarePlanCategoryCodes" display 'Assess and Plan'
// CarePlan.category:AssessPlan - pattern discriminator on a fixed coding, so the predicate tests the
// category for that coding, exactly as the FHIRCommon isProblemListItem() and isVitalSign() predicates do
define fluent function hasCategory(carePlan FHIR.CarePlan, category Code):
exists (carePlan.category C
where C ~ category
)
define fluent function isAssessPlan(carePlan FHIR.CarePlan):
carePlan.hasCategory("Assess and Plan")
// Organization.identifier:NPI - pattern discriminator on identifier.system. The slice is 0..*, so the
// accessor returns a list; the 0..1 identifier slices (ccn, ein) use singleton from instead
define fluent function npi(organization FHIR.Organization):
organization.identifier I
where I.system = 'http://hl7.org/fhir/sid/us-npi'
return I.value
Notes on the above content:
hasCategory() overload exists upstream for CarePlan, DiagnosticReport, or ServiceRequest. FHIRCommon defines hasCategory() only for Condition, Observation, and MedicationRequest. The overloads for the other three, and the isLaboratory(DiagnosticReport) predicate, are drafted in CQMConcepts and proposed for FHIRCommon, since none of them is US-specific.npi(), clia(), naic(), ccn(), or ein(), so measures that identified a provider or facility by Practitioner.NPI or Organization.ccn under QI Core must filter identifier by system. Those functions are drafted in CQMConcepts; npi(), clia(), and naic() are proposed for USCoreElements, while ccn() and ein() are proposed for USQualityCoreCommon, because those two slices are QI Core additions rather than US Core content.USQualityCore."Coverage.Class.group" and "Coverage.Class.plan" are still declared, as are USCore."Observation.Component.systolic", ".diastolic", ".FlowRate", ".Concentration", and ".industry", but no element in either model info has those types — all 22 component elements in the USCore 6.1.0-derived model info are plain USCore."Observation.Component". The types are inert; they cannot be reached by navigation.Observation.value[x]:valueCodeableConcept on NonPatientObservation, ObservationCancelled, and SimpleObservation, and the effective[x] slices on the occupation and smoking status profiles, are type slices on a choice element. Neither model info surfaces them as named elements; use the usual choice-type handling described in the uv/cql patterns page.