This is modeled after the ASBI Screening App. The app can be used in conjuction with the SMART® app launch framework.
CQL is a domain-specific programming language focused on clinical quality applications, including CDS as well as electronic clinical quality measures (eCQMs). Logical expressions written in CQL are human-readable but can also be compiled to a machine-friendly format to facilitate implementation. This application executes CQL logic to provide patient customized behavior. Machine-friendly versions of the CQL are embedded in this app; For more information about CQL see here; For more information about how to compile CQL code into machine-readable format, see here.
Vue is a JavaScript front-end framework for building user interfaces. The application was built using the vue create
command from the Vue command line interface (CLI).
Vuetify is a Vue UI library with Material Design themed UI components that can be used for the application.
All CQL calculations are executed using the CQL Execution Engine, an open source library that implements the CQL standard.
All CQL calculations are executed within the context of a Web Worker, thereby offloading them to a separate thread. This greatly improves the responsiveness of the application.
A number of options are available for local usage to support testing with synthetic data.
This project manages dependencies using the Yarn package manager in the Node environment (Node version <= 16 is recommended for this application). Make sure to have both Yarn and Node installed before proceeding. The dependencies for the application can be installed locally by typing yarn
at the command line. A local version of the app can be launched by typing yarn serve
at the command line. A copy suitable for distribution can be built using the yarn build
command.
The value set content used by the CQL is cached in a file named valueset-db.json, which has been checked into this project in an empty state. In order for the CDS to operate as intended, implementers must populate valueset-db.json with the value sets which have been published on the Value Set Authority Center (VSAC). In order to access VSAC, you must sign up for a UMLS Terminology Services account.
Once a UMLS Terminology Services account has been obtained, the valueset-db.json file can be updated by running the following:
- Run
node src/util/updateValueSetDB.js UMLS_API_KEY
(replacing UMLS_API_KEY with your actual UMLS API key)
To get you UMLS API Key:
- Sign into your UMLS account at https://uts.nlm.nih.gov/uts.html
- Click 'My Profile' in the orange banner at the top of the screen
- Your API key should be listed below your username in the table
- If no API key is listed:
- Click ‘Edit Profile’
- Select the ‘Generate new API Key’ checkbox
- Click ‘Save Profile’
- Your new API key should now be listed.
Parameters for the app are stored in environmental variables that are stored in an .env
file (run cp default.env .env
at command line to create the .env file) and it allows the environment variables thus specified to be read by the application at build time. The dotenv package is used to store the default variable values, which can be overwritten by defining a more specific env (e.g., .env.local
) file or by setting the variables in the deployment system. For more information, see the Vue documentation.
Parameter | Description | Allowed Values |
---|---|---|
VUE_APP_FHIR_RESOURCES |
Define the FHIR resource(s) to load for the patient | Condition,Procedure,Observation,Questionnaire,QuestionnaireResponse |
VUE_APP_FHIR_OBSERVATION_CATEGORIES |
Define what categor(ies) of FHIR observations to load for the patient | social-history,vital-signs,imaging,laboratory,procedure,survey,exam,therapy,activity |
VUE_APP_AUTH_SCOPES |
For allowing the app to specify the delegation of a specific set of access rights via launch context. see App Launch: Scopes and Launch Context | profile roles email patient/*.read openid fhirUser patient/QuestionnaireResponse.write |
VUE_APP_SYSTEM_TYPE |
Define system type | development , demo , staging , production |
A public SMART® App Launcher is available for sandbox tesing of SMART on FHIR apps with synthetic data.
| VUE_APP_DASHBOARD_URL
| Define the (f)EMR URL to which the app can return to | example, https://dashboard.acc.dev.cosri.cirg.washington.edu
Navigate to the public SMART® App Launcher and choose the "Provider EHR Launch" Launch Type. Uncheck "Simulate launch within the EHR user interface". Leave all other options unselected. Paste the URL to where launch.html
, e.g. http://localhost:8080/launch.html
, is being served from into the "App Launch URL" box at the bottom of the SMART® App Launcher page. Select "Launch App!" which will bring up a patient selector widget before the app is launched.