DigitalTWINs on FHIR β
Digital Twins on FHIR (DToF) is a conceptual FHIR based framework to standardise key concepts, tools and data within the context of a workflow. In this sense a workflow comprises one or more steps where certain (software) tools take relevant data (e.g. from EHR) and feed into computational models (of human physiology & anatomy) to generate derived data which may be used to predict disease progression or treatment effects. We are using FHIR to make the data and models FAIR (findable, accessible, interoperable, and reusable).
DigitalTWINs on FHIR enables users to store patients' hospital EHR data and research data (such as clinical descriptions, mathematical models, and medical images). The foundational concept of DigitalTWINs on FHIR version 1 is the use of FHIR R4 resources to build the DigitalTWINs FHIR Specification. This specification is divided into four parts: Primary Measurements, Workflow, Workflow Tools, and Workflow Tool Process.
- Primary Measurements: Raw EHR data from hospitals or research institutes.
- Workflow: Defines the steps, actions, inputs, and outputs of a research study.
- Workflow Tools: Tools used in each step or action of the workflow.
- Workflow Tool Process: Generated by executing a tool or step within a workflow.
The core idea behind DigitalTWINs on FHIR is to develop a digital twin system for patients, clinicians, and researchers.
- Patients can view historical medical reports and predictions of disease progression.
- Clinicians can access patient history report data and review predicted clinical reports generated by researchersβ workflows.
- Researchers can create patient cohorts and use their raw EHR data as input for their studies.
Version 1 β
FHIR version: R4
Search β
- Finding all primary measurements for a patient.
- Find which workflow, tool, and primary data was used to generate a specific derived measurement observation.
- Find all tools and models used by a workflow and their workflow tool processes.
- Find inputs and outputs of a given tool in a workflow.
Tutorials β
Development β
- Packages
- App
- GitHub
- Preview App
Discussion β
- Version control of
Task
(Workflow tool process)- If a researcher run a same workflow tool for a same patient's measurements, it is hard to find their relationship
- Scenario 1 ( run different workflow tool): Researcher A run breast workflow tool A for patient A with measurements A. Then run breast workflow tool B for patient A with measurements B.
- This situation is very simple, we can search the
workflow tool process
bypatient's id, dataset'id, researcher'id, workflow'id and workflow tool's id
, and then usemeasurements A
andmeasurements B
or theirtitle
to distinguish theworkflow tool process A
andworkflow tool process B
. Because the measurements should be as a reference in workflow tool process input.
- This situation is very simple, we can search the
- Scenario 2 (run same workflow tool for same patient' measurements): Researcher A run breast workflow tool A for patient A with measurements A twice.
- This situation is a little bit tricky, but we still can solve it by execution time. The basic solution is same to above, but this time we will receive two almost same
workflow tool process
with sametitle, input measurements referece, dataset's reference researcher reference, patient reference, workflow reference, workflow tool reference
. The differences between them areuuid, output observation reference, execution time
. So, once we find these twoworkflow tool process
viaforward way
(dataset -> patient -> workflow -> workflow tool -> workflow tool process), we cannot distinguish them bytitle or measurements
, but needtitle or measurements
to get them first and then we can distinguish them by theirexecution time
.
- This situation is a little bit tricky, but we still can solve it by execution time. The basic solution is same to above, but this time we will receive two almost same
- Scenario 3 (run same workflow tool for same patient): Researcher A run breast workflow tool A for patient A without measurements A twice.
- This situation is tricky, because some workflow tool don't have EHR data as their input. So we cannot use
measurements
now, and when we searchworkflow tool process
viaforward way
we will get all workflow tools' processes. At this stage we also can usetitle
to get these twoworkflow tool process
and then distinguish them by their execution time.
- This situation is tricky, because some workflow tool don't have EHR data as their input. So we cannot use
- Conclusion: As for the
Task (workflow tool process)
, we can use their execution time for the version control.
- Scenario 1 ( run different workflow tool): Researcher A run breast workflow tool A for patient A with measurements A. Then run breast workflow tool B for patient A with measurements B.
- If a researcher run a same workflow tool for a same patient's measurements, it is hard to find their relationship
- Image format
- Currently, we are using
ImagingStudy
to store one patient'sDicom MRI
data. But in some tools (e.g,tumour position and extent report App
) they need other image format, such asNRRD
. Therefore, when we want to annotate one patient's image viatumour position and extent report App
, we cannot sent the MRIs' endpoint directly to the target App, but we need to do below steps:- Send the patient
ImageStudy's endpoint uuid
to backend, and get theDicom
images - Convert the
Dicom MRIs
toNRRD
format - Send the images to
tumour position and extent report App
- Send the patient
- Time consuming
- Request the images from PACs
- Convert
Dicom
toNRRD
- Send
NRRD
to the target tool
- Currently, we are using
- Patient cohorts
- Missing patients research cohorts
Version 2 β
FHIR version: R5
Search β
- Finding all primary measurements for a patient. - No
- Find which workflow, tool, and primary data was used to generate a specific derived measurement observation. - Conditional Yes, (only if the workflow tool process has input/output EHR data.)
- Find all tools and models used by a workflow and their workflow tool processes. - Yes
- Find inputs and outputs of a given tool in a workflow. - No (there is no links between workflow tool process and workflow.)
Discussion β
- What exactly information that we want to store for
workflow, workflow tool and workflow tool process
? - We are using
PlanDefinition
to store theworkflow
information, thePlanDefinition
has already fields to storeworkflow title, description, actions/steps, action's input/output
, what information we want to store inActivityDefinition
? - The
DeviceDefinition
we are used to store theworkflow tool
information, so theDevice
is theworkflow tool process
? We can save theexecution time
in manufactureDate , but here is a issue, consider this scenario if two differentworkflow
use the sameworkflow tool
and they run the same patient's measurements and same dataset, how can we distinguishworkflow tool processes
belong to whichworkflow
by searchworkflow tool process
directly? - Under this architecture, we cannot find the relationship between
workflow tool process
andpatient
- Patient can be in different
ResearchStudy
- The patient
primary measurements
may be used in same workflow actions (workflow tools) as input data - Some
workflow tool
may not have EHR input/output data, so theirworkflow tool process
don't have reference to result observation and primary observation.
- Patient can be in different
- Under this architecture, we cannot find the relationship between
workflow tool process
andResearchStudy
- This diagram is using
ResearchStudy
level to connect workflow not inPatient
level- We cannot find a
patient's
workflow tool process precisely, because its underResearchStudy
level, we only search like this:- From
ResearchStudy
- Find the
PlanDefinition
viaprotocol
- Find all the patients belong to this
ResearchStudy
- Find
workflow tools
belong to thisPlanDefinition (workflow)
- Then choose one
DeviceDefinition (workflow tool)
find allDevices (workflow tool processes)
, Notice: all Devices here means the Device may generate from otherResearchStudy (dataset)
andPlanDefinition (workflow)
, because there is no constraints/reference amongDevice (workflow tool process), ResearchStudy (dataset), PlanDefinition (workflow)
.- We may find some relationship between
Device (workflow tool process)'s reslut Observations
andPrimary Measurements
, But we cannot guarantee allDevice
has EHR input/output data.
- We may find some relationship between
- Find the
- From
PlanDefinition
- We can find a
PlanDefintion (workflow)'s ResearchStudy
by searchprotocol
inResearchStudy
- Then we will meet the same issue.
- We can find a
- From
- We cannot find a
- This diagram is using