Blog

FaaS-ification in Health Care

Why and how?

Personalized healthcare requires decision support systems that can help healthcare professionals to manage large volumes of patients. Care for chronic conditions requires doing so for patients at their everyday setting, outside the clinical environment. These needs can only be addressed with AI systems, at the core of which models trained by ML can be found. Such systems are deployed to offer diverse services, such as model inference for patient outcomes’ prediction, patient clustering into phenotypes and dataset augmentation with synthetic arms.

The traditional deployments of such systems in healthcare suffer from scaling. Deployment is a lengthy procedure, certainly aided by modern CI/CD pipelines, but the resulting systems are quite static in terms of resources, while occupying them even during quiet times.

PHYSICS facilitates the design and deployment of these services. It provides a design environment to implement and deploy the services. The starting point is an AI function implemented in Python at the core, which constitutes a node in complete Node-RED flows built around it using more (Javascript) functions and PHYSICS patterns to handle input and output.

Node-RED offers developers the means to locally test the flow, using additional nodes for user input, and invocation. Local testing is handy during the implementation phase.

Still using the design environment, locally tested flows are then deployed as functions to expose the health care services. PHYSICS annotation nodes control the deployment options at the flow level.

Thus, the flows employed for defining testing and deploying healthcare services are usually split in three sections. The endpoints definition section defines two POST endpoints, the /run with the service core, and the /init for any initialization. The manual invocation section facilitates local testing by sending a request to the /run endpoint. Finally, the annotations section controls the deployment options. The sections are shown in the flow depicted below:

The healthcare services being implemented in the PHYSICS FaaS way are:

  • Predictive model inference: Load feature vectors and a predictive model into an inference engine to get inference results.
  • Patient phenotyping: Load feature vectors and a set of generative models (describing patient clusters) into a system that return the model best describing each vector.
  • Data synthesis: Load a set of generative models and a model transition probability matrix into a system that draws vectors from the generative models, following a model activation pattern as described by the transition probability.

Currently, the first flow is implemented, tested and deployed. It is now undergoing testing to showcase the benefits of the PHYSICS approach in terms of handling rapid small requests by merging them into larger ones. The rest of the flows are under initial implementation. Stay tuned for more news on our progress!

You might be interested in …

Newsletter

View our previous Newsletters

Sign up to stay informed on our latest updates!