Expand description
Clinical documents / pathology — Restricted, records-first clinical entries.
Implements the master plan’s clinical-document rules (audit CLI-01..13, plan §5):
- Records-first, manual entry. A
ClinicalReportcaptures what the owner (or a labelled author) actually typed. There is NO parsing of pathology/imaging PDFs here — a mock extractor must never be presented as real parsing. Structured extraction, when it exists, is a separate audited stage that raises its own records; this module only stores hand-entered documents and their attachment metadata. - Content-addressed attachments (plan §5). The attachment content is a
content-addressed blob stored elsewhere.
AttachmentMetaholds only metadata plus the content hash — never the bytes. - Honest epistemics. An unconfirmed report is asserted by its author, not
observed by a clinician. Only a
ClinicianConfirmedreport maps toEvidenceType::ClinicianObserved; aDisputedreport is surfaced asEpistemicStatus::Disputed. The envelope never launders a self-reported claim into clinician-grade evidence.
Structs§
- Attachment
Meta - Metadata for a content-addressed attachment blob (plan §5).
- Clinical
Report - A manually-entered clinical document (pathology / imaging / discharge / referral).
Enums§
- Claim
Event - Events that can move a
ClaimStatusalong its lifecycle. - Claim
Status - Claim-approval lifecycle for a clinical document.
- Clinical
Report Type - Category of a manually-entered clinical document.
Functions§
- advance_
claim - Advance the claim lifecycle for a given event, returning the resulting status.
- build_
clinical_ attachment_ envelope - Build the record envelope for an attachment’s metadata. The blob hash is carried both
as the content anchor and (redundantly for the graph) as the envelope
blob_hash. - build_
clinical_ report_ envelope - Build the record envelope for a clinical report, deriving epistemic/evidence honesty
from its claim status. Always
Restricted. - clinical_
attachment_ record_ id - record ID.
- clinical_
attachment_ summary - summary.
- clinical_
report_ record_ id - record ID.
- clinical_
report_ summary - summary.