moonbit-triage

Explainable emergency triage scoring primitives for MoonBit.

triage
NEWS2
qSOFA
GCS
SOFA
HEART
Wells
clinical-score
audit
observability
risk-stratification
moon add agentdebug799/moonbit-triage@0.4.0
Download zip
Version
0.4.0
License
Apache-2.0
Last updated
7 hours ago
Downloads
6
README

#moonbit-triage

moonbit-triage is a dependency-free MoonBit library for explainable, auditable clinical score computation in education, software validation, data-quality pipelines, and prototype integrations. It returns component contributions and structured range errors so a caller can inspect exactly how a result was made.

The library computes early-warning, cardiorespiratory, neurologic, trauma, gastrointestinal, renal/hepatic, perioperative, and pediatric/obstetric scores, including NEWS2, qSOFA, GCS, SIRS, MEWS, SOFA, PEWS, CURB-65, Shock Index, ROX, Wells, HEART, CHA2DS2-VASc, PESI, BODE, qCSI, Hestia, RTS, ISS, NIHSS, FOUR, ABCD2, APACHE II, SMART-COP, Caprini, Padua, STOP-Bang, ARISCAT, Child-Pugh, MELD-Na, Glasgow-Blatchford, AKI, BISAP, Ranson, Alvarado, Bishop, and preeclampsia feature checks. It also provides observation timelines, assessment ledgers, pathway decisions, audit events, registry diffs, batch summaries, and measurement-quality flags.

#Core capabilities

  • Typed inputs with explicit inclusive threshold functions.
  • Component-level explanations and stable severity bands.
  • First-error validation for common measurement ranges.
  • Integer-scaled ratio APIs (Shock Index x100, ROX Index x100) for portable, deterministic results across MoonBit targets.
  • Batch summaries and quality flags for form or data-pipeline integration.
  • Observation timelines, trend extraction, threshold evaluation, and freshness checks for longitudinal data.
  • Assessment ledgers, deterministic pathway escalation, audit events, and a versioned instrument registry for traceable integrations.
  • No external runtime dependencies; wasm-gc is the preferred target.

#Quick start

moon check moon test moon run cmd/main

The runnable CLI prints a combined NEWS2/qSOFA/GCS assessment and its summary. For a deterministic workload used by the benchmark section, run:

moon run cmd/benchmark

#CLI

The example CLI is intentionally small and demonstrates the public API rather than acting as a clinical decision system. Applications can construct records, call score_*, inspect ScoreReport.explanations, and route validation errors through their own forms or service boundaries.

#Minimal example

///|
test "README NEWS2 example" {
let report = @moonbit-triage.score_news2({
respiratory_rate: 16,
oxygen_saturation: 98,
spo2_scale: @moonbit-triage.Scale1,
supplemental_oxygen: false,
temperature_tenths_c: 370,
systolic_bp: 120,
heart_rate: 72,
consciousness: @moonbit-triage.Alert,
})
inspect(report.score, content="0")
debug_inspect(report.severity, content="Low")
}

#Architecture and API shape

The public API intentionally uses plain records and enums so that callers can wire the library into CLI tools, web forms, or data-validation pipelines without extra dependencies. Each ScoreReport includes:

  • instrument: scoring instrument name.
  • score: numeric total.
  • severity: local library band for software routing.
  • interpretation: short explanation of the band.
  • explanations: component-level point contributions.
  • disclaimer: safety boundary text.

The root package owns the public data types and scoring facade. Focused files contain each instrument family; observation_pipeline.mbt handles longitudinal measurements, assessment.mbt handles score snapshots, pathway.mbt handles escalation and audit events, and registry*.mbt handles instrument metadata and release diffs. quality.mbt handles measurement metadata and batch.mbt handles deterministic aggregation. The generated pkg.generated.mbti is checked in as a compact public API review surface.

#Sources and safety

The implementation follows publicly described scoring thresholds for NEWS2, qSOFA, and GCS. The qSOFA criteria are also summarized by the public qSOFA project: respiratory rate at least 22/min, systolic blood pressure at most 100 mmHg, and GCS below 15. Clinical scoring rules can be embedded in local protocols differently, so downstream projects should review the thresholds against their intended policy before use.

This project is for education, audit, and software validation. It is not a medical device and must not replace clinician judgment.

Rule provenance, primary reference links, implementation scope, and explicit non-claims are documented in PROVENANCE.md.

Every score is a rule implementation, not a diagnosis. This package must not be used as a substitute for clinician judgment, local policy, or a regulated medical-device workflow. Downstream users are responsible for validating the chosen thresholds, patient population, units, and escalation policy.

#Benchmarks

The checked-in benchmark runs 10,000 NEWS2 calculations and prints a checksum and count, making correctness and workload size reproducible without claiming hardware-independent latency. On the maintainer workstation with MoonBit 0.1.20260807, the command produced:

iterations=10000 checksum=54000 critical_reports=4500

Measure wall-clock time locally with PowerShell (Measure-Command { moon runcmd/benchmark }) or /usr/bin/time on Unix; report the machine and toolchain when comparing runs.

#Tests and CI

The test suite covers threshold transitions, invalid ranges, aggregate scores, clinical edge cases, longitudinal data quality, pathway decisions, registry diffs, report serialization, and deterministic summaries. The current native coverage run executes 2,349 of 3,354 instrumented lines (70.0%). GitHub Actions runs formatting, all-target checks, public API generation, wasm-gc tests, native tests, and a coverage summary on Linux, macOS, and Windows.

#Development notes

  • MoonBit module: agentdebug799/moonbit-triage.
  • License: Apache-2.0.
  • Preferred target: wasm-gc.
  • Validation used for release: moon fmt --check, moon check --deny-warn, moon info, moon test --deny-warn, and the benchmark command.

#License

Apache-2.0. See LICENSE.

#
Abcd2Input

pub(all) struct Abcd2Input {
age : Int
systolic_bp : Int
diastolic_bp : Int
unilateral_weakness : Bool
speech_impairment_without_weakness : Bool
symptom_duration_minutes : Int
diabetes : Bool
} derive(Eq,
Debug
)

#
AkiInput

pub(all) struct AkiInput {
baseline_creatinine_hundredths : Int
current_creatinine_hundredths : Int
urine_rate_hundredths_ml_kg_h : Int
urine_duration_hours : Int
} derive(Eq,
Debug
)

#
AlvaradoInput

pub(all) struct AlvaradoInput {
migration_of_pain : Bool
anorexia : Bool
nausea_or_vomiting : Bool
right_lower_quadrant_tenderness : Bool
rebound_tenderness : Bool
fever_tenths_c : Int
leukocytosis : Bool
left_shift : Bool
} derive(Eq,
Debug
)

#
ApacheIiInput

pub(all) struct ApacheIiInput {
temperature_tenths_c : Int
mean_arterial_pressure : Int
heart_rate : Int
respiratory_rate : Int
oxygenation_value : Int
high_fio2 : Bool
arterial_ph_hundredths : Int
sodium : Int
potassium_tenths : Int
creatinine_hundredths : Int
acute_renal_failure : Bool
hematocrit_tenths : Int
white_cell_count_tenths : Int
gcs : Int
age : Int
chronic_health : Bool
} derive(Eq,
Debug
)

#
AriscatInput

pub(all) struct AriscatInput {
age : Int
preoperative_oxygen_saturation : Int
respiratory_infection_last_month : Bool
preoperative_anemia : Bool
surgical_incision_site : Int
expected_duration_minutes : Int
emergency_surgery : Bool
} derive(Eq,
Debug
)

#
AssessmentLedger

pub(all) struct AssessmentLedger {
snapshots : Array[ScoreSnapshot]
last_timestamp_minutes : Int
} derive(Eq,
Debug
)

#
AssessmentSummary

pub(all) struct AssessmentSummary {
snapshots : Int
instruments : Int
total_score : Int
highest : Severity
latest_timestamp_minutes : Int
} derive(Eq,
Debug
)

#
AuditEvent

pub(all) struct AuditEvent {
sequence : Int
event_type : String
instrument : String
score : Int
severity : Severity
timestamp_minutes : Int
source : String
note : String
} derive(Eq,
Debug
)

#
BisapInput

pub(all) struct BisapInput {
bun_mmol_l_tenths : Int
impaired_mentation : Bool
sirs_criteria : Int
age : Int
pleural_effusion : Bool
} derive(Eq,
Debug
)

#
BishopInput

pub(all) struct BishopInput {
dilation_cm : Int
effacement_percent : Int
fetal_station : Int
cervical_consistency : Int
cervical_position : Int
} derive(Eq,
Debug
)

#
BodeInput

pub(all) struct BodeInput {
body_mass_index : Int
fev1_percent : Int
modified_mrc : Int
six_minute_walk_meters : Int
} derive(Eq,
Debug
)

#
CanadianCspineInput

pub(all) struct CanadianCspineInput {
age : Int
dangerous_mechanism : Bool
paresthesias : Bool
low_risk_simple_rear_end_collision : Bool
low_risk_sitting_in_ed : Bool
low_risk_ambulatory : Bool
low_risk_delayed_neck_pain : Bool
low_risk_no_midline_tenderness : Bool
rotates_neck_45_degrees : Bool
} derive(Eq,
Debug
)

#
CanadianCtHeadInput

pub(all) struct CanadianCtHeadInput {
age : Int
gcs_less_than_15_at_two_hours : Bool
suspected_open_skull_fracture : Bool
signs_of_basal_skull_fracture : Bool
vomiting_episodes : Int
age_at_least_65 : Bool
retrograde_amnesia_minutes : Int
dangerous_mechanism : Bool
anticoagulant_or_antiplatelet : Bool
} derive(Eq,
Debug
)

#
CapriniInput

pub(all) struct CapriniInput {
age : Int
bmi_over_25 : Bool
swollen_legs : Bool
varicose_veins : Bool
pregnancy_or_postpartum : Bool
oral_contraceptives_or_hormone : Bool
sepsis : Bool
serious_lung_disease : Bool
abnormal_pulmonary_function : Bool
acute_myocardial_infarction : Bool
congestive_heart_failure : Bool
inflammatory_bowel_disease : Bool
medical_patient : Bool
minor_surgery : Bool
arthroscopic_surgery : Bool
major_surgery : Bool
laparoscopic_surgery_over_45_min : Bool
malignancy : Bool
bed_rest_over_72_hours : Bool
prior_vte : Bool
family_history_vte : Bool
thrombophilia : Bool
stroke : Bool
elective_arthroplasty : Bool
hip_pelvis_leg_fracture : Bool
acute_spinal_cord_injury : Bool
} derive(Eq,
Debug
)

#
Cha2ds2VascInput

pub(all) struct Cha2ds2VascInput {
congestive_failure : Bool
hypertension : Bool
age : Int
diabetes : Bool
stroke_or_tia : Bool
vascular_disease : Bool
sex_female : Bool
} derive(Eq,
Debug
)

#
CharlsonInput

pub(all) struct CharlsonInput {
age : Int
myocardial_infarction : Bool
congestive_heart_failure : Bool
peripheral_vascular_disease : Bool
cerebrovascular_disease : Bool
dementia : Bool
chronic_pulmonary_disease : Bool
connective_tissue_disease : Bool
peptic_ulcer_disease : Bool
mild_liver_disease : Bool
diabetes_without_complication : Bool
diabetes_with_end_organ_damage : Bool
hemiplegia : Bool
moderate_or_severe_renal_disease : Bool
any_tumor : Bool
leukemia : Bool
lymphoma : Bool
moderate_or_severe_liver_disease : Bool
metastatic_solid_tumor : Bool
aids : Bool
} derive(Eq,
Debug
)

#
ChildPughInput

pub(all) struct ChildPughInput {
bilirubin_tenths_mg_dl : Int
albumin_tenths_g_dl : Int
inr_hundredths : Int
ascites_grade : Int
encephalopathy_grade : Int
} derive(Eq,
Debug
)

#
Consciousness

pub(all) enum Consciousness {
Alert
NewConfusion
Voice
Pain
Unresponsive
} derive(Eq,
Debug
)

#
Curbs65Input

pub(all) struct Curbs65Input {
confusion : Bool
urea_mmol : Int
respiratory_rate : Int
systolic_bp : Int
diastolic_bp : Int
age : Int
} derive(Eq,
Debug
)

#
EscalationTier

pub(all) enum EscalationTier {
Routine
Review
Urgent
Immediate
} derive(Eq,
Debug
)

#
EvidenceStatus

pub(all) enum EvidenceStatus {
EvidenceComplete
EvidencePartial
EvidenceMissing
EvidenceInvalid
} derive(Eq,
Debug
)

#
Explanation

pub(all) struct Explanation {
label : String
points : Int
detail : String
} derive(Eq,
Debug
)

#
FourScoreInput

pub(all) struct FourScoreInput {
eye_response : Int
motor_response : Int
brainstem_reflexes : Int
respiration : Int
} derive(Eq,
Debug
)

#
GcsInput

pub(all) struct GcsInput {
eye : Int
verbal : Int
motor : Int
} derive(Eq,
Debug
)

#
GcsReport

pub(all) struct GcsReport {
total : Int
eye : Int
verbal : Int
motor : Int
severity : Severity
explanations : Array[Explanation]
disclaimer : String
} derive(Eq,
Debug
)

#
GlasgowBlatchfordInput

pub(all) struct GlasgowBlatchfordInput {
bun_mmol_l_tenths : Int
hemoglobin_g_dl_tenths : Int
female : Bool
systolic_bp : Int
pulse : Int
melena : Bool
syncope : Bool
hepatic_disease : Bool
cardiac_failure : Bool
} derive(Eq,
Debug
)

#
HasBledInput

pub(all) struct HasBledInput {
hypertension : Bool
abnormal_renal : Bool
abnormal_liver : Bool
stroke : Bool
bleeding_history : Bool
labile_inr : Bool
age_over_65 : Bool
drugs_or_alcohol : Bool
} derive(Eq,
Debug
)

#
HeartInput

pub(all) struct HeartInput {
history : Int
ecg : Int
age : Int
risk_factors : Int
troponin : Int
} derive(Eq,
Debug
)

#
HestiaInput

pub(all) struct HestiaInput {
unstable : Bool
oxygen_saturation_low : Bool
active_bleeding : Bool
need_thrombolysis : Bool
severe_renal_impairment : Bool
severe_liver_impairment : Bool
social_barrier : Bool
pregnancy : Bool
history_bleeding : Bool
treatment_failure : Bool
} derive(Eq,
Debug
)

#
InjurySeverityInput

pub(all) struct InjurySeverityInput {
head_neck : Int
face : Int
chest : Int
abdomen : Int
extremity : Int
external : Int
} derive(Eq,
Debug
)

#
InstrumentCategory

pub(all) enum InstrumentCategory {
EarlyWarning
Cardiorespiratory
Neurology
Trauma
Gastrointestinal
RenalHepatic
Perioperative
ObstetricPediatric
Workflow
} derive(Eq,
Debug
)

#
InstrumentMetadata

pub(all) struct InstrumentMetadata {
id : String
display_name : String
category : InstrumentCategory
unit : String
minimum : Int
maximum : Int
source_url : String
version : String
caution : String
keywords : Array[String]
} derive(Eq,
Debug
)

#
InstrumentRegistry

pub(all) struct InstrumentRegistry {
entries : Array[InstrumentMetadata]
revision : String
} derive(Eq,
Debug
)

#
MeasurementQuality

pub(all) enum MeasurementQuality {
Complete
Missing
OutOfRange
Suspicious
} derive(Eq,
Debug
)

#
MeasurementUnit

pub(all) enum MeasurementUnit {
BeatsPerMinute
BreathsPerMinute
MillimetersMercury
Percent
CelsiusTenths
MilligramsPerDeciliter
MillimolesPerLiter
MicromolesPerLiter
ScorePoints
Unknown
} derive(Eq,
Debug
)

#
MeldNaInput

pub(all) struct MeldNaInput {
bilirubin_tenths_mg_dl : Int
inr_hundredths : Int
creatinine_tenths_mg_dl : Int
sodium : Int
dialysis_twice_last_week : Bool
} derive(Eq,
Debug
)

#
MewsInput

pub(all) struct MewsInput {
systolic_bp : Int
heart_rate : Int
respiratory_rate : Int
temperature_tenths_c : Int
consciousness : Consciousness
} derive(Eq,
Debug
)

#
News2Input

pub(all) struct News2Input {
respiratory_rate : Int
oxygen_saturation : Int
spo2_scale : Spo2Scale
supplemental_oxygen : Bool
temperature_tenths_c : Int
systolic_bp : Int
heart_rate : Int
consciousness : Consciousness
} derive(Eq,
Debug
)

#
NexusCspineInput

pub(all) struct NexusCspineInput {
posterior_midline_tenderness : Bool
focal_neurologic_deficit : Bool
altered_alertness : Bool
intoxication : Bool
painful_distracting_injury : Bool
} derive(Eq,
Debug
)

#
NihssInput

pub(all) struct NihssInput {
consciousness : Int
questions : Int
commands : Int
gaze : Int
visual : Int
facial : Int
left_arm : Int
right_arm : Int
left_leg : Int
right_leg : Int
ataxia : Int
sensory : Int
language : Int
dysarthria : Int
neglect : Int
} derive(Eq,
Debug
)

#
Observation

pub(all) struct Observation {
kind : ObservationKind
value : Int
unit : MeasurementUnit
timestamp_minutes : Int
source : String
} derive(Eq,
Debug
)

#
ObservationIssue

pub(all) enum ObservationIssue {
NegativeTimestamp
EmptySource
UnitMismatch
NonFiniteRange
} derive(Eq,
Debug
)

#
ObservationKind

pub(all) enum ObservationKind {
HeartRate
RespiratoryRate
SystolicBloodPressure
DiastolicBloodPressure
OxygenSaturation
Temperature
GlasgowComaScale
WhiteCellCount
PlateletCount
Bilirubin
Creatinine
Custom
} derive(Eq,
Debug
)

#
OttawaAnkleInput

pub(all) struct OttawaAnkleInput {
posterior_edge_lateral_malleolus_tender : Bool
posterior_edge_medial_malleolus_tender : Bool
base_of_fifth_metatarsal_tender : Bool
navicular_tender : Bool
unable_to_bear_four_steps : Bool
} derive(Eq,
Debug
)

#
PaduaInput

pub(all) struct PaduaInput {
active_cancer : Bool
previous_vte : Bool
reduced_mobility : Bool
known_thrombophilia : Bool
recent_trauma_or_surgery : Bool
elderly_age : Bool
heart_or_respiratory_failure : Bool
acute_mi_or_stroke : Bool
acute_infection_or_rheumatologic : Bool
bmi_over_30 : Bool
ongoing_hormonal_treatment : Bool
} derive(Eq,
Debug
)

#
PathwayDecision

pub(all) struct PathwayDecision {
tier : EscalationTier
evidence : EvidenceStatus
matched_rules : Array[String]
missing_instruments : Array[String]
highest_severity : Severity
score_count : Int
explanation : String
} derive(Eq,
Debug
)

#
PathwayRule

pub(all) struct PathwayRule {
code : String
title : String
tier : EscalationTier
required_instruments : Array[String]
minimum_severity : Severity
rationale : String
} derive(Eq,
Debug
)

#
PecarnHeadInput

pub(all) struct PecarnHeadInput {
age_under_two : Bool
altered_mentation : Bool
palpable_skull_fracture : Bool
nonfrontal_scalp_hematoma : Bool
loss_of_consciousness_minutes : Int
severe_mechanism : Bool
not_behaving_normally : Bool
signs_of_basilar_skull_fracture : Bool
severe_headache : Bool
} derive(Eq,
Debug
)

#
PediatricAppendicitisInput

pub(all) struct PediatricAppendicitisInput {
migration_of_pain : Bool
anorexia : Bool
nausea_or_vomiting : Bool
right_lower_quadrant_tenderness : Bool
cough_hopping_percussion_pain : Bool
fever_tenths_c : Int
leukocytosis : Bool
neutrophilia : Bool
} derive(Eq,
Debug
)

#
PercInput

pub(all) struct PercInput {
age : Int
heart_rate : Int
oxygen_saturation : Int
hemoptysis : Bool
estrogen_use : Bool
prior_vte : Bool
recent_surgery_or_trauma : Bool
unilateral_leg_swelling : Bool
} derive(Eq,
Debug
)

#
PesiInput

pub(all) struct PesiInput {
age : Int
male : Bool
nursing_home : Bool
cancer : Bool
heart_failure : Bool
chronic_lung_disease : Bool
heart_rate : Int
systolic_bp : Int
temperature_tenths_c : Int
altered_mentation : Bool
oxygen_saturation : Int
} derive(Eq,
Debug
)

#
PewsBehavior

pub(all) enum PewsBehavior {
Playing
Sleeping
Irritable
Lethargic
} derive(Eq,
Debug
)

#
PewsCardiovascular

pub(all) enum PewsCardiovascular {
Normal
Tachycardic
PoorPerfusion
} derive(Eq,
Debug
)

#
PewsInput

pub(all) struct PewsInput {
behavior : PewsBehavior
cardiovascular : PewsCardiovascular
respiratory : PewsRespiratory
oxygen_support : PewsOxygenSupport
nebulizer_count : Int
} derive(Eq,
Debug
)

#
PewsOxygenSupport

pub(all) enum PewsOxygenSupport {
RoomAir
LowFlow
HighFlow
} derive(Eq,
Debug
)

#
PewsRespiratory

pub(all) enum PewsRespiratory {
Normal
ModerateDistress
SevereDistress
} derive(Eq,
Debug
)

#
PreeclampsiaInput

pub(all) struct PreeclampsiaInput {
systolic_bp : Int
diastolic_bp : Int
platelets_thousands : Int
creatinine_hundredths_mg_dl : Int
ast_units : Int
alt_units : Int
pulmonary_edema : Bool
persistent_headache : Bool
visual_symptoms : Bool
right_upper_quadrant_pain : Bool
fetal_growth_restriction : Bool
} derive(Eq,
Debug
)

#
QcsiInput

pub(all) struct QcsiInput {
respiratory_rate : Int
oxygen_saturation : Int
oxygen_flow_liters : Int
} derive(Eq,
Debug
)

#
QsofaInput

pub(all) struct QsofaInput {
respiratory_rate : Int
systolic_bp : Int
gcs_total : Int
} derive(Eq,
Debug
)

#
QualityFlag

pub(all) struct QualityFlag {
field : String
quality : MeasurementQuality
message : String
} derive(Eq,
Debug
)

#
QualitySummary

pub(all) struct QualitySummary {
total : Int
complete : Int
missing : Int
out_of_range : Int
suspicious : Int
} derive(Eq,
Debug
)

#
RansonInput

pub(all) struct RansonInput {
age : Int
wbc_tenths : Int
glucose_mg_dl : Int
ldh_units : Int
ast_units : Int
hematocrit_drop_tenths : Int
bun_rise_mg_dl : Int
calcium_mg_dl_tenths : Int
arterial_oxygen_mmhg : Int
base_deficit : Int
fluid_sequestration_liters : Int
} derive(Eq,
Debug
)

#
RcriInput

pub(all) struct RcriInput {
high_risk_surgery : Bool
ischemic_heart_disease : Bool
heart_failure : Bool
cerebrovascular_disease : Bool
diabetes_on_insulin : Bool
creatinine_above_2 : Bool
} derive(Eq,
Debug
)

#
RegistryChange

pub(all) struct RegistryChange {
id : String
kind : RegistryChangeKind
before_version : String
after_version : String
detail : String
} derive(Eq,
Debug
)

#
RegistryChangeKind

pub(all) enum RegistryChangeKind {
Added
Removed
Updated
Unchanged
} derive(Eq,
Debug
)

#
ReportComparison

pub(all) struct ReportComparison {
left_instrument : String
right_instrument : String
left_score : Int
right_score : Int
left_more_concerning : Bool
score_delta : Int
} derive(Eq,
Debug
)

#
ReportQuality

pub(all) struct ReportQuality {
total : Int
nonempty : Int
reconciled : Int
coherent : Bool
disclaimer_count : Int
} derive(Eq,
Debug
)

#
ReportSummary

pub(all) struct ReportSummary {
count : Int
total_score : Int
highest : Severity
low_count : Int
medium_count : Int
high_count : Int
critical_count : Int
} derive(Eq,
Debug
)

#
RevisedTraumaInput

pub(all) struct RevisedTraumaInput {
gcs_total : Int
systolic_bp : Int
respiratory_rate : Int
} derive(Eq,
Debug
)

#
RoxInput

pub(all) struct RoxInput {
oxygen_saturation : Int
fio2_percent : Int
respiratory_rate : Int
} derive(Eq,
Debug
)

#
RuleEvaluation

pub(all) struct RuleEvaluation {
rule_name : String
value : Int
matched : Bool
points : Int
band : String
explanation : String
} derive(Eq,
Debug
)

#
ScoreReport

pub(all) struct ScoreReport {
instrument : String
score : Int
severity : Severity
interpretation : String
explanations : Array[Explanation]
disclaimer : String
} derive(Eq,
Debug
)

#
ScoreSnapshot

pub(all) struct ScoreSnapshot {
instrument : String
score : Int
severity : Severity
timestamp_minutes : Int
source : String
} derive(Eq,
Debug
)

#
Severity

pub(all) enum Severity {
Low
Medium
High
Critical
} derive(Eq,
Debug
)

#
ShockIndexInput

pub(all) struct ShockIndexInput {
heart_rate : Int
systolic_bp : Int
} derive(Eq,
Debug
)

#
SirsInput

pub(all) struct SirsInput {
temperature_tenths_c : Int
heart_rate : Int
respiratory_rate : Int
white_cell_count : Int
immature_neutrophils_percent : Int
} derive(Eq,
Debug
)

#
SmartCopInput

pub(all) struct SmartCopInput {
systolic_bp : Int
multilobar_infiltrates : Bool
albumin_tenths_g_dl : Int
respiratory_rate : Int
age : Int
confusion : Bool
oxygen_saturation : Int
arterial_ph_hundredths : Int
} derive(Eq,
Debug
)

#
SnapshotChange

pub(all) enum SnapshotChange {
Increased(Int)
Decreased(Int)
Unchanged
InstrumentChanged
} derive(Eq,
Debug
)

#
SofaInput

pub(all) struct SofaInput {
pao2_fio2 : Int
respiratory_support : Bool
platelets : Int
bilirubin_micromol : Int
mean_arterial_pressure : Int
vasopressor : VasopressorLevel
gcs_total : Int
creatinine_micromol : Int
urine_ml_day : Int
} derive(Eq,
Debug
)

#
Spo2Scale

pub(all) enum Spo2Scale {
Scale1
Scale2
} derive(Eq,
Debug
)

#
StopBangInput

pub(all) struct StopBangInput {
snoring : Bool
tiredness : Bool
observed_apnea : Bool
hypertension : Bool
bmi_over_35 : Bool
age_over_50 : Bool
neck_circumference_over_40_cm : Bool
male : Bool
} derive(Eq,
Debug
)

#
ThresholdBand

pub(all) struct ThresholdBand {
label : String
minimum : Int
maximum : Int
points : Int
explanation : String
} derive(Eq,
Debug
)

#
Timeline

pub(all) struct Timeline {
observations : Array[Observation]
last_timestamp_minutes : Int
} derive(Eq,
Debug
)

#
TimelineSummary

pub(all) struct TimelineSummary {
observations : Int
distinct_kinds : Int
invalid_observations : Int
earliest_timestamp : Int
latest_timestamp : Int
span_minutes : Int
} derive(Eq,
Debug
)

#
TimiInput

pub(all) struct TimiInput {
age_65_or_more : Bool
risk_factors : Int
known_coronary_stenosis : Bool
aspirin_last_7_days : Bool
severe_angina : Bool
st_deviation : Bool
positive_biomarker : Bool
} derive(Eq,
Debug
)

#
TraceSummary

pub(all) struct TraceSummary {
event_count : Int
unique_instruments : Int
first_timestamp : Int?
last_timestamp : Int?
invalid_event_count : Int
source_labels : Array[String]
} derive(Eq,
Debug
)

#
Trend

pub(all) struct Trend {
kind : ObservationKind
first_value : Int
latest_value : Int
delta : Int
samples : Int
rising : Bool
falling : Bool
stable : Bool
} derive(Eq,
Debug
)

#
TriageBundle

pub(all) struct TriageBundle {
news2 : ScoreReport
qsofa : ScoreReport
gcs : ScoreReport
overall : Severity
summary : String
disclaimer : String
} derive(Eq,
Debug
)

#
TriageInput

pub(all) struct TriageInput {
news2 : News2Input
gcs : GcsInput
} derive(Eq,
Debug
)

#
ValidationError

pub(all) enum ValidationError {
OutOfRange(field~ : String, value~ : Int, min~ : Int, max~ : Int)
InvalidScale(field~ : String, value~ : Int)
} derive(Eq,
Debug
)

#
VasopressorLevel

pub(all) enum VasopressorLevel {
None
DopamineLow
DopamineHigh
NorepinephrineLow
NorepinephrineHigh
} derive(Eq,
Debug
)

#
WellsDvtInput

pub(all) struct WellsDvtInput {
active_cancer : Bool
paralysis_or_immobilization : Bool
bedridden_or_surgery : Bool
tenderness_deep_veins : Bool
entire_leg_swollen : Bool
calf_swelling : Bool
previous_dvt : Bool
alternative_diagnosis : Bool
} derive(Eq,
Debug
)

#
WellsPeInput

pub(all) struct WellsPeInput {
clinical_dvt_signs : Bool
pe_most_likely : Bool
heart_rate : Int
surgery_or_immobilization : Bool
previous_dvt_or_pe : Bool
hemoptysis : Bool
malignancy : Bool
} derive(Eq,
Debug
)

#
abcd2_age_points

fn abcd2_age_points(value : Int) -> Int

#
abcd2_clinical_points

fn abcd2_clinical_points(unilateral : Bool, speech_only : Bool) -> Int

#
abcd2_diabetes_points

fn abcd2_diabetes_points(value : Bool) -> Int

#
abcd2_duration_points

fn abcd2_duration_points(minutes : Int) -> Int

#
abcd2_pressure_points

fn abcd2_pressure_points(systolic : Int, diastolic : Int) -> Int

#
abcd2_severity

fn abcd2_severity(score : Int) -> Severity

#
aki_creatinine_stage

fn aki_creatinine_stage(input : AkiInput) -> Int

#
aki_severity

fn aki_severity(stage : Int) -> Severity

#
aki_stage

fn aki_stage(input : AkiInput) -> Int

#
aki_urine_stage

fn aki_urine_stage(input : AkiInput) -> Int

#
alvarado_score

fn alvarado_score(input : AlvaradoInput) -> Int

#
alvarado_severity

fn alvarado_severity(score : Int) -> Severity

#
apache_age_points

fn apache_age_points(value : Int) -> Int

#
apache_chronic_points

fn apache_chronic_points(value : Bool) -> Int

#
apache_creatinine_points

fn apache_creatinine_points(value : Int) -> Int

#
apache_heart_rate_points

fn apache_heart_rate_points(value : Int) -> Int

#
apache_hematocrit_points

fn apache_hematocrit_points(value : Int) -> Int

#
apache_ii_score

fn apache_ii_score(input : ApacheIiInput) -> Int

#
apache_ii_severity

fn apache_ii_severity(score : Int) -> Severity

#
apache_map_points

fn apache_map_points(value : Int) -> Int

#
apache_oxygenation_points

fn apache_oxygenation_points(value : Int, high_fio2 : Bool) -> Int

#
apache_ph_points

fn apache_ph_points(value : Int) -> Int

#
apache_potassium_points

fn apache_potassium_points(value : Int) -> Int

#
apache_respiratory_rate_points

fn apache_respiratory_rate_points(value : Int) -> Int

#
apache_sodium_points

fn apache_sodium_points(value : Int) -> Int

#
apache_temp_points

fn apache_temp_points(value : Int) -> Int

#
apache_white_cell_points

fn apache_white_cell_points(value : Int) -> Int

#
ariscat_age_points

fn ariscat_age_points(age : Int) -> Int

#
ariscat_anemia_points

fn ariscat_anemia_points(value : Bool) -> Int

#
ariscat_duration_points

fn ariscat_duration_points(minutes : Int) -> Int

#
ariscat_emergency_points

fn ariscat_emergency_points(value : Bool) -> Int

#
ariscat_incision_points

fn ariscat_incision_points(value : Int) -> Int

#
ariscat_infection_points

fn ariscat_infection_points(value : Bool) -> Int

#
ariscat_oxygen_points

fn ariscat_oxygen_points(value : Int) -> Int

#
ariscat_severity

fn ariscat_severity(score : Int) -> Severity

#
assessment_summary

fn assessment_summary(ledger : AssessmentLedger) -> AssessmentSummary

#
audit_event

fn audit_event(sequence : Int, event_type : String, instrument : String, report : ScoreReport, timestamp_minutes : Int, source : String, note : String) -> AuditEvent

#
audit_event_label

fn audit_event_label(event : AuditEvent) -> String

#
audit_event_labels

fn audit_event_labels(events : Array[AuditEvent]) -> Array[String]

#
audit_ordered

fn audit_ordered(left : AuditEvent, right : AuditEvent) -> Bool

#
bisap_age_points

fn bisap_age_points(value : Int) -> Int

#
bisap_bun_points

fn bisap_bun_points(value : Int) -> Int

#
bisap_effusion_points

fn bisap_effusion_points(value : Bool) -> Int

#
bisap_mentation_points

fn bisap_mentation_points(value : Bool) -> Int

#
bisap_score

fn bisap_score(input : BisapInput) -> Int

#
bisap_severity

fn bisap_severity(score : Int) -> Severity

#
bisap_sirs_points

fn bisap_sirs_points(value : Int) -> Int

#
bishop_consistency_points

fn bishop_consistency_points(value : Int) -> Int

#
bishop_dilation_points

fn bishop_dilation_points(value : Int) -> Int

#
bishop_effacement_points

fn bishop_effacement_points(value : Int) -> Int

#
bishop_position_points

fn bishop_position_points(value : Int) -> Int

#
bishop_score

fn bishop_score(input : BishopInput) -> Int

#
bishop_severity

fn bishop_severity(score : Int) -> Severity

#
bishop_station_points

fn bishop_station_points(value : Int) -> Int

#
bode_bmi_points

fn bode_bmi_points(value : Int) -> Int

#
bode_fev1_points

fn bode_fev1_points(value : Int) -> Int

#
bode_mrc_points

fn bode_mrc_points(value : Int) -> Int

#
bode_severity

fn bode_severity(score : Int) -> Severity

#
bode_walk_points

fn bode_walk_points(value : Int) -> Int

#
canadian_cspine_high_risk_count

fn canadian_cspine_high_risk_count(input : CanadianCspineInput) -> Int

#
canadian_cspine_low_risk_count

fn canadian_cspine_low_risk_count(input : CanadianCspineInput) -> Int

#
canadian_cspine_positive

fn canadian_cspine_positive(input : CanadianCspineInput) -> Bool

#
canadian_ct_head_high_risk_count

fn canadian_ct_head_high_risk_count(input : CanadianCtHeadInput) -> Int

#
canadian_ct_head_medium_risk_count

fn canadian_ct_head_medium_risk_count(input : CanadianCtHeadInput) -> Int

#
canadian_ct_head_positive

fn canadian_ct_head_positive(input : CanadianCtHeadInput) -> Bool

#
caprini_age_points

fn caprini_age_points(age : Int) -> Int

#
caprini_bool_points

fn caprini_bool_points(value : Bool, points : Int) -> Int

#
caprini_five_point_count

fn caprini_five_point_count(input : CapriniInput) -> Int

#
caprini_score

fn caprini_score(input : CapriniInput) -> Int

#
caprini_severity

fn caprini_severity(score : Int) -> Severity

#
caprini_three_point_count

fn caprini_three_point_count(input : CapriniInput) -> Int

#
caprini_two_point_count

fn caprini_two_point_count(input : CapriniInput) -> Int

#
cha2ds2_vasc_age_points

fn cha2ds2_vasc_age_points(value : Int) -> Int

#
cha2ds2_vasc_flag_points

fn cha2ds2_vasc_flag_points(value : Bool) -> Int

#
cha2ds2_vasc_severity

fn cha2ds2_vasc_severity(score : Int) -> Severity

#
cha2ds2_vasc_stroke_points

fn cha2ds2_vasc_stroke_points(value : Bool) -> Int

#
charlson_age_points

fn charlson_age_points(age : Int) -> Int

#
charlson_bool_points

fn charlson_bool_points(value : Bool, points : Int) -> Int

#
charlson_common_points

fn charlson_common_points(input : CharlsonInput) -> Int

#
charlson_score

fn charlson_score(input : CharlsonInput) -> Int

#
charlson_severe_points

fn charlson_severe_points(input : CharlsonInput) -> Int

#
charlson_severity

fn charlson_severity(score : Int) -> Severity

#
charlson_systemic_points

fn charlson_systemic_points(input : CharlsonInput) -> Int

#
charlson_vascular_points

fn charlson_vascular_points(input : CharlsonInput) -> Int

#
child_pugh_albumin_points

fn child_pugh_albumin_points(value : Int) -> Int

#
child_pugh_ascites_points

fn child_pugh_ascites_points(value : Int) -> Int

#
child_pugh_bilirubin_points

fn child_pugh_bilirubin_points(value : Int) -> Int

#
child_pugh_class

fn child_pugh_class(score : Int) -> String

#
child_pugh_encephalopathy_points

fn child_pugh_encephalopathy_points(value : Int) -> Int

#
child_pugh_inr_points

fn child_pugh_inr_points(value : Int) -> Int

#
child_pugh_severity

fn child_pugh_severity(score : Int) -> Severity

#
clamp

fn clamp(value : Int, low : Int, high : Int) -> Int

#
compare_metadata

fn compare_metadata(before : InstrumentMetadata?, after : InstrumentMetadata?, id : String) -> RegistryChange

#
compare_reports

fn compare_reports(left : ScoreReport, right : ScoreReport) -> ReportComparison

#
compare_snapshots

fn compare_snapshots(left : ScoreSnapshot, right : ScoreSnapshot) -> SnapshotChange

#
curbs65_age_points

fn curbs65_age_points(value : Int) -> Int

#
curbs65_confusion_points

fn curbs65_confusion_points(value : Bool) -> Int

#
curbs65_pressure_points

fn curbs65_pressure_points(systolic : Int, diastolic : Int) -> Int

#
curbs65_respiratory_points

fn curbs65_respiratory_points(value : Int) -> Int

#
curbs65_severity

fn curbs65_severity(score : Int) -> Severity

#
curbs65_urea_points

fn curbs65_urea_points(value : Int) -> Int

#
default_registry

fn default_registry() -> InstrumentRegistry

#
empty_ledger

fn empty_ledger() -> AssessmentLedger

#
empty_registry

fn empty_registry(revision : String) -> InstrumentRegistry

#
empty_timeline

fn empty_timeline() -> Timeline

#
escalation_rank

fn escalation_rank(tier : EscalationTier) -> Int

#
escalation_tier_label

fn escalation_tier_label(tier : EscalationTier) -> String

#
evaluate_pathway

fn evaluate_pathway(rules : Array[PathwayRule], reports : Array[ScoreReport]) -> PathwayDecision

#
evaluate_threshold

fn evaluate_threshold(rule_name : String, value : Int, bands : Array[ThresholdBand]) -> RuleEvaluation

#
evaluation_labels

fn evaluation_labels(evaluations : Array[RuleEvaluation]) -> Array[String]

#
evidence_status_label

fn evidence_status_label(status : EvidenceStatus) -> String

#
explanation

fn explanation(label : String, points : Int, detail : String) -> Explanation

#
explanation_label

fn explanation_label(item : Explanation) -> String

#
explanation_labels

fn explanation_labels(items : Array[Explanation]) -> Array[String]

#
four_score_severity

fn four_score_severity(score : Int) -> Severity

#
four_score_total

fn four_score_total(input : FourScoreInput) -> Int

#
gbs_bool_points

fn gbs_bool_points(value : Bool, points : Int) -> Int

#
gbs_bun_points

fn gbs_bun_points(value : Int) -> Int

#
gbs_female_hemoglobin_points

fn gbs_female_hemoglobin_points(value : Int) -> Int

#
gbs_hemoglobin_points

fn gbs_hemoglobin_points(value : Int, female : Bool) -> Int

#
gbs_male_hemoglobin_points

fn gbs_male_hemoglobin_points(value : Int) -> Int

#
gbs_pressure_points

fn gbs_pressure_points(value : Int) -> Int

#
gbs_pulse_points

fn gbs_pulse_points(value : Int) -> Int

#
gbs_severity

fn gbs_severity(score : Int) -> Severity

#
gcs_severity

fn gcs_severity(total : Int) -> Severity

#
gcs_total

fn gcs_total(input : GcsInput) -> Int

#
has_bled_severity

fn has_bled_severity(score : Int) -> Severity

#
heart_severity

fn heart_severity(score : Int) -> Severity

#
hestia_positive_points

fn hestia_positive_points(value : Bool) -> Int

#
hestia_severity

fn hestia_severity(score : Int) -> Severity

#
highest_concern_report

fn highest_concern_report(reports : Array[ScoreReport]) -> ScoreReport?

#
injury_severity_band

fn injury_severity_band(score : Int) -> Severity

#
injury_severity_score

fn injury_severity_score(input : InjurySeverityInput) -> Int

#
instrument_category_label

fn instrument_category_label(category : InstrumentCategory) -> String

#
instrument_present

fn instrument_present(reports : Array[ScoreReport], name : String) -> Bool

#
ledger_add

fn ledger_add(ledger : AssessmentLedger, item : ScoreSnapshot) -> AssessmentLedger

#
ledger_count_instrument

fn ledger_count_instrument(ledger : AssessmentLedger, instrument : String) -> Int

#
ledger_highest_severity

fn ledger_highest_severity(ledger : AssessmentLedger) -> Severity

#
ledger_instruments

fn ledger_instruments(ledger : AssessmentLedger) -> Array[String]

#
ledger_latest

fn ledger_latest(ledger : AssessmentLedger) -> ScoreSnapshot?

#
ledger_latest_instrument

fn ledger_latest_instrument(ledger : AssessmentLedger, instrument : String) -> ScoreSnapshot?

#
ledger_scores

fn ledger_scores(ledger : AssessmentLedger) -> Array[Int]

#
ledger_size

fn ledger_size(ledger : AssessmentLedger) -> Int

#
ledger_total_score

fn ledger_total_score(ledger : AssessmentLedger) -> Int

#
matched_evaluations

fn matched_evaluations(evaluations : Array[RuleEvaluation]) -> Array[RuleEvaluation]

#
max_pathway_severity

fn max_pathway_severity(left : Severity, right : Severity) -> Severity

#
max_tier

fn max_tier(left : EscalationTier, right : EscalationTier) -> EscalationTier

#
meld_component_points

fn meld_component_points(value : Int, low : Int, middle : Int, high : Int) -> Int

#
meld_na_score

fn meld_na_score(input : MeldNaInput) -> Int

#
meld_na_severity

fn meld_na_severity(score : Int) -> Severity

#
metadata

fn metadata(id : String, display_name : String, category : InstrumentCategory, unit : String, minimum : Int, maximum : Int, source_url : String, version : String, caution : String, keywords : Array[String]) -> InstrumentMetadata

#
metadata_same

fn metadata_same(left : InstrumentMetadata, right : InstrumentMetadata) -> Bool

#
mews_consciousness_points

fn mews_consciousness_points(value : Consciousness) -> Int

#
mews_heart_rate_points

fn mews_heart_rate_points(value : Int) -> Int

#
mews_respiratory_rate_points

fn mews_respiratory_rate_points(value : Int) -> Int

#
mews_severity

fn mews_severity(score : Int) -> Severity

#
mews_systolic_bp_points

fn mews_systolic_bp_points(value : Int) -> Int

#
mews_temperature_points

fn mews_temperature_points(value : Int) -> Int

#
news2_consciousness_points

fn news2_consciousness_points(consciousness : Consciousness) -> Int

#
news2_heart_rate_points

fn news2_heart_rate_points(heart_rate : Int) -> Int

#
news2_oxygen_saturation_points

fn news2_oxygen_saturation_points(saturation : Int, scale : Spo2Scale, supplemental_oxygen : Bool) -> Int

#
news2_respiratory_rate_points

fn news2_respiratory_rate_points(rate : Int) -> Int

#
news2_severity

fn news2_severity(score : Int, any_single_three : Bool) -> Severity

#
news2_supplemental_oxygen_points

fn news2_supplemental_oxygen_points(supplemental_oxygen : Bool) -> Int

#
news2_systolic_bp_points

fn news2_systolic_bp_points(systolic_bp : Int) -> Int

#
news2_temperature_points

fn news2_temperature_points(temperature_tenths_c : Int) -> Int

#
nexus_clears_cspine

fn nexus_clears_cspine(input : NexusCspineInput) -> Bool

#
nexus_positive_count

fn nexus_positive_count(input : NexusCspineInput) -> Int

#
nihss_severity

fn nihss_severity(score : Int) -> Severity

#
nihss_total

fn nihss_total(input : NihssInput) -> Int

#
observation

fn observation(kind : ObservationKind, value : Int, unit : MeasurementUnit, timestamp_minutes : Int, source : String) -> Observation

#
observation_age_minutes

fn observation_age_minutes(now : Int, item : Observation) -> Int

#
observation_delta

fn observation_delta(older : Observation, newer : Observation) -> Int

#
observation_is_fresh

fn observation_is_fresh(now : Int, item : Observation, window_minutes : Int) -> Bool

#
observation_is_ordered

fn observation_is_ordered(left : Observation, right : Observation) -> Bool

#
observation_issue_label

fn observation_issue_label(issue : ObservationIssue) -> String

#
observation_kind_label

fn observation_kind_label(kind : ObservationKind) -> String

#
observation_unit_label

fn observation_unit_label(unit : MeasurementUnit) -> String

#
ottawa_ankle_criterion_count

fn ottawa_ankle_criterion_count(input : OttawaAnkleInput) -> Int

#
ottawa_ankle_positive

fn ottawa_ankle_positive(input : OttawaAnkleInput) -> Bool

#
padua_score

fn padua_score(input : PaduaInput) -> Int

#
padua_severity

fn padua_severity(score : Int) -> Severity

#
pathway_decision_explanation

fn pathway_decision_explanation(tier : EscalationTier, evidence : EvidenceStatus, severity : Severity, matched_count : Int) -> String

#
pathway_missing_instruments

fn pathway_missing_instruments(rule : PathwayRule, reports : Array[ScoreReport]) -> Array[String]

#
pathway_rule_labels

fn pathway_rule_labels(rules : Array[PathwayRule]) -> Array[String]

#
pathway_rule_matches

fn pathway_rule_matches(rule : PathwayRule, reports : Array[ScoreReport]) -> Bool

#
pecarn_high_risk_count

fn pecarn_high_risk_count(input : PecarnHeadInput) -> Int

