-
Notifications
You must be signed in to change notification settings - Fork 1
Pathways on FHIR Mapping
This is an evolving wiki page for mapping the internal data model for pathways into CPG. This page builds off Pathways on FHIR and Pathways on FHIR Resources.
Powerpoint deck of mapping is available for download here.
Each pathway in the builder will map to a Recommendation Definition. Although the builder supports joining branches again, the CPG exporter will not. Anywhere two branches of the pathway rejoin the CPG representation will have the entire sub-tree copied. Each Action Node will map to only one Activity Definition but the RecommendationDefinition.action
may have duplicate entries for the same Action Node. In general the RecommendationDefinition.action
s will be all of the Action Nodes as well as any Branch Nodes whose parent is also a Branch Node.
Mapping the pathway metadata to a Recommendation is very straight forward.
Unlike the pathway data model which has a discrete node for both action and branch, the Recommendation Definition only defines a list of actions. Each Action Node will map to its own RecommendationDefinition.action
. The Branch Nodes do not become their own action unless their parent is also a branch (nested branch node). Branch Nodes are represented in the Recommendation Definition as the action.condition
property of the child transition.
The general mapping of RecommendationDefinition.action
is:
{
id: string, // automatically assigned
title: node.label,
description: ("Action for " | "Branch based on ") + node.label,
definitionCanonical?: canonical(ActivityDefinition),
condition?: [{
kind: "applicability",
expression: {
language: "text/cql",
expression: parent.transition.condition
}
}],
relatedAction?: [
{
actionId: string // parent action id,
relationship: "after-end"
},
{
actionId: string // child action id,
relationship: "before-start"
}
],
action?: [ {Action} ] // child actions
}
where:
-
definitionCanonical
is defined for action nodes, otherwise undefined -
condition
is defined when the parent node is a branch, otherwise undefined -
action
is defined for nested branch nodes, otherwise undefined -
relatedAction
defines all of the parent and child transitions for Action Nodes only
Even if a single Action Node has multiple RecommendationDefinition.action
s they will have the same definitionCanonical
to a single ActivityDefinition. The mapping is trivial: