diff --git a/.gitignore b/.gitignore index 914783c60..797e160ef 100644 --- a/.gitignore +++ b/.gitignore @@ -32,4 +32,5 @@ Thumbs.db input/tests/results # .env -.env \ No newline at end of file +.envlocal-templates +local-template diff --git a/input/images-source/dedup-workflow.plantuml b/input/images-source/dedup-workflow.plantuml new file mode 100644 index 000000000..851bc6d73 --- /dev/null +++ b/input/images-source/dedup-workflow.plantuml @@ -0,0 +1,53 @@ +@startuml +skinparam svgDimensionStyle false +hide footbox +participant "KenyaEMR 1" as EMR1 +participant "KenyaEMR 2" as EMR2 +participant "Data Mediator" as Data +participant "MPI" as MPI +participant "CQF Ruler" as CQL +participant "Report Generator" as Report + +activate CQL +loop Copy Data to FHIR/CQL Server + activate Data + activate EMR1 + Data -> EMR1: Query for FHIR resource updates\n**GET /////\n ?_lastUpdated=gtYYYY-MM-DD** + EMR1 -> Data: Return FHIR resources + deactivate EMR1 + activate MPI + Data -> MPI: Match Patient records to MPI + MPI -> Data: Return unique identifier + deactivate MPI + Data -> CQL: Save FHIR resources to server\n**PUT //////////**\nor\n**POST /////** + CQL -> Data: Return confirmation or error + deactivate Data +end + +loop Copy Data to FHIR/CQL Server + activate Data + activate EMR2 + Data -> EMR2: Query for FHIR resource updates\n**GET /////\n ?_lastUpdated=gtYYYY-MM-DD** + EMR2 -> Data: Return FHIR resources + deactivate EMR2 + activate MPI + Data -> MPI: Match Patient records to MPI + MPI -> Data: Return unique identifier + deactivate MPI + Data -> CQL: Save FHIR resources to server\n**PUT //////////**\nor\n**POST /////** + CQL -> Data: Return confirmation or error + deactivate Data +end + +activate Report +opt Update indicator resources + Report -> CQL: Save updated Measure, Library, Terminology resources\n**PUT //////////**\nor\n**POST /////** + CQL -> Report: Return confirmation or error +end + +Report -> CQL: Evaluate measure for the period\n**GET /Measure/TXCURR/$evaluate-measure\n ?periodStart=YYYY-MM-DD&periodEnd=YYYY-MM-DD** +CQL -> Report: Return MeasureReport +deactivate Report +deactivate CQL + +@enduml diff --git a/input/images-source/multiple-workflow.plantuml b/input/images-source/multiple-workflow.plantuml new file mode 100644 index 000000000..0d493478f --- /dev/null +++ b/input/images-source/multiple-workflow.plantuml @@ -0,0 +1,44 @@ +@startuml +skinparam svgDimensionStyle false +hide footbox +participant "KenyaEMR 1" as EMR1 +participant "KenyaEMR 2" as EMR2 +participant "Data Mediator" as Data +participant "CQF Ruler" as CQL +participant "Report Generator" as Report + +activate CQL +loop Copy Data to FHIR/CQL Server + activate Data + activate EMR1 + Data -> EMR1: Query for FHIR resource updates\n**GET /////\n ?_lastUpdated=gtYYYY-MM-DD** + EMR1 -> Data: Return FHIR resources + deactivate EMR1 + Data -> CQL: Save FHIR resources to server\n**PUT //////////**\nor\n**POST /////** + CQL -> Data: Return confirmation or error + deactivate Data +end + +loop Copy Data to FHIR/CQL Server + activate Data + activate EMR2 + Data -> EMR2: Query for FHIR resource updates\n**GET /////\n ?_lastUpdated=gtYYYY-MM-DD** + EMR2 -> Data: Return FHIR resources + deactivate EMR2 + Data -> CQL: Save FHIR resources to server\n**PUT //////////**\nor\n**POST /////** + CQL -> Data: Return confirmation or error + deactivate Data +end + +activate Report +opt Update indicator resources + Report -> CQL: Save updated Measure, Library, Terminology resources\n**PUT //////////**\nor\n**POST /////** + CQL -> Report: Return confirmation or error +end + +Report -> CQL: Evaluate measure for the period\n**GET /Measure/TXCURR/$evaluate-measure\n ?periodStart=YYYY-MM-DD&periodEnd=YYYY-MM-DD** +CQL -> Report: Return MeasureReport +deactivate Report +deactivate CQL + +@enduml diff --git a/input/images-source/simple-workflow.plantuml b/input/images-source/simple-workflow.plantuml new file mode 100644 index 000000000..b48c011b3 --- /dev/null +++ b/input/images-source/simple-workflow.plantuml @@ -0,0 +1,32 @@ +@startuml +skinparam svgDimensionStyle false +hide footbox +participant "KenyaEMR" as EMR +participant "Data Mediator" as Data +participant "CQF Ruler" as CQL +participant "Report Generator" as Report + +activate CQL +loop Copy Data to FHIR/CQL Server + activate Data + activate EMR + Data -> EMR: Query for FHIR resource updates\n**GET /////\n ?_lastUpdated=gtYYYY-MM-DD** + EMR -> Data: Return FHIR resources + deactivate EMR + Data -> CQL: Save FHIR resources to server\n**PUT //////////**\nor\n**POST /////** + CQL -> Data: Return confirmation or error + deactivate Data +end + +activate Report +opt Update indicator resources + Report -> CQL: Save updated Measure, Library, Terminology resources\n**PUT //////////**\nor\n**POST /////** + CQL -> Report: Return confirmation or error +end + +Report -> CQL: Evaluate measure for the period\n**GET /Measure/TXCURR/$evaluate-measure\n ?periodStart=YYYY-MM-DD&periodEnd=YYYY-MM-DD** +CQL -> Report: Return MeasureReport +deactivate Report +deactivate CQL + +@enduml diff --git a/input/pagecontent/index.xml b/input/pagecontent/index.xml index cb410a256..83dd7d5a5 100644 --- a/input/pagecontent/index.xml +++ b/input/pagecontent/index.xml @@ -18,6 +18,7 @@

The top menu allows quick navigation to the different sections, and a Table of Contents is provided with the entire content of this Implementation Guide. (Be aware that some pages have multiple tabs).

+

Some workflows have been defined.

Intellectual Property Considerations

diff --git a/input/pagecontent/workflows.md b/input/pagecontent/workflows.md new file mode 100644 index 000000000..71ab882da --- /dev/null +++ b/input/pagecontent/workflows.md @@ -0,0 +1,32 @@ +## Simple Iteration + +This iteration is the simplest version where the KenyaEMR data is loaded into a FHIR Server with CQL support. This will work from multiple source data systems to get combined MeasureReports across all imported data. + +This iteration will also be specific to the KenyaEMR data model without needing mapping to unused data elements. Future iterations will be created to use a more standard model that is mapped to the KenyaEMR model. + +
+{% include simple-workflow.svg %} +
+
+ +## Simple Standard Iteration + +This iteration is exactly the same as the Simple Iteration, but the CQL logic will be system agnostic and require mapping of concepts and possibly custom CQL expressions to align with the system specific data model. + +## Multiple Source Iteration + +This iteration adds some further complexity in importing data from multiple EMRs. This doesn't include any deduplication, but shows how any number of systems can send data to the CQL server. + +
+{% include multiple-workflow.svg %} +
+
+ +## Multiple Sources with Deduplication + +This iteration adds in a deduplication service to ensure data from multiple sources aren't counted multiple times. The CQL logic will use the unique identifier from the MPI to avoid counting records mulitple times. + +
+{% include dedup-workflow.svg %} +
+
diff --git a/input/tests/server/OpenMRSFHIRExperiments.rest b/input/tests/server/OpenMRSFHIRExperiments.rest index 5eac7f4b9..8a3499554 100644 --- a/input/tests/server/OpenMRSFHIRExperiments.rest +++ b/input/tests/server/OpenMRSFHIRExperiments.rest @@ -1,5 +1,5 @@ @fhir = https://demo.openmrs.org/openmrs/ws/fhir2/R4 -@auth = user:pass +@auth = admin:Admin123 GET {{fhir}}/Patient?_count=100 HTTP/1.1 Authorization: Basic {{auth}} @@ -25,4 +25,8 @@ Authorization: Basic {{auth}} ### GET {{fhir}}/Encounter/24638591-9586-4b2b-a511-17bc1b79d1ba HTTP/1.1 +Authorization: Basic {{auth}} + +### +GET {{fhir}}/metadata Authorization: Basic {{auth}} \ No newline at end of file diff --git a/sushi-config.yaml b/sushi-config.yaml index 990d26eeb..57ec4f73b 100644 --- a/sushi-config.yaml +++ b/sushi-config.yaml @@ -137,9 +137,14 @@ dependencies: # file name extension. Any subproperties that are valid filenames # with supported extensions (e.g., .md/.xml) will be treated as # sub-pages. -#pages: -# index.md: -# title: Example Home +pages: + index.xml: + title: Home + changes.xml: + title: Changes + workflows.md: + title: Workflows + generation: markdown # implementation.xml: # examples.xml: # title: Examples Overview @@ -167,9 +172,10 @@ dependencies: # currently only supports one level deep on sub-menus. # To provide a custom menu.xml file, do not include this property and # include a `menu.xml` file in input/includes. -#menu: -# Home: index.html -# Artifacts: +menu: + Home: index.html + Workflows: workflows.html + Artifacts: artifacts.html # Profiles: artifacts.html#2 # Extensions: artifacts.html#3 # Value Sets: artifacts.html#4