#
pecarn_intermediate_count

fn pecarn_intermediate_count(input : PecarnHeadInput) -> Int

#
pediatric_appendicitis_anorexia_points

fn pediatric_appendicitis_anorexia_points(value : Bool) -> Int

#
pediatric_appendicitis_cough_points

fn pediatric_appendicitis_cough_points(value : Bool) -> Int

#
pediatric_appendicitis_fever_points

fn pediatric_appendicitis_fever_points(value : Int) -> Int

#
pediatric_appendicitis_lab_points

fn pediatric_appendicitis_lab_points(leukocytosis : Bool, neutrophilia : Bool) -> Int

#
pediatric_appendicitis_migration_points

fn pediatric_appendicitis_migration_points(value : Bool) -> Int

#
pediatric_appendicitis_nausea_points

fn pediatric_appendicitis_nausea_points(value : Bool) -> Int

#
pediatric_appendicitis_score

fn pediatric_appendicitis_score(input : PediatricAppendicitisInput) -> Int

#
pediatric_appendicitis_severity

fn pediatric_appendicitis_severity(score : Int) -> Severity

#
pediatric_appendicitis_tenderness_points

fn pediatric_appendicitis_tenderness_points(value : Bool) -> Int

#
perc_negative

fn perc_negative(input : PercInput) -> Bool

#
perc_positive_count

fn perc_positive_count(input : PercInput) -> Int

#
pesi_severity

fn pesi_severity(score : Int) -> Severity

#
pews_behavior_points

fn pews_behavior_points(value : PewsBehavior) -> Int

#
pews_cardiovascular_points

fn pews_cardiovascular_points(value : PewsCardiovascular) -> Int

#
pews_nebulizer_points

fn pews_nebulizer_points(value : Int) -> Int

#
pews_oxygen_points

fn pews_oxygen_points(value : PewsOxygenSupport) -> Int

#
pews_respiratory_points

fn pews_respiratory_points(value : PewsRespiratory) -> Int

#
pews_severity

fn pews_severity(score : Int) -> Severity

#
preeclampsia_liver_points

fn preeclampsia_liver_points(ast : Int, alt : Int, pain : Bool) -> Int

#
preeclampsia_neurologic_points

fn preeclampsia_neurologic_points(headache : Bool, visual : Bool) -> Int

#
preeclampsia_other_points

fn preeclampsia_other_points(edema : Bool, growth : Bool) -> Int

#
preeclampsia_platelet_points

fn preeclampsia_platelet_points(value : Int) -> Int

#
preeclampsia_pressure_points

fn preeclampsia_pressure_points(systolic : Int, diastolic : Int) -> Int

#
preeclampsia_renal_points

fn preeclampsia_renal_points(value : Int) -> Int

#
preeclampsia_score

fn preeclampsia_score(input : PreeclampsiaInput) -> Int

#
preeclampsia_severity

fn preeclampsia_severity(score : Int) -> Severity

#
qcsi_flow_points

fn qcsi_flow_points(value : Int) -> Int

#
qcsi_oxygen_points

fn qcsi_oxygen_points(value : Int) -> Int

#
qcsi_respiratory_points

fn qcsi_respiratory_points(value : Int) -> Int

#
qcsi_severity

fn qcsi_severity(score : Int) -> Severity

#
qsofa_mentation_points

fn qsofa_mentation_points(gcs_total : Int) -> Int

#
qsofa_respiratory_rate_points

fn qsofa_respiratory_rate_points(respiratory_rate : Int) -> Int

#
qsofa_severity

fn qsofa_severity(score : Int) -> Severity

#
qsofa_systolic_bp_points

fn qsofa_systolic_bp_points(systolic_bp : Int) -> Int

#
quality_flag

fn quality_flag(field : String, quality : MeasurementQuality, message : String) -> QualityFlag

#
quality_for_int

fn quality_for_int(field : String, value : Int, min : Int, max : Int) -> QualityFlag

#
quality_for_news2

fn quality_for_news2(input : News2Input) -> Array[QualityFlag]

#
quality_for_optional

fn quality_for_optional(field : String, value : Int?) -> QualityFlag

#
quality_is_usable

fn quality_is_usable(flag : QualityFlag) -> Bool

#
quality_label

fn quality_label(quality : MeasurementQuality) -> String

#
ranson_48_hour_score

fn ranson_48_hour_score(input : RansonInput) -> Int

#
ranson_admission_score

fn ranson_admission_score(input : RansonInput) -> Int

#
ranson_score

fn ranson_score(input : RansonInput) -> Int

#
ranson_severity

fn ranson_severity(score : Int) -> Severity

#
rcri_flag_points

fn rcri_flag_points(value : Bool) -> Int

#
rcri_severity

fn rcri_severity(score : Int) -> Severity

#
registry_add

fn registry_add(registry : InstrumentRegistry, entry : InstrumentMetadata) -> InstrumentRegistry

#
registry_added

fn registry_added(changes : Array[RegistryChange]) -> Array[RegistryChange]

#
registry_category_count

fn registry_category_count(registry : InstrumentRegistry, category : InstrumentCategory) -> Int

#
registry_category_counts

fn registry_category_counts(registry : InstrumentRegistry) -> Array[String]

#
registry_category_entries

fn registry_category_entries(registry : InstrumentRegistry, category : InstrumentCategory) -> Array[InstrumentMetadata]

#
registry_change_kind_label

fn registry_change_kind_label(kind : RegistryChangeKind) -> String

#
registry_changes

fn registry_changes(before : InstrumentRegistry, after : InstrumentRegistry) -> Array[RegistryChange]

#
registry_contains

fn registry_contains(registry : InstrumentRegistry, id : String) -> Bool

#
registry_display_labels

fn registry_display_labels(registry : InstrumentRegistry) -> Array[String]

#
registry_filter_valid

fn registry_filter_valid(registry : InstrumentRegistry) -> InstrumentRegistry

#
registry_find

fn registry_find(registry : InstrumentRegistry, id : String) -> InstrumentMetadata?

#
registry_has_duplicate_ids

fn registry_has_duplicate_ids(registry : InstrumentRegistry) -> Bool

#
registry_ids

fn registry_ids(registry : InstrumentRegistry) -> Array[String]

#
registry_is_release_ready

fn registry_is_release_ready(registry : InstrumentRegistry) -> Bool

fn registry_keyword_search(registry : InstrumentRegistry, keyword : String) -> Array[InstrumentMetadata]

#
registry_merge

fn registry_merge(primary : InstrumentRegistry, additions : InstrumentRegistry) -> InstrumentRegistry

#
registry_removed

fn registry_removed(changes : Array[RegistryChange]) -> Array[RegistryChange]

#
registry_revision_label

fn registry_revision_label(registry : InstrumentRegistry) -> String

#
registry_select

fn registry_select(registry : InstrumentRegistry, ids : Array[String]) -> InstrumentRegistry

#
registry_size

fn registry_size(registry : InstrumentRegistry) -> Int

#
registry_unchanged

fn registry_unchanged(changes : Array[RegistryChange]) -> Array[RegistryChange]

#
registry_updated

fn registry_updated(changes : Array[RegistryChange]) -> Array[RegistryChange]

#
registry_validate

fn registry_validate(registry : InstrumentRegistry) -> Bool

#
render_change

fn render_change(left : ScoreSnapshot, right : ScoreSnapshot) -> String

#
render_explanation

fn render_explanation(item : Explanation) -> String

#
render_explanations

fn render_explanations(items : Array[Explanation]) -> String

#
render_ledger

fn render_ledger(ledger : AssessmentLedger) -> String

#
render_metadata

fn render_metadata(entry : InstrumentMetadata) -> String

#
render_pathway_decision

fn render_pathway_decision(decision : PathwayDecision) -> String

#
render_registry

fn render_registry(registry : InstrumentRegistry) -> String

#
render_registry_change

fn render_registry_change(change : RegistryChange) -> String

#
render_registry_changes

fn render_registry_changes(changes : Array[RegistryChange]) -> String

#
render_report

fn render_report(report : ScoreReport) -> String

#
render_report_comparison

fn render_report_comparison(comparison : ReportComparison) -> String

#
render_report_quality

fn render_report_quality(quality : ReportQuality) -> String

#
render_snapshot

fn render_snapshot(item : ScoreSnapshot) -> String

#
render_trace_summary

fn render_trace_summary(summary : TraceSummary) -> String

#
report

fn report(instrument : String, score : Int, severity : Severity, interpretation : String, explanations : Array[Explanation]) -> ScoreReport

#
report_average_delta_x100

fn report_average_delta_x100(left : Array[ScoreReport], right : Array[ScoreReport]) -> Int

#
report_average_score_x100

fn report_average_score_x100(reports : Array[ScoreReport]) -> Int

#
report_bundle_is_coherent

fn report_bundle_is_coherent(reports : Array[ScoreReport]) -> Bool

#
report_catalog

fn report_catalog(reports : Array[ScoreReport]) -> String

#
report_catalog_line

fn report_catalog_line(report : ScoreReport) -> String

#
report_comparison_label

fn report_comparison_label(comparison : ReportComparison) -> String

#
report_count_at_or_above

fn report_count_at_or_above(reports : Array[ScoreReport], severity : Severity) -> Int

#
report_csv_header

fn report_csv_header() -> String

#
report_csv_row

fn report_csv_row(report : ScoreReport) -> String

#
report_delta_label

fn report_delta_label(delta : Int) -> String

#
report_disclaimer_set

fn report_disclaimer_set(reports : Array[ScoreReport]) -> Array[String]

#
report_explanation_count

fn report_explanation_count(reports : Array[ScoreReport]) -> Int

