Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ecqm-bundler

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ecqm-bundler - npm Package Compare versions

Comparing version 0.3.2 to 0.4.0

50

dist/helpers/fhir.js

@@ -127,5 +127,51 @@ "use strict";

}
function generateMeasureResource(measureId, libraryId, canonicalBase, groupInfo, measureVersion) {
function makeSupplementalData(supplementalData, riskAdjustmentFactors) {
const sdes = [];
if (supplementalData && supplementalData.length > 0) {
supplementalData.forEach(sde => {
sdes.push({
id: (0, uuid_1.v4)(),
usage: [
{
coding: [
{
system: 'http://terminology.hl7.org/CodeSystem/measure-data-usage',
code: 'supplemental-data'
}
]
}
],
criteria: {
language: 'text/cql-identifier',
expression: sde
}
});
});
}
if (riskAdjustmentFactors && riskAdjustmentFactors.length > 0) {
riskAdjustmentFactors.forEach(raf => {
sdes.push({
id: (0, uuid_1.v4)(),
usage: [
{
coding: [
{
system: 'http://terminology.hl7.org/CodeSystem/measure-data-usage',
code: 'risk-adjustment-factor'
}
]
}
],
criteria: {
language: 'text/cql-identifier',
expression: raf
}
});
});
}
return sdes;
}
function generateMeasureResource(measureId, libraryId, canonicalBase, groupInfo, measureVersion, supplementalData, riskAdjustmentFactors) {
logger_1.default.info(`Creating Measure/${measureId}`);
return Object.assign(Object.assign({ resourceType: 'Measure', id: measureId }, (measureVersion && { version: measureVersion })), { url: combineURLs(canonicalBase, `/Measure/${measureId}`), status: 'draft', library: [combineURLs(canonicalBase, `/Library/${libraryId}`)], group: groupInfo.map(gi => {
return Object.assign(Object.assign({ resourceType: 'Measure', id: measureId }, (measureVersion && { version: measureVersion })), { url: combineURLs(canonicalBase, `/Measure/${measureId}`), status: 'draft', library: [combineURLs(canonicalBase, `/Library/${libraryId}`)], supplementalData: makeSupplementalData(supplementalData, riskAdjustmentFactors), group: groupInfo.map(gi => {
const group = {

@@ -132,0 +178,0 @@ id: (0, uuid_1.v4)(),

6

dist/index.js

@@ -30,3 +30,3 @@ #!/usr/bin/env node

const program = new commander_1.Command();
program.version('v0.3.2');
program.version('v0.4.0');
program

@@ -40,2 +40,4 @@ .command('generate', { isDefault: true })

.option('--deps-directory <path>', 'Directory containing all dependent CQL or ELM files')
.option('--sde <sde...>', 'Supplemental Data Element expression(s) used in the measure')
.option('--raf <raf...>', 'Risk Adjustment Variable expression(s) used in the measure')
.option('--ipop <expr...>', '"initial-Population" expression name(s) of measure (enter multiple values for a multiple ipp ratio measure)')

@@ -341,3 +343,3 @@ .option('--numer <expr>', '"numerator" expression name of measure')

const measureFHIRId = `measure-${mainLibraryId}`;
const measure = (0, fhir_1.generateMeasureResource)(measureFHIRId, libraryFHIRId, baseOpts.canonicalBase, allGroupInfo, baseOpts.measureVersion);
const measure = (0, fhir_1.generateMeasureResource)(measureFHIRId, libraryFHIRId, baseOpts.canonicalBase, allGroupInfo, baseOpts.measureVersion, opts.sde, opts.raf);
logger_1.default.info('Resolving dependencies/relatedArtifact');

@@ -344,0 +346,0 @@ const mainLibDeps = (0, elm_1.getDependencyInfo)(mainLibELM);

{
"name": "ecqm-bundler",
"version": "0.3.2",
"version": "0.4.0",
"description": "CLI for bundling FHIR-based eCQMs",

@@ -5,0 +5,0 @@ "main": "dist/index.js",

@@ -95,2 +95,18 @@ # ecqm-bundler

### Supplemental Data Elements
To add [Supplemental Data Elements (SDEs)](https://build.fhir.org/ig/HL7/cqf-measures/measure-conformance.html#supplemental-data-elements) to a Measure, simply include expression name(s) using the `--sde` flag:
```bash
ecqm-bundler generate <...> --sde "SDE 1 Expression Name" "SDE 2 Expression Name" "..."
```
### Risk Adjustment Variables
To add [Risk Adjustment Variables](https://build.fhir.org/ig/HL7/cqf-measures/measure-conformance.html#risk-adjustment) to a Measure, simply include expression name(s) using the `--raf` flag:
```bash
ecqm-bundler generate <...> --raf "RAF 1 Expression Name" "RAF 2 Expression Name" "..."
```
### ValueSet Resolution

@@ -97,0 +113,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc