CDCgov / prime-reportstream

ReportStream is a public intermediary tool for delivery of data between different parts of the healthcare ecosystem.
https://reportstream.cdc.gov
Creative Commons Zero v1.0 Universal
67 stars 39 forks source link

Fix mappings when OBX.2 is CE #14685

Closed arnejduranovic closed 1 month ago

arnejduranovic commented 1 month ago

Describe the bug

When processing the message below in the UP (HL7v2 sender HL7v2 receiver) the output HL7v2 is missing data from OBX.3 and OBX.5

MSH|^~\&|SISGDSP|SISGDSP|SISHIERECEIVER^11223344^L,M,N|^simulated-hospital-id^L,M,N|20230706093730||ORU^R01^ORU_R01|220220550|T|2.5.1
PID|1||^^^NPI^MR||Smith^John^^^^^B||202202050000|||2106-3^White||||||||||||2186-5^Not Hispanic or Latino||N|1
NK1|1|Smith^Sarah|MTH^Mother|850 Marina Bay Parkway, APT 125^^Richmond^CA^94806-4000^USA|^^^^^916^3720117|^^^^^916^3729999||||||||||199107010000
ORC|RE|^FormNumber||^HospOrdNumber||||||||^CORTEZ^ALAN^^^^^^^NPI||||||||||300 PASTEUR DR, RM H1524^^PALO ALTO^CA^94305-2200
OBR|1|^FormNumber||54089-8^NB Screen Panel Patient AHIC|||202202070000|||||||||^James^Smith||||||20230706093730|||F
OBR|2|^FormNumber||57128-1^Newborn Screening Report summary panel|||202202070000|||||||||^James^Smith||||||20230706093730|||F
OBX|1|CE|57721-3^Reason for lab test in Dried blood spot^LN|1|LA12421-6^Initial screen^LN|||N|||F|||20230706093730
OBX|2|CE|57718-9^Sample quality of Dried blood spot^LN|1|LA12432-3^Acceptable^LN|||N|||F|||20230706093730
OBX|3|CE|57130-7^Newborn screening report - overall interpretation^LN|1|LA12428-1^All screening is in range for the conditions tested^LN|||N|||F|||20230706093730
OBX|4|CE|57131-5^Newborn conditions with positive markers [Identifier] in Dried blood spot^LN|1|LA137-2^None^LN|||N|||F|||20230706093730
OBX|5|CE|57720-5^Newborn conditions with equivocal markers [Identifier] in Dried blood spot^LN|1|LA137-2^None^LN|||N|||F|||20230706093730
OBX|6|TX|57724-7^Newborn screening short narrative summary^LN|1|NBS Testing Lab - COMMUNITY REG MEDICAL CENTER LAB \R\2823 FRESNO ST, FRESNO, CA 93721-1324\.br\\.br\Genetic Disease Laboratory - GDL 850 MARINA BAY PKWY, # G265, RICHMOND, CA 94804-6403\.br\\.br\Lab Director - Rasoul Alikhani Koupaei, PhD., Genetic Disease Laboratory, (510) 231-1790\.br\\.br\\.br\\.br\If you have any questions regarding these screening outcomes, please contact the Newborn Screening Staff at Stanford University Medical Center at (510) 412-1562. \.br\\.br\Methods and Limitations:\.br\\.br\Assays for ALD Tier-1, ALD Tier-2, Pompe Tier-1, MPS I Tier-1 and SMA were developed and/or optimized by the California Department of Public Health Genetic Disease Laboratory Branch (GDLB). Performance characteristics of aforementioned assays are determined by GDLB. The SMA assay is designed to identify 95% of SMA patients who have homozygous deletion/mutation of SMN1 gene in 5q chromosome. All aforementioned assays have not been cleared or approved by the U.S. Food and Drug Administration (FDA). The FDA has determined that such clearance or approval is not necessary. The assays are used for clinical purposes and should not be regarded as investigational or for research. GDLB is certified under the Clinical Laboratory Improvement Amendments of 1988 (CLIA-88) to perform high complexity genetic disease screening. \.br\Attention Healthcare Provider:\.br\\.br\Due to biological variability of newborns and differences in detection rates for the various disorders in the newborn period, the Newborn Screening Program will not identify all newborns with these conditions. While a positive screening result identifies newborns at an increased risk to justify a diagnostic work-up, a negative screening result does not rule out the possibility of a disorder. Health care providers should remain watchful for any sign or symptoms of these disorders in their patients. A newborn screening result should not be considered diagnostic, and cannot replace the individualized evaluation and diagnosis of an infant by a well-trained, knowledgeable health care provider. \.br\\.br\ |||N|||F|||20230706093730
OBX|7|TX|57129-9^Full newborn screening summary report for display or printing^LN|1||||N|||F|||20230706093730

Impact on ReportStream

ETOR cannot move forward with pilot. RS can't properly map HL7v2 messages when value of OBX.2 is CE.

Steps to reproduce

Steps to reproduce the behavior:

  1. Submit above message in local dev as a HL7v2 sender
  2. Have HL7v2 receiver receive it
  3. Verify the output message is missing data in OBX.3 and OBX.5

Expected behavior

Output HL7v2 should match input HL7v2

Additional context

This issue appears when OBX.2 is set to CE. This is a known issue that our OBX -> Observation mappings are not correct. We should make the following changes to make the mappings more correct and THEN see if it fixes the issue above.

If these changes don't fix the issue above, then figure out why and make additional changes as needed. Also, make sure the following commented out test passes now: test converts with CE for obx2 OBXToObservationTests

Andrey-Glazkv commented 1 month ago

Hey team! Please add your planning poker estimate with Zenhub @adegolier @arnejduranovic @brick-green @david-navapbc @jack-h-wang @jalbinson @JFisk42 @mkalish @thetaurean

basiliskus commented 1 month ago

In case it helps, I did some debugging last week on this issue and found a couple of things:

FYI, this is the ticket where we're tracking this issue on our side. It also has some more context: https://github.com/CDCgov/trusted-intermediary/issues/1133

jorg3lopez commented 1 month ago

I also took a look at this issue.

Findings:

CWE datatype:

image

CE datatype:

image