Stream: implementers
Topic: Analytics and ML
Severin Skillman (Jul 29 2019 at 15:04):
Hello - I am looking for some advice on data modelling for analytics and ML purposes.
I've been trying to map ML/analytical concepts to FHIR resources. My current idea is to model algorithms as Devices as I believe one could consider them to be "Virtual Medical Devices" in that they take observational information as input and produce some other, higher-level observational output. These algorithms could contain parameters for within the Device and be defined using the DeviceDefinition resource. A trained ML model could persisted as a Binary resource and loaded when utilised. Some kind of event/notification implementation could then leverage the Subscription resource to notify when Observation data produced by the algorithms matches a given criteria (e.g. exceeds a threshold).
Below the concept mappings:
Data (both as input and output) == Observation (or more generally, diagnostic resources)
Model == Binary (+ DocumentReference?)
Algorithm and its parameters == Device
Algo Definition == DeviceDefiniton
Notification definition == Subscription
Notification == Flag
Would this approach make sense? Any others out there tackling this with FHIR?
Jose Costa Teixeira (Jul 29 2019 at 17:10):
Did you look at http://build.fhir.org/measure ?
Jose Costa Teixeira (Jul 29 2019 at 17:28):
Device should be good for software algorithms / argorithm implementations. Not sure what is an algorithm definition, and I am curious to see how to manage Machine Learning but that is just my curiosity
Grahame Grieve (Jul 29 2019 at 19:21):
@Bryn Rhodes - did you guys end up using OperationDefinition for this?
Bryn Rhodes (Jul 29 2019 at 19:30):
We started there, but wanted a standardized interface, so in STU3 it would have been a ServiceDefinition, in R4, an OperationDefinition would be good because it would allow you to specify the parameters directly.
Bryn Rhodes (Jul 29 2019 at 19:34):
If you have reasonably well-defined classes of models that all take the same types of parameters, then Measure is another potential fit, where a Library would be used to communicate the model and algorithms.
Severin Skillman (Jul 30 2019 at 11:19):
It's the first time I'm looking into Measure and Library resources. Am I understanding correctly that a Measure is a way to track, for example, the sensitivity/specificity of an algorithm wheres a Library persists algorithm models and/or other assets?
Severin Skillman (Jul 30 2019 at 11:21):
Is the idea with OperationDefinition to define parameters for invoking an algorithm in a Library?
Grahame Grieve (Jul 30 2019 at 11:33):
pretty much
Severin Skillman (Jul 30 2019 at 13:44):
What kind of operations are we talking about - something like $train, $predict?
Severin Skillman (Jul 30 2019 at 13:44):
against a Device? and is there a way to refer between Device and Library?
Bryn Rhodes (Jul 30 2019 at 16:52):
There is a cqf-Library extension that lets you reference a Library from any resource, that could be used to attach a library reference to a Device, yes.
Severin Skillman (Jul 31 2019 at 10:18):
Ok thank you. I will take a look
Dwight Walker (Aug 10 2019 at 13:50):
To do ML, you need to define what you are looking for in data, e.g. a symptom reading field value range for a diagnosis, then train the model based on known data using an algorithm to find the relevant data then use that model to predict the correct diagnosis for unseen data.
Javier Espina (Dec 03 2020 at 17:23):
Very interesting discussion. I have a similar (a bit simpler) project at hand with a similar model. For modelling the algorithm, I was planning to use Device. However OperationDefinition has a much better-fitting structure to describe all the algorithm inputs and outputs, version, publisher, etc. What I am struggling with is that OperationDefinition is already normative and does not describe that kind of usage. Especially if we're talking about algorithms that won't be invoked as "...a FHIR operation or a named query." (quoting https://www.hl7.org/fhir/operationdefinition.html#scope). Any suggestions?
Lloyd McKenzie (Dec 03 2020 at 19:41):
Broadening the scope is certainly something that's possible - you could submit a change request
Last updated: Apr 12 2022 at 19:14 UTC