#
report_explanation_total

fn report_explanation_total(report : ScoreReport) -> Int

#
report_find

fn report_find(reports : Array[ScoreReport], instrument : String) -> ScoreReport?

#
report_has_explanation

fn report_has_explanation(report : ScoreReport, label : String) -> Bool

#
report_has_severity

fn report_has_severity(reports : Array[ScoreReport], severity : Severity) -> Bool

#
report_header

fn report_header(report : ScoreReport) -> String

#
report_instrument_names

fn report_instrument_names(reports : Array[ScoreReport]) -> Array[String]

#
report_interpretations

fn report_interpretations(reports : Array[ScoreReport]) -> Array[String]

#
report_is_empty

fn report_is_empty(report : ScoreReport) -> Bool

#
report_is_more_concerning

fn report_is_more_concerning(left : ScoreReport, right : ScoreReport) -> Bool

#
report_max_score

fn report_max_score(reports : Array[ScoreReport]) -> Int

#
report_min_score

fn report_min_score(reports : Array[ScoreReport]) -> Int?

#
report_nonempty

fn report_nonempty(reports : Array[ScoreReport]) -> Array[ScoreReport]

#
report_points_for_label

fn report_points_for_label(report : ScoreReport, label : String) -> Int?

#
report_quality

fn report_quality(reports : Array[ScoreReport]) -> ReportQuality

#
report_quality_ready

fn report_quality_ready(quality : ReportQuality) -> Bool

#
report_range

fn report_range(reports : Array[ScoreReport]) -> Int

#
report_score_reconciles

fn report_score_reconciles(report : ScoreReport) -> Bool

#
report_score_reconciles_with_explanations

fn report_score_reconciles_with_explanations(report : ScoreReport, explanations : Array[Explanation]) -> Bool

#
report_score_sum

fn report_score_sum(reports : Array[ScoreReport]) -> Int

#
report_severity_rank

fn report_severity_rank(report : ScoreReport) -> Int

#
report_severity_vector

fn report_severity_vector(reports : Array[ScoreReport]) -> Array[String]

#
report_summary_line

fn report_summary_line(reports : Array[ScoreReport]) -> String

#
report_value_vector

fn report_value_vector(reports : Array[ScoreReport]) -> Array[Int]

#
reports_at_or_above

fn reports_at_or_above(reports : Array[ScoreReport], severity : Severity) -> Array[ScoreReport]

#
reports_csv

fn reports_csv(reports : Array[ScoreReport]) -> String

#
reports_have_invalid_score

fn reports_have_invalid_score(reports : Array[ScoreReport]) -> Bool

#
reports_highest_severity

fn reports_highest_severity(reports : Array[ScoreReport]) -> Severity

#
reports_render_lines

fn reports_render_lines(reports : Array[ScoreReport]) -> Array[String]

#
reports_with_severity

fn reports_with_severity(reports : Array[ScoreReport], severity : Severity) -> Array[ScoreReport]

#
revised_trauma_score

fn revised_trauma_score(input : RevisedTraumaInput) -> Int

#
revised_trauma_severity

fn revised_trauma_severity(score : Int) -> Severity

#
rox_severity

fn rox_severity(index_x100 : Int) -> Severity

#
rox_x100

fn rox_x100(input : RoxInput) -> Int

#
score_abcd2

fn score_abcd2(input : Abcd2Input) -> ScoreReport

#
score_aki

fn score_aki(input : AkiInput) -> ScoreReport

#
score_alvarado

fn score_alvarado(input : AlvaradoInput) -> ScoreReport

#
score_apache_ii

fn score_apache_ii(input : ApacheIiInput) -> ScoreReport

#
score_ariscat

fn score_ariscat(input : AriscatInput) -> ScoreReport

#
score_bisap

fn score_bisap(input : BisapInput) -> ScoreReport

#
score_bishop

fn score_bishop(input : BishopInput) -> ScoreReport

#
score_bode

fn score_bode(input : BodeInput) -> ScoreReport

#
score_canadian_cspine

fn score_canadian_cspine(input : CanadianCspineInput) -> ScoreReport

#
score_canadian_ct_head

fn score_canadian_ct_head(input : CanadianCtHeadInput) -> ScoreReport

#
score_caprini

fn score_caprini(input : CapriniInput) -> ScoreReport

#
score_cha2ds2_vasc

fn score_cha2ds2_vasc(input : Cha2ds2VascInput) -> ScoreReport

#
score_charlson

fn score_charlson(input : CharlsonInput) -> ScoreReport

#
score_child_pugh

fn score_child_pugh(input : ChildPughInput) -> ScoreReport

#
score_curbs65

fn score_curbs65(input : Curbs65Input) -> ScoreReport

#
score_four

fn score_four(input : FourScoreInput) -> ScoreReport

#
score_gcs

fn score_gcs(input : GcsInput) -> GcsReport

#
score_gcs_as_report

fn score_gcs_as_report(input : GcsInput) -> ScoreReport

#
score_glasgow_blatchford

fn score_glasgow_blatchford(input : GlasgowBlatchfordInput) -> ScoreReport

#
score_has_bled

fn score_has_bled(input : HasBledInput) -> ScoreReport

#
score_heart

fn score_heart(input : HeartInput) -> ScoreReport

#
score_hestia

fn score_hestia(input : HestiaInput) -> ScoreReport

#
score_injury_severity

fn score_injury_severity(input : InjurySeverityInput) -> ScoreReport

#
score_meld_na

fn score_meld_na(input : MeldNaInput) -> ScoreReport

#
score_mews

fn score_mews(input : MewsInput) -> ScoreReport

#
score_news2

fn score_news2(input : News2Input) -> ScoreReport

#
score_nexus_cspine

fn score_nexus_cspine(input : NexusCspineInput) -> ScoreReport

#
score_nihss

fn score_nihss(input : NihssInput) -> ScoreReport

#
score_ottawa_ankle

fn score_ottawa_ankle(input : OttawaAnkleInput) -> ScoreReport

#
score_padua

fn score_padua(input : PaduaInput) -> ScoreReport

#
score_pecarn_head

fn score_pecarn_head(input : PecarnHeadInput) -> ScoreReport

#
score_pediatric_appendicitis

fn score_pediatric_appendicitis(input : PediatricAppendicitisInput) -> ScoreReport

#
score_perc

fn score_perc(input : PercInput) -> ScoreReport

#
score_pesi

fn score_pesi(input : PesiInput) -> ScoreReport

#
score_pews

fn score_pews(input : PewsInput) -> ScoreReport

#
score_preeclampsia

fn score_preeclampsia(input : PreeclampsiaInput) -> ScoreReport

#
score_qcsi

fn score_qcsi(input : QcsiInput) -> ScoreReport

#
score_qsofa

fn score_qsofa(input : QsofaInput) -> ScoreReport

#
score_ranson

fn score_ranson(input : RansonInput) -> ScoreReport

#
score_rcri

fn score_rcri(input : RcriInput) -> ScoreReport

#
score_revised_trauma

fn score_revised_trauma(input : RevisedTraumaInput) -> ScoreReport

#
score_rox

fn score_rox(input : RoxInput) -> ScoreReport

#
score_shock_index

fn score_shock_index(input : ShockIndexInput) -> ScoreReport

#
score_sirs

fn score_sirs(input : SirsInput) -> ScoreReport

#
score_smart_cop

fn score_smart_cop(input : SmartCopInput) -> ScoreReport

#
score_sofa

fn score_sofa(input : SofaInput) -> ScoreReport

#
score_stop_bang

fn score_stop_bang(input : StopBangInput) -> ScoreReport

#
score_timi

fn score_timi(input : TimiInput) -> ScoreReport

#
score_triage

fn score_triage(input : TriageInput) -> TriageBundle

#
score_wells_dvt

fn score_wells_dvt(input : WellsDvtInput) -> ScoreReport

#
score_wells_pe

fn score_wells_pe(input : WellsPeInput) -> ScoreReport

#
severity_label

fn severity_label(severity : Severity) -> String

#
severity_rank

fn severity_rank(severity : Severity) -> Int

#
shock_index_severity

fn shock_index_severity(index_x100 : Int) -> Severity

#
shock_index_x100

fn shock_index_x100(input : ShockIndexInput) -> Int

#
sirs_heart_rate_points

fn sirs_heart_rate_points(value : Int) -> Int

#
sirs_respiratory_rate_points

fn sirs_respiratory_rate_points(value : Int) -> Int

#
sirs_severity

fn sirs_severity(score : Int) -> Severity

#
sirs_temperature_points

fn sirs_temperature_points(value : Int) -> Int

#
sirs_white_cell_points

fn sirs_white_cell_points(value : Int, immature_percent : Int) -> Int

#
smart_cop_age_points

fn smart_cop_age_points(value : Int) -> Int

#
smart_cop_albumin_points

fn smart_cop_albumin_points(value : Int) -> Int

#
smart_cop_confusion_points

fn smart_cop_confusion_points(value : Bool) -> Int

#
smart_cop_infiltrate_points

fn smart_cop_infiltrate_points(value : Bool) -> Int

#
smart_cop_oxygen_points

fn smart_cop_oxygen_points(value : Int) -> Int

#
smart_cop_ph_points

fn smart_cop_ph_points(value : Int) -> Int

#
smart_cop_pressure_points

fn smart_cop_pressure_points(value : Int) -> Int

#
smart_cop_respiration_points

fn smart_cop_respiration_points(value : Int, age : Int) -> Int

#
smart_cop_score

fn smart_cop_score(input : SmartCopInput) -> Int

#
smart_cop_severity

