Clinical Intelligence StandardsVersion 0.2

Functional standard / Definition kinds / Constrains No resource. It configures the harness.

reaction

When a resource enters a state, and an optional expression matches, run effects.

Runtime

Clinical effects become proposals whose origin is reaction:<key>. Other effects are applied by the system actor. Chains stop at max_reaction_depth, default 4.

Elements

NameCard.TypeDescription
defaults0..1objectFields copied onto a new instance. Values given at creation win.
approval_required_for0..*codeExtra states that need an Approval to enter.
when_kind1..1codeResource kind.
when_state1..1codeState just entered. Creation counts as entering the initial state.
condition0..1expressionsafe_eval over the record's own fields.
effects1..*Effectop create or transition, kind, data, target_id, to, rationale. $field reads the source.

Example

{ "when_kind": "assessment", "when_state": "finalized", "condition": "safety_flag == True", "effects": [{ "op": "create", "kind": "task", "data": { "title": "Safety review", "priority": "urgent" } }] }