Stream: cql
Topic: how to export all fhir data
Vasyl Herman (Jan 21 2021 at 11:51):
Hi!
I have a question on how to export all FHIR Bundles from an FHIR API for performing healthcare quality measures using cql-execution and cql-exec-fhir. The FHIR Data Source (for cql-exec-fhir) expects each patient to be represented as a single FHIR Bundle containing all of the patient's relevant data.
I have read the article https://hl7.org/fhir/uv/bulkdata/ that says we should use FHIR based approach for exporting bulk data from a FHIR server. The fhir-downloader (another JS library) exports bulk data from a FHIR Server and store it localy as .ndjson files. however, FHIR Bundle is required.
I would approtialte any help to get an idea on how to glue all tools together to perform healthcare quality measures agaist all FHIR Bundles available on specific FHIR API source.
PS: is there a way to extract FHIR Bundles from .ndjson files? Is it correct approach?
Chris Moesel (Jan 21 2021 at 13:33):
Hi @Vasyl Herman -- I don't know enough about bulk FHIR to answer your questions about that, but I expect it would not be terribly difficult to write some code that could build a bundle from the .ndjson results. It may already exist, I don't know. Another approach, if your server supports it, would be to use the Patient $everything operator -- although it is admittedly not optimized for massive amounts of data.
Since you're talking about FHIR-based measures and cql-execution / cql-exec-fhir, I also wanted to be sure you know about the open source fqm-execution project. It uses cql-execution and cql-exec-fhir, but also provides some of the CQM-specific logic you would want when processing measures. If JavaScript is not a requirement, and Java is OK, you may also want to check out cqf-ruler. I think it can do FHIR measures (@Bryn Rhodes, correct me if I am wrong) and it dynamically queries the FHIR server for you (so you don't need to get all the data in bulk up front). But... it is Java, not JavaScript.
Paul Denning (Jan 21 2021 at 14:56):
Also see the Connectathon 26 clinical reasoning track, data element submission (data exchange scenarios) . It was noted that "Consider bulk data" does not necessarily mean using the Bulk Data IG, but could also mean using Asynchronous Request Pattern. IBM supports bulk operations https://ibm.github.io/FHIR/guides/FHIRBulkOperations/ but not sure they support Measure operations.
Bryn Rhodes (Jan 21 2021 at 15:03):
Yes, confirming that cqf-ruler does support Measure evaluation, but it does so with the local server's data.
Chris Moesel (Feb 01 2021 at 17:27):
Bryn Rhodes said:
Yes, confirming that cqf-ruler does support Measure evaluation, but it does so with the local server's data.
Quick follow-up question, @Bryn Rhodes -- is this the case for CQF Ruler's CDS Hooks support as well? Or can the CDS Hooks implementation query the fhirServer
from the CDS Hooks request?
JP (Feb 01 2021 at 17:58):
It can query the fhirServer
.
Bryn Rhodes (Feb 01 2021 at 18:48):
There are lots of options for how that happens, and we're working to standardize the parameters for those options. Take a look at the Library/$evaluate operation here: http://build.fhir.org/ig/HL7/cqf-recommendations/OperationDefinition-cpg-library-evaluate.html
Last updated: Apr 12 2022 at 19:14 UTC