fn smart_cop_severity(score : Int) -> Severity

#
snapshot

fn snapshot(instrument : String, score : Int, severity : Severity, timestamp_minutes : Int, source : String) -> ScoreSnapshot

#
snapshot_age_minutes

fn snapshot_age_minutes(now : Int, item : ScoreSnapshot) -> Int

#
snapshot_change_amount

fn snapshot_change_amount(change : SnapshotChange) -> Int

#
snapshot_change_label

fn snapshot_change_label(change : SnapshotChange) -> String

#
snapshot_from_report

fn snapshot_from_report(report : ScoreReport, timestamp_minutes : Int, source : String) -> ScoreSnapshot

#
snapshot_is_fresh

fn snapshot_is_fresh(now : Int, item : ScoreSnapshot, window_minutes : Int) -> Bool

#
sofa_bilirubin_points

fn sofa_bilirubin_points(value : Int) -> Int

#
sofa_circulation_points

fn sofa_circulation_points(map : Int, pressor : VasopressorLevel) -> Int

#
sofa_gcs_points

fn sofa_gcs_points(value : Int) -> Int

#
sofa_platelet_points

fn sofa_platelet_points(value : Int) -> Int

#
sofa_renal_points

fn sofa_renal_points(creatinine : Int, urine : Int) -> Int

#
sofa_respiratory_points

fn sofa_respiratory_points(ratio : Int, support : Bool) -> Int

#
sofa_severity

fn sofa_severity(score : Int) -> Severity

#
sort_audit_events

fn sort_audit_events(events : Array[AuditEvent]) -> Array[AuditEvent]

#
stop_bang_score

fn stop_bang_score(input : StopBangInput) -> Int

#
stop_bang_severity

fn stop_bang_severity(score : Int) -> Severity

#
sum_evaluations

fn sum_evaluations(evaluations : Array[RuleEvaluation]) -> Int

#
summarize_quality

fn summarize_quality(flags : Array[QualityFlag]) -> QualitySummary

#
summarize_reports

fn summarize_reports(reports : Array[ScoreReport]) -> ReportSummary

#
threshold_band

fn threshold_band(label : String, minimum : Int, maximum : Int, points : Int, explanation : String) -> ThresholdBand

#
threshold_contains

fn threshold_contains(band : ThresholdBand, value : Int) -> Bool

#
threshold_find

fn threshold_find(bands : Array[ThresholdBand], value : Int) -> ThresholdBand?

#
threshold_labels

fn threshold_labels(bands : Array[ThresholdBand]) -> Array[String]

#
threshold_points

fn threshold_points(bands : Array[ThresholdBand], value : Int) -> Int?

#
timeline_add

fn timeline_add(timeline : Timeline, item : Observation) -> Timeline

#
timeline_count_of

fn timeline_count_of(timeline : Timeline, kind : ObservationKind) -> Int

#
timeline_latest

fn timeline_latest(timeline : Timeline) -> Observation?

#
timeline_latest_of

fn timeline_latest_of(timeline : Timeline, kind : ObservationKind) -> Observation?

#
timeline_length

fn timeline_length(timeline : Timeline) -> Int

#
timeline_summary

fn timeline_summary(timeline : Timeline) -> TimelineSummary

#
timeline_valid

fn timeline_valid(timeline : Timeline) -> Bool

#
timi_risk_factor_points

fn timi_risk_factor_points(value : Int) -> Int

#
timi_severity

fn timi_severity(score : Int) -> Severity

#
trace_summary

fn trace_summary(events : Array[AuditEvent]) -> TraceSummary

#
trauma_gcs_points

fn trauma_gcs_points(value : Int) -> Int

#
trauma_pressure_points

fn trauma_pressure_points(value : Int) -> Int

#
trauma_respiration_points

fn trauma_respiration_points(value : Int) -> Int

#
trend_direction

fn trend_direction(trend : Trend) -> String

#
trend_for

fn trend_for(timeline : Timeline, kind : ObservationKind) -> Trend?

#
triage_disclaimer

fn triage_disclaimer() -> String

#
validate_abcd2

fn validate_abcd2(input : Abcd2Input) -> ValidationError?

#
validate_aki

fn validate_aki(input : AkiInput) -> ValidationError?

#
validate_alvarado

fn validate_alvarado(input : AlvaradoInput) -> ValidationError?

#
validate_apache_ii

fn validate_apache_ii(input : ApacheIiInput) -> ValidationError?

#
validate_ariscat

fn validate_ariscat(input : AriscatInput) -> ValidationError?

#
validate_audit_event

fn validate_audit_event(event : AuditEvent) -> ValidationError?

#
validate_bisap

fn validate_bisap(input : BisapInput) -> ValidationError?

#
validate_bishop

fn validate_bishop(input : BishopInput) -> ValidationError?

#
validate_bode

fn validate_bode(input : BodeInput) -> ValidationError?

#
validate_bool_scale

fn validate_bool_scale(field : String, value : Int) -> ValidationError?

#
validate_canadian_cspine

fn validate_canadian_cspine(input : CanadianCspineInput) -> ValidationError?

#
validate_canadian_ct_head

fn validate_canadian_ct_head(input : CanadianCtHeadInput) -> ValidationError?

#
validate_caprini

fn validate_caprini(input : CapriniInput) -> ValidationError?

#
validate_cha2ds2_vasc

fn validate_cha2ds2_vasc(input : Cha2ds2VascInput) -> ValidationError?

#
validate_charlson

fn validate_charlson(input : CharlsonInput) -> ValidationError?

#
validate_child_pugh

fn validate_child_pugh(input : ChildPughInput) -> ValidationError?

#
validate_curbs65

fn validate_curbs65(input : Curbs65Input) -> ValidationError?

#
validate_four_score

fn validate_four_score(input : FourScoreInput) -> ValidationError?

#
validate_gcs

fn validate_gcs(input : GcsInput) -> ValidationError?

#
validate_glasgow_blatchford

fn validate_glasgow_blatchford(input : GlasgowBlatchfordInput) -> ValidationError?

#
validate_heart

fn validate_heart(input : HeartInput) -> ValidationError?

#
validate_injury_severity

fn validate_injury_severity(input : InjurySeverityInput) -> ValidationError?

#
validate_meld_na

fn validate_meld_na(input : MeldNaInput) -> ValidationError?

#
validate_metadata

fn validate_metadata(entry : InstrumentMetadata) -> Bool

#
validate_mews

fn validate_mews(input : MewsInput) -> ValidationError?

#
validate_news2

fn validate_news2(input : News2Input) -> ValidationError?

#
validate_nihss

fn validate_nihss(input : NihssInput) -> ValidationError?

#
validate_observation

fn validate_observation(item : Observation) -> ObservationIssue?

#
validate_padua

fn validate_padua(input : PaduaInput) -> ValidationError?

#
validate_pecarn_head

fn validate_pecarn_head(input : PecarnHeadInput) -> ValidationError?

#
validate_pediatric_appendicitis

fn validate_pediatric_appendicitis(input : PediatricAppendicitisInput) -> ValidationError?

#
validate_perc

fn validate_perc(input : PercInput) -> ValidationError?

#
validate_pesi

fn validate_pesi(input : PesiInput) -> ValidationError?

#
validate_pews

fn validate_pews(input : PewsInput) -> ValidationError?

#
validate_preeclampsia

fn validate_preeclampsia(input : PreeclampsiaInput) -> ValidationError?

#
validate_qcsi

fn validate_qcsi(input : QcsiInput) -> ValidationError?

#
validate_qsofa

fn validate_qsofa(input : QsofaInput) -> ValidationError?

#
validate_range

fn validate_range(field : String, value : Int, min : Int, max : Int) -> ValidationError?

#
validate_ranson

fn validate_ranson(input : RansonInput) -> ValidationError?

#
validate_revised_trauma

fn validate_revised_trauma(input : RevisedTraumaInput) -> ValidationError?

#
validate_rox

fn validate_rox(input : RoxInput) -> ValidationError?

#
validate_shock_index

fn validate_shock_index(input : ShockIndexInput) -> ValidationError?

#
validate_sirs

fn validate_sirs(input : SirsInput) -> ValidationError?

#
validate_smart_cop

fn validate_smart_cop(input : SmartCopInput) -> ValidationError?

#
validate_sofa

fn validate_sofa(input : SofaInput) -> ValidationError?

#
validate_timi

fn validate_timi(input : TimiInput) -> ValidationError?

#
validate_triage

fn validate_triage(input : TriageInput) -> ValidationError?

#
validate_wells_pe

fn validate_wells_pe(input : WellsPeInput) -> ValidationError?

#
validation_error_field

fn validation_error_field(err : ValidationError) -> String

#
validation_error_message

fn validation_error_message(err : ValidationError) -> String

#
wells_dvt_severity

fn wells_dvt_severity(score : Int) -> Severity

#
wells_pe_dvt_points

fn wells_pe_dvt_points(value : Bool) -> Int

#
wells_pe_hemoptysis_points

fn wells_pe_hemoptysis_points(value : Bool) -> Int

#
wells_pe_immobilization_points

fn wells_pe_immobilization_points(value : Bool) -> Int

#
wells_pe_likely_points

fn wells_pe_likely_points(value : Bool) -> Int

#
wells_pe_malignancy_points

fn wells_pe_malignancy_points(value : Bool) -> Int

#
wells_pe_previous_event_points

fn wells_pe_previous_event_points(value : Bool) -> Int

#
wells_pe_rate_points

fn wells_pe_rate_points(value : Int) -> Int

#
wells_pe_severity

fn wells_pe_severity(score : Int) -> Severity