dQM QICore Content Implementation Guide
2025.0.0 - CI Build

dQM QICore Content Implementation Guide, published by cqframework. This guide is not an authorized publication; it is the continuous build for version 2025.0.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/cqframework/dqm-content-qicore-2025/ and changes regularly. See the Directory of published versions

Library: CMS157FHIRPainIntensityQuantified

Official URL: https://madie.cms.gov/Library/CMS157FHIRPainIntensityQuantified Version: 1.0.000
Active as of 2025-08-22 Responsible: American Society of Clinical Oncology Computable Name: CMS157FHIRPainIntensityQuantified
Other Identifiers: https://madie.cms.gov/login#CMS157FHIRPainIntensityQuantified (use: official, )

CMS157FHIRPainIntensityQuantified

Metadata
Title CMS157FHIRPainIntensityQuantified
Version 1.0.000
Identifier CMS157FHIRPainIntensityQuantified
Steward (Publisher) American Society of Clinical Oncology
Description

CMS157FHIRPainIntensityQuantified

Type http://terminology.hl7.org/CodeSystem/library-type#logic-library
Data Requirement Type: Patient
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-patient
Data Requirement Type: Encounter
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter
Must Support Elements: type
Code Filter(s):
Path: type
ValueSet: Office Visit
Data Requirement Type: Encounter
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter
Must Support Elements: type
Code Filter(s):
Path: type
ValueSet: Audio Visual Telehealth Encounter
Data Requirement Type: Procedure
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-procedure
Must Support Elements: code, performed, status, status.value
Code Filter(s):
Path: code
ValueSet: Chemotherapy Administration
Data Requirement Type: Encounter
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter
Must Support Elements: type, period, status, status.value
Code Filter(s):
Path: type
ValueSet: Radiation Treatment Management
Data Requirement Type: Condition
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-problems-health-concerns
Must Support Elements: code
Code Filter(s):
Path: code
ValueSet: Cancer
Data Requirement Type: Condition
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-encounter-diagnosis
Must Support Elements: code
Code Filter(s):
Path: code
ValueSet: Cancer
Data Requirement Type: Observation
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-observation-screening-assessment
Must Support Elements: code, value
Code Filter(s):
Path: code
ValueSet: Standardized Pain Assessment Tool
Data Requirement Type: Observation
Profile(s): http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-observation-screening-assessment
Must Support Elements: code, value, effective
Code Filter(s):
Path: code
ValueSet: Standardized Pain Assessment Tool
Parameters
Name Use Card. Type Documentation
Measurement Period In 0..1 Period
Patient Out 0..1 Resource
Chemotherapy Within 31 Days Prior and During Measurement Period Out 0..* Resource
Face to Face or Telehealth Encounter with Ongoing Chemotherapy Out 0..* Resource
Initial Population 1 Out 0..* Resource
Denominator 1 Out 0..* Resource
Radiation Treatment Management During Measurement Period with Cancer Diagnosis Out 0..* Resource
Initial Population 2 Out 0..* Resource
Denominator 2 Out 0..* Resource
Standard Pain Assessment with Result Out 0..* Resource
Numerator 1 Out 0..* Resource
Numerator 2 Out 0..* Resource
SDE Ethnicity Out 0..1 Resource
SDE Payer Out 0..* Resource
SDE Race Out 0..1 Resource
SDE Sex Out 0..1 Coding
Library Content
CQL Content
library CMS157FHIRPainIntensityQuantified version '1.0.000'

using QICore version '6.0.0'

include FHIRHelpers version '4.4.000' called FHIRHelpers
include CQMCommon version '4.1.000' called CQMCommon
include QICoreCommon version '4.0.000' called QICoreCommon
include SupplementalDataElements version '5.1.000' called SDE

codesystem "CPT": 'http://www.ama-assn.org/go/cpt'

valueset "Audio Visual Telehealth Encounter": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.1444.5.215'
valueset "Cancer": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1010'
valueset "Chemotherapy Administration": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1027'
valueset "Office Visit": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1001'
valueset "Radiation Treatment Management": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1026'
valueset "Standardized Pain Assessment Tool": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1028'

code "Radiation treatment management, 5 treatments": '77427' from "CPT" display 'Radiation treatment management, 5 treatments'

parameter "Measurement Period" Interval<DateTime>
  default Interval[@2026-01-01T00:00:00.000Z, @2027-01-01T00:00:00.000Z)

context Patient

define "Denominator 1":
  "Initial Population 1"

define "Denominator 2":
  "Initial Population 2"

define "Initial Population 1":
  "Face to Face or Telehealth Encounter with Ongoing Chemotherapy"

define "Initial Population 2":
  "Radiation Treatment Management During Measurement Period with Cancer Diagnosis"

define "Chemotherapy Within 31 Days Prior and During Measurement Period":
  [Procedure: "Chemotherapy Administration"] ChemoAdministration
    where ChemoAdministration.performed.toInterval ( ) during Interval[start of "Measurement Period" - 31 days, end of "Measurement Period"]
      and ChemoAdministration.status in { 'completed', 'in-progress' }

