Problem list, allergies and observations (SP7)

Featurekamo-shared-library
Shipped
August 25, 2026 at 5:09 PM UTC
Author
Kamo
Commit
c0ac7cf

The three chart tables where a modelling mistake harms a patient rather than annoying a user. Condition carries TWO independent statuses because conflating them is the classic error. clinicalStatus says whether the patient still has it; verificationStatus says how sure anyone is. A ruled-out differential is active/refuted — collapse them and you either leave a refuted condition on the problem list or delete a real one that was never formally confirmed, which is most working diagnoses. Refuted and entered-in-error are also why a condition is never deleted: "we considered this and it is not so" is information the next clinician needs. AllergyIntolerance carries a no-known-allergy SENTINEL, and this is the safety-critical one. An empty allergy list is ambiguous — "asked, nothing found" and "nobody has asked" are completely different clinical facts, and an absent row means the second while reading like the first. A prescriber seeing a blank list reasonably infers it is safe to prescribe. The sentinel is a real row recording who asked and when, so absence can mean unasked. criticality is kept separate from severity because a mild rash that is early anaphylaxis is low severity and high criticality, and only one of those tells a prescriber to stop. Observation gives value[x] real typed columns rather than one stringified one, because the type is part of what was recorded and quantity search is most of what an Observation is for. interpretation is STORED, never derived: reference ranges vary by method and population, so recomputing against today's range silently reclassifies historical results. dataAbsentReason exists because a cancelled test and one nobody ran otherwise look identical. And a correction SUPERSEDES via supersedesObservationId rather than inserting a second row — two potassiums on a flowsheet is how a clinician acts on the stale one. isUnacknowledgedAbnormal deliberately excludes uninterpreted results: flooding the inbox is how a real abnormal gets lost in the noise, and missed follow-up on abnormal results is a leading ambulatory diagnostic-error category. 1718 tests green.

All changes

Like what you see shipping?

Every one of these updates lands in your workspace automatically. Start free and watch it grow week after week.

Start Free ForeverView Pricing