Observation observation implemented

Qualitative clinical findings: social history, lifestyle factors, survey responses, activity data. One FHIR Observation (or one component) maps to one OMOP observation row. Also receives data from AllergyIntolerance and FamilyMemberHistory.

Conversion profile omop-observation-observation
A FHIR instance converts to observation iff it validates against this profile.
Routing key Observation.code ∈ omop-observation-codes (OMOP domain Observation)
Path Card Type Binding / Fixed Comment
Observation.status fhir/observation-statusrequired
Observation.code 1..*MS omop-observation-codesrequired
Observation.subject 1..* Reference
Observation.effective[x] 1..*MS
ViewDefinition (Stage 1 flattener) omop-observation-observation
19 columns · resource Observation
column name FHIRPath type
id Observation.id id
code_loinc Observation.code.coding.where(system='http://loinc.org').first().code code
code_snomed Observation.code.coding.where(system='http://snomed.info/sct').first().code code
code_text Observation.code.text string
value_code_snomed Observation.valueCodeableConcept.coding.where(system='http://snomed.info/sct').first().code code
value_code_loinc Observation.valueCodeableConcept.coding.where(system='http://loinc.org').first().code code
value_code_text Observation.valueCodeableConcept.text string
subject_id Observation.subject Reference(Patient)
observation_date Observation.effectiveDateTime dateTime
observation_datetime Observation.effectiveDateTime dateTime
value_as_number Observation.valueQuantity.value decimal
value_as_string Observation.valueString string
qualifier_text Observation.interpretation[0].coding[0].code code
qualifier Observation.interpretation CodeableConcept
unit_text Observation.valueQuantity.unit string
unit Observation.valueQuantity.code code
performer_id Observation.performer[0] Reference(Practitioner)
encounter_id Observation.encounter Reference(Encounter)
value_text computed string
Condition: category is social-history, survey, or activity
Implementation: src/mapper/observation.ts

Fields (21)

Vocabularies

interpretation

Source Display Concept ID Concept Name
H High -
L Low -
N Normal -
A Abnormal -
HH Critical high -
LL Critical low -

social_history_loinc

Source Display Concept ID Concept Name
72166-2 Tobacco smoking status -
11367-0 History of tobacco use -
74013-4 Alcoholic drinks per day -
11331-6 History of alcohol use -
76689-9 Sex assigned at birth -

domain_routing

Source Display Concept ID Concept Name
social-history -
survey -
activity -
laboratory -
vital-signs -
(absent) Absent or unknown category -

Edge Cases

valueString present
Maps directly to value_as_string.
valueCodeableConcept with no matching OMOP concept
value_as_concept_id=null. Text goes to value_as_string.
valueBoolean
Not mapped. Could use value_as_string='true'/'false' or concept IDs 4188539/4188540.
interpretation with multiple codings
Only first coding used for qualifier_source_value.
Status not in {final, amended, corrected}
Skip entire observation.
Missing effectiveDateTime
Skip -- observation_date is required.
effectivePeriod instead of dateTime
Use period.start.
Categories not in routing set (exam, imaging, therapy)
Route to measurement (default). HL7 IG routes these to observation.
LOINC code with Observation domain but lab category
Category wins (routes to measurement). ETL-German: domain wins.

Reference Implementations