define "Face to Face or Telehealth Encounter with Ongoing Chemotherapy":
  from
    ( [Encounter: "Office Visit"]
      union [Encounter: "Audio Visual Telehealth Encounter"] ) FaceToFaceOrTelehealthEncounter,
    "Chemotherapy Within 31 Days Prior and During Measurement Period" ChemoBeforeEncounter,
    "Chemotherapy Within 31 Days Prior and During Measurement Period" ChemoAfterEncounter,
    ( [ConditionProblemsHealthConcerns: "Cancer"]
      union [ConditionEncounterDiagnosis: "Cancer"] ) CancerDx
    where CancerDx.prevalenceInterval ( ) overlaps day of FaceToFaceOrTelehealthEncounter.period
      and ChemoBeforeEncounter.performed.toInterval ( ) starts 30 days or less on or before day of end of FaceToFaceOrTelehealthEncounter.period
      and ChemoAfterEncounter.performed.toInterval ( ) starts 30 days or less on or after day of end of FaceToFaceOrTelehealthEncounter.period
      and not ( ChemoAfterEncounter.performed.toInterval ( ) same day as ChemoBeforeEncounter.performed.toInterval ( ) )
      and FaceToFaceOrTelehealthEncounter.period during day of "Measurement Period"
      and FaceToFaceOrTelehealthEncounter.status = 'finished'
    return FaceToFaceOrTelehealthEncounter

define "Numerator 1":
  "Face to Face or Telehealth Encounter with Ongoing Chemotherapy" FaceToFaceOrTelehealthEncounterWithChemo
    with "Standard Pain Assessment with Result" PainAssessed
      such that PainAssessed.effective.toInterval ( ) during day of FaceToFaceOrTelehealthEncounterWithChemo.period

define "Radiation Treatment Management During Measurement Period with Cancer Diagnosis":
  ( [Encounter: "Radiation Treatment Management"] ) RadiationTreatmentManagement
    with ( [ConditionProblemsHealthConcerns: "Cancer"]
      union [ConditionEncounterDiagnosis: "Cancer"] ) CancerDx
      such that CancerDx.prevalenceInterval ( ) overlaps day of RadiationTreatmentManagement.period
    where RadiationTreatmentManagement.period during day of "Measurement Period"
      and RadiationTreatmentManagement.status = 'finished'

define "Numerator 2":
  "Radiation Treatment Management During Measurement Period with Cancer Diagnosis" RadiationManagementEncounter
    with "Standard Pain Assessment with Result" PainAssessed
      such that case
        when exists ( ( RadiationManagementEncounter.type ) RadiationManagement
            where RadiationManagement ~ "Radiation treatment management, 5 treatments"
        ) then PainAssessed.effective.toInterval ( ) 6 days or less on or before day of start of RadiationManagementEncounter.period 
        else PainAssessed.effective.toInterval ( ) during day of RadiationManagementEncounter.period end

define "SDE Ethnicity":
  SDE."SDE Ethnicity"

define "SDE Payer":
  SDE."SDE Payer"

define "SDE Race":
  SDE."SDE Race"

define "SDE Sex":
  SDE."SDE Sex"

define "Standard Pain Assessment with Result":
  [ObservationScreeningAssessment: "Standardized Pain Assessment Tool"] AssessedPain
    where AssessedPain.value is not null
ELM XML Content
Encoded data 
ELM JSON Content
Encoded data 
Citations and References
Dependency Description: Library FHIRHelpers
Resource: FHIRHelpers version: 4.4.000
Canonical URL: https://madie.cms.gov/Library/FHIRHelpers|4.4.000
Dependency Description: Library CQMCommon
Resource: CQMCommon version: 4.1.000
Canonical URL: https://madie.cms.gov/Library/CQMCommon|4.1.000
Dependency Description: Library QICoreCommon
Resource: QICoreCommon version: 4.0.000
Canonical URL: https://madie.cms.gov/Library/QICoreCommon|4.0.000
Dependency Description: Library SDE
Resource: SupplementalDataElements version: 5.1.000
Canonical URL: https://madie.cms.gov/Library/SupplementalDataElements|5.1.000
Dependency Description: Code system CPT
Resource: Current Procedural Terminology (CPT®)
Canonical URL: http://www.ama-assn.org/go/cpt
Dependency Description: Value set Audio Visual Telehealth Encounter
Resource: Audio Visual Telehealth Encounter
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.1444.5.215
Dependency Description: Value set Cancer
Resource: Cancer
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1010
Dependency Description: Value set Chemotherapy Administration
Resource: Chemotherapy Administration
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1027
Dependency Description: Value set Office Visit
Resource: Office Visit
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1001
Dependency Description: Value set Radiation Treatment Management
Resource: Radiation Treatment Management
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1026
Dependency Description: Value set Standardized Pain Assessment Tool
Resource: Standardized Pain Assessment Tool
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1028
Generated using version 0.5.6 of the sample-content-ig Liquid templates