5. Common and archetyping
Requirement prefix: M5.
Where these invariants come from#
As in §3 and §6: read from the Release 1.0.2 publication (Common Information Model, Rev 2.1.1, 20 Dec 2008, §3.2, §4.3, §6.5), because the rendered RM page omits its class-definition tables.
LOCATABLE#
- M5.1 Every clinical node MUST carry the
LOCATABLEattributes:name,archetype_node_id, and optionallyuid,links,archetype_details, andfeeder_audit. - M5.2
archetype_node_idMUST be non-empty. A node without one cannot be reached by any path, which makes it invisible to AQL and to templates alike. - M5.3
nameMUST be able to be aDV_CODED_TEXTas well as aDV_TEXT, because openEHR types itDV_TEXTand permits the subtype at runtime. - M5.4 Reading a
namethat carries adefining_codeMUST NOT discard the code. Where_typeis absent, the presence ofdefining_codeMUST decide. - M5.5
is_archetype_rootMUST be exactly "archetype_detailsis present", andconceptMUST answer only at a root. Offering an internal node's name as a concept would misreport where the archetype boundaries are.
ARCHETYPED#
- M5.6
ARCHETYPEDMUST carry a parsedARCHETYPE_ID, an optionalTEMPLATE_ID, and a non-emptyrm_version. - M5.7 Validation MUST report an
ARCHETYPEDwhose archetype id constrains a different RM class than the node it annotates — anOBSERVATIONarchetype id on anEVALUATION. It is the commonest structural error in hand-built and transform-produced instances, nothing downstream detects it, and the data looks fine. - M5.8
rm_versionMUST be carried and MUST NOT be enforced (S1.16).
LINK and FEEDER_AUDIT#
- M5.9
LINK.targetMUST be aDV_EHR_URI(D3.31). - M5.10
FEEDER_AUDIT.original_contentMUST accept only aDV_ENCAPSULATEDdescendant. Accepting aDV_TEXTwould invite a lossy stringification of the one thing that exists to be lossless. - M5.11
FEEDER_AUDIT_DETAILS.system_idMUST be non-empty: recording that data came from somewhere without saying where is the one fact it exists to carry.
Parties#
- M5.12
PARTY_PROXYMUST admitPARTY_SELF,PARTY_IDENTIFIED, andPARTY_RELATED, and MUST infer the class where_typeis absent by looking forrelationship, thenname/identifiers, then defaulting toPARTY_SELF. - M5.13 Reading a
PARTY_RELATEDas aPARTY_IDENTIFIEDMUST NOT be possible: the relationship is the attribute that says whom the data is about. - M5.13a
PARTY_RELATED.relationshipMUST come from the openEHRsubject_relationshipgroup (Relationship_valid). The primary constructor takes a code, so the rule holds by construction; a relationship coded against another terminology is readable and is checked by validation instead. This is the attribute that says whom an entry is about, so an unrecognised code means a finding may be attributed to the wrong person. - M5.14
PARTY_IDENTIFIEDMUST require at least one ofname,identifiers, orexternal_ref. A party with none of them identifies nobody. - M5.15 "Is this the record subject?" MUST answer true for
PARTY_SELFand for aPARTY_RELATEDwhose relationship is0|self|. Both spellings occur, and code that checks only the first treats a self-related entry as being about somebody else. - M5.16
PARTY_SELFwith noexternal_refMUST be representable. It is how openEHR supports an anonymous record, and it is the representation a research extract needs — not a degenerate case to normalise away.
Participation#
- M5.17
PARTICIPATIONMUST carryfunction,performer, and optionallymodeand a time interval. - M5.18
PARTICIPATION.functionMUST be aDV_TEXTrather than a coded type, because openEHR types it that way: the useful vocabulary lives in external terminologies, and the openEHR group defines exactly one code. - M5.18a Where
functionormodeis coded from openEHR's own terminology, it MUST be in theparticipation_functionorparticipation_modegroup respectively (Function_valid,Mode_valid). The check MUST NOT apply to a code from another terminology: rejecting a SNOMED-coded participation function would reject the commonest real case.