hybrid recommender system architecture for personalized wellness management
TRANSCRIPT
HYBRID RECOMMENDER SYSTEM ARCHITECTURE FOR PERSONALIZED WELLNESS
MANAGEMENT
Master of Science – Thesis Defense
Prasad Priyadarshana Fernando, Boosabaduge
Complex Engineered Research LabDepartment of Electrical and Computer Engineering
The University of Akron
02/24/2016
OUTLINE
Introduction Background Hybrid Recommender System Architecture Design of the Hybrid Recommender System Illustrative Examples and Evaluation Conclusion and Future Works Demonstration
Introduction
• The current healthcare costs in the USA exceeds $3.8 trillion and the reactive approach to managing health is not sustainable
• The focus on keeping healthy people healthy is one approach to addressing this serious societal concern
• Exercising is one of the key requirments for a healthy life
Why Exercising is Important
• Helps prevent diseases• Improves stamina• Strengthens and Tones• Enhances flexibility• Controls weight• Improves quality of life
Why Exercise Recommendation is needed
• Don’t know what to do• Don’t know how to do• Consulting an expert is expensive• Consulting an expert is time consuming• Freely available guidelines are not personalized
Our Goal
• To empower wellness management at the scale of the society, efficient software tools are necessary
• So the design objectives for our system were;– To Reduce the cost burden on participants– To Improve the access to expertise for the participants– To explore personalized options for the participant
Challenges in Recommending Exercises
• Recommender Systems are widely used to recommend items such as movies, books, products and services to users
• The problem of recommending exercises to participants in a wellness program is, however challenging and nuanced
• Participants must adhere to the appropriate intensity and frequency to benefit from the exercise
• These exercises must help the participants to achieve their wellness objectives
Why it is different from Item Recommendation
• The efficacy of the exercises recommended is not merely the user preference
• The efficacy must often be assessed after a lapse of several weeks
• Recommended exercises must be refined over a duration of time
• Health, physical, motivational, occupational, etc. conditions of a person tend to change as the particular person uses the recommended exercise
The Basis for the Solution
• The participants are expected to interact regularly with the system by providing their latest measurement so that the software systems can make decisions based on the individual's requirements with the time
• The main concept that was exploited is, the people with similar physical and motivational conditions tend to perform similar kind of exercises
Proposed Solution
• To address the above challenges, we architected a hybrid recommender system that incorporates two major components– Rule Based Expert System : To evaluate the participant’s
conditions in order to come up with a possible exercise schedule
– Collaborative Filtering Recommender System : To Explore more exercises that would be interesing to the participant
OUTLINE
Introduction Background Hybrid Recommender System Architecture Design of the Hybrid Recommender System Illustrative Examples and Evaluation Conclusion and Future Works Demonstration
Background
• The background knowledge on the following fields were useful in building our Hybrid Recommender System (HyRES) for Exercise Recommendation;1. Exercise Science Domain Knowledge2. Rule Based Expert System3. Recommender System
Exercise Science
• In order to integrate exercise science domain knowledge into HyRES, we used the following overall strategy;– Determine the participant's capability to exercise based on
physical activities performed recently– Come up with a suitable exercise duration for the participant
based on the fitness status and the goal of exercising– Consider the participant's anthropometric and biometric data to
modify the exercise schedule– Consider the gender, age, diseases and disabilities as high
priorities to alter the recommended intensity and duration– Estimate the desired daily calorie intake and compare it with the
actual calorie intake to change the exercise schedule– Explore more exercise based on participants preferences
Estimating the Ability to Perform Exercises
Evaluating Participants and Exercises
• Metabolic Equivalent of Task (MET) – Exercise Intensity Ratio
• Basal Metabolic Rate (BMR) – Participant’s Daily Calorie Intake
• Body Mass Index (BMI) – Participant’s Obesity
Rule Based Expert System
• The exercise science knowledge and practice guidelines were codified as rules in the Domain Knowledge Module
• We utilized a Forward Chaining system that started with the facts and triggered actions or conclusions based on the Rete Algorithm
• We selected the JBoss Drools platform because it was open source and supported easy integration with the Java implementation of HyRES
Recommender System
• Recommender Systems use two main techniques to recommend new items to users;– Content Based (CB) Recommendation– Collaborative Filtering (CF) Recommendation
• Starting with the output of the Expert System, the Recommender System generates more recommendations by accounting for user preferences
• CF techniques are used in HyRES to find;– Similar exercises to participant’s preferred exercises– Similar exercises that similar participants are preferring
Collaborative Filtering Approach
• In Collaborative Filtering, we considered two main approaches– Neighborhood Method– Latent Factor Model
• The basis for the CF techniques is the user-exercise preference matrix
• For Neighborhood based CF, we used pre built set of algorithms in Apache Mahout Machine Learning Framework
OUTLINE
Introduction Background Hybrid Recommender System Architecture Design of the Hybrid Recommender System Illustrative Examples and Evaluation Conclusion and Future Works Demonstration
HyRES Architecture
• HyRES was organized into the following five modules;1. PWM Storage Module – Persistent store for all data in
HyRES2. Participant Dialog Module (PDM) – Gathers participant
details and exerciese preferences3. Domain Knowledge Module (DKM) – Exercise Science
Domain Knowledge coded in JBoss Drools Expert System4. Options Exploration Module (EM) – Recommendation
funcitonality supported by Apache Mahout Machine Learner
5. System Integration Module (IM) – Coordinates the event, data and control flow across above three modules and manages the Storage
<Interact>
Participant Dialog Module (PDM)
Participant Detail
Domain Knowledge Module (DKM)
DKM Prescriptions
Integration Module (IM)
Rule Execution
Expert Rules
Exercise Selection
Participant
PWM Storage
<Profile>
<Exe
rcis
es>
Exercise Recommendation
EM Recommendations
<Prefer>
Exploration Module (EM)
Collaborative Filtering
Rules.DRL
<Prefer>
<Exe
rcis
es>
<Participant Profile>
<Recommendations>
Authentication and Interaction
HyRES Backend Library Architecture
Funcitonality of HyRES Components• Authentication – Authenticates participants and creates
sessions• Interaction – Coordinates with participant to build the profile• Modification – Changes participant’s profile through the
participant dialog• Storage – Persistant sotrage of participant records• Rule Execution – Expert system management in DKM• Exercise Selection – Combines Expert System output with the
exercise data in the PWM Storage to come up with exercise prescriptions
• Exercise Recommendation – Handles the recommender system to explore more exercise options for the participant
Integration Module (IM)
Authentication and Interaction
Participant Profile
Exploration Module (EM)
Domain Knowledge
Module (DKM)
Exercise Selection
PWM Storage
Participant Dialog Module (PDM)
Stores Participant Data
Obtains Participants Preferences
Builds Participant Profile
Evaluates Participant Profile
Obtains Updated Profile
Obtains ExercisesGenerates Exercise Prescriptions
Processes User Inputs
Trig
gers
Exp
ert S
yste
m
Generates Exercise Recommendations
Coordinates Participant Dialog
HyRES Component Interaction
OUTLINE
Introduction Background Hybrid Recommender System Architecture Design of the Hybrid Recommender System Illustrative Examples and Evaluation Conclusion and Future Works Demonstration
PWM Storage• Every participant is associated with four data sets;
1. Profile – Data gathered from participant dialog2. Exercise Prescriptions – Expert System evaluation3. Exercise Preference – Participant’s Responses for prescribed exercise4. Exercise Recommendation – More exercises explored based on
exercise preferences• PWM Storage supports the above four data models based on
three update rates;1. Meta Data – These data define the parameters that are used to
specify exercises and participant profiles2. Static Data – These data do not change after they are entered into
the PWM Store3. Dynamic Data – These data change frequently, perhaps, with each
new interaction with the participants
Participant Profile (PDM & IM)
Exercise Prescriptions (DKM)
Exercise Preferences (PDM & IM)
Exercise Recommendations
(EM)
Generated through Participant Dialog Module
(PDM)
Generated by the Domain Knowledge Module (DKM)
Generated with participant interaction on DKM decisions
Generated by observing the participant preference on
DKM decisions
Participant
Evolution of Participant Profile in HyRES
Meta Data
exercise types exercise levels exercise goals
participant occupations
Static Data
exercises
participants
participant exercise health
Dynamic Data
participant exercise preferences
participant general health
administrators
participant activity history
participant exercise schedules
exercise categories
Multitire Structure of PWM Storage
activity levels
Participant Dialog Module (PDM)• The objective for the Participant Dialog Module is to;– Gather participant information– Present potential recommendations– Collect participant preferences
• To provide participant satisfaction; PDM supports both Mobile and Web interfaces through a RESTful service
RESTful Web Service
HyRES Backend Library
JSON Interface for Participant Dialog Module (PDM)
Internet <HTTP>
PWM Storage
Mobile AppsWeb Apps
PDM IM DKM EM
HyRES Interfaces
LoginRegister
Rejected
Enter health data
Enter information on exercises performed during past 7 days
Enter information on the fitness status
Select exercise categories
Express preferences on prescribed exercises
Get recommendations based on preferences
Get exercise schedule
Rejected
<Existing Participant><New Participant>
Participant’s Activity Flow
Domain Knowledge Module (DKM)• This module encapsulates the theories from the
domain of exercise science as rules• JBoss Drools platform supports seamless and robust
interactions between the Java based implementation of HyRES and Domain Knowledge Module
• The JBoss Drools platform offers a convenient interface via Java objects
• The main object that is exchanged between the DKM and HyRES is the Participant Profile
Pattern Matcher(ReteOO)
Drools Rule Engine
Working Memory
Participant Profile
Domain Knowledge
(Rules)
Modify
Drools Expert System
Participant Attributes Used by DKM Updated by DKM
Gender ✔
Weight (lb) ✔
Height (in) ✔
Age (years) ✔
Blood Pressure ✔
Resting Heart Rate ✔
Daily Calorie Intake ✔
Exercise Goal ✔
Fitness Status ✔
Current Exercise Status ✔ ✔
Basal Metabolic Rate ✔ ✔
Body Mass Index ✔ ✔
Exercise Intensity ✔
Exercise Frequency ✔
Exercise Duration ✔
Participant Object in DKM
Drools Rule Structure• A Rule is made up of two section– ‘When’ Statement : Condition of the Rule– ‘Then’ Statement : Action based on the condition
• Within ‘Then’ statment; it can alter the working memory through modify, retract, update and insert operation on Java objects in the working memory
• JBoss Drools platform allowes us to set rule priorities through the ‘Salience’ attribute
Sample Exercise Rule in Drools
Salience Rule Purpose of Rule
50 Startup Rules Call the rule functions and set the intermediate parameters (BMR, BMI, etc) in the participants profile
40 IPAQ Exercise Rules
Set the initial Exercise Intensity based on the Exercise Ability assigned out of the three exercise levels (Minimal, Moderate and Health Enhancing)
30 Gender Rule Alter the Exercise Intensity for Male and Female participants respectively
30 Age Group Rules
Alter the Exercise Intensity for different age groups
20 Fitness Status Rules
Override the exercise intensity if the participant is subjected to some special constraints (disabled, chronic diseases, bedridden)
10 Exercise Goal Rules
Set the Exercise Frequency and Exercise Duration based on the participant’s goal of doing exercises
0 BMR Calorie Rules
Check whether the expressed goal is realistic along with the participant’s dietary pattern
0 BMI Rules Do any modification to the generated exercise schedule based on the obesity of the participant
Rules and Priorities in DKM
Rule Function Function Purpose
getExerciseLevel Calculate the Exercise Ability of the participant using the answers given for International Physical Activity Questionnaire (IPAQ)
lifeStyleToActivityLevel Determine the day-to-day activity level of the participant based on his/her life style. Participant’s occupation is considered as a key indication of the life style.
getMBICalculation Get the Body Mass Index (BMI) of the participant based on the anthropometric data in the profile
getBMRCalorieCalculation Calculate the Basal Metabolic Rate (BMR) calorie requirement for the participant using the Harris Benedict equation
Rule Functions
Exploration Module (EM)• The Exploration Module (EM) in HyRES has been
designed and implemented on the Recommender System techniques
• We investigated two different CF techniques to design the EM; – Matrix Factorization– Neighborhood Methods
• Participant-Exercise preference matrix is the basis for those CF techniques
• Neighborhood based CF is the currently used implementation in HyRES and it was based on the Apache Mahout ML Framework
Participant-Exercise Preference Matrix (M)Exercises
Parti
cipa
nts
Matrix Factorization (Latent Factor Model)
Stochastic Gradient Descent (SGD) Method
Error: The difference between actual preference and calculated value
Adjustment to Factor Matrices to minimize the RMSE
Neighborhood CF Methods
Pearson Similarity between two participants
Prediction based on a neighborhood
Apache Mahout Library Components
Recommender Data Model
Similarity
Neighborhood
PWM Storage
HyRES
HyRES intercation with Apache Mahout Components
OUTLINE
Introduction Background Hybrid Recommender System Architecture Design of the Hybrid Recommender System Illustrative Examples and Evaluation Conclusion and Future Works Demonstration
Examples and Evaluation• We used a set of synthetic participants for evaluation– A synthetic participant is a hypothetical participant that is a
typical representative of an actual participant• The attributes of the synthetic participants were
selected to test the different values allowed in the software system
• Decisions made by Expert System and Recommender System can be compared against the condition and needs of each participant
Age Group Gender Fitness Status
Exercise Goal Exercise Ability
Calorie Intake
BMI
Young (15 < age < 40)
Male Healthy Stay Healthy Minimal > BMR + 500
> 26
Retired (61 < age < 90)
Female Disabled Loose Weight Moderate < BMR – 500
< 18
Mid Age (41 < age < 60)
Chronic Condition
Maintain after Weight Loss
Health Enhancing
Balanced Healthy
Bedridden Prevent Weight Gain
Attributes of Synthetic Participants
User ID Age Gender Weight (lb)Height (inch)
Daily Calorie Intake Fitness Status Occupation Exercise Goal
Vigorous Exercise Minutes
Moderate Exercise Minutes
Light Exercise Minutes
u0 28 Male 180 71 2200 Healthy Desk WorkerPrevent Weight Gain 10 60 280
u1 22 Female 150 64 2000 Healthy Household Loose Weight 20 120 350u2 36 Female 200 64 2800 Chronic Patient Household Stay Healthy 0 20 140u3 46 Male 180 73 1800 Healthy Farmer Stay Healthy 120 350 700
u4 16 Male 190 74 2500 Healthy AthletePrevent Weight Gain 90 160 240
u5 26 Female 160 65 2000 Healthy Health CareMaintain after Weight Loss 0 160 420
u6 31 Male 200 72 2700 Healthy Academics Loose Weight 10 90 240
u7 56 Female 180 62 2100 Disabled Desk WorkerPrevent Weight Gain 0 0 180
u8 76 Male 170 73 2000 Bedridden InactivePrevent Weight Gain 0 0 20
u9 30 Female 190 70 2500 Healthy SoldierMaintain after Weight Loss 60 200 700
u10 40 Male 175 65 2700 Chronic Patient Porter Loose Weight 20 120 350u11 26 Male 154 72 2900 Healthy Student Stay Healthy 140 210 420u12 46 Female 165 66 2000 Bedridden Household Stay Healthy 0 30 75
u13 31 Male 176 60 3000 Healthy LaborerPrevent Weight Gain 50 100 420
u14 36 Female 121 60 2000 Healthy Field worker Stay Healthy 20 300 350u15 38 Female 154 68 2500 Patient Inactive Stay Healthy 0 0 45u16 25 Male 132 63 3000 Healthy Academics Stay Healthy 105 210 420
u17 71 Female 127 72 3200 Chronic Patient HouseholdPrevent Weight Gain 0 25 280
u18 26 Female 110 66 2800 Healthy Student Stay Healthy 210 280 420u19 22 Male 143 70 2600 Healthy Student Stay Healthy 45 210 300u20 41 Male 127 72 2000 Disabled Inactive Stay Healthy 0 0 210u21 26 Male 138 68 3000 Healthy Desk Worker Stay Healthy 300 280 420u22 31 Female 132 64 2200 Healthy Field worker Stay Healthy 0 50 560u23 58 Female 119 60 2300 Chronic Patient Household Stay Healthy 45 80 200u24 26 Male 154 68 2800 Healthy Student Stay Healthy 35 420 420
u25 51 Male 187 72 3000 Disabled CleanerPrevent Weight Gain 20 0 350
Synthetic Participants
u0 u2 u4 u6 u8u10
u12u14
u16u18
u20u22
u240
2
4
6
8
10
12Expert System RS (Exercise based Similarity) RS (Participant based Similarity)
Participants
Max
Inte
nsity
(MET
) Max Intensities Suggested to Synthetic Participants
u0 u2 u4 u6 u8u10
u12u14
u16u18
u20u22
u240
50
100
150
200
250
300
Minutes per Week
Participant
Exer
cise
Min
utes
per
Wee
k
Exercise Durations Suggested to Synthetic Participants
1 2 3 4 50
2
4
6
8
10
12
Desired Exercise Intensity
IPAQ Exercise Level
Reco
mm
ende
d Ex
erci
se In
tens
ity (M
ET)
Minimal Moderate Health Enhancing
u8, u12
u2, u7, u15 u10
u17, u20, u23, u25
u14 u22
u0, u1, u4, u13, u16, u19, u24
u5, u6
u18
u3, u9
u11, u21
Exercise Ability vs. Desired Intensity
1 2 3 4 50
50
100
150
200
250
300Exercise Duration
IPAQ Exercise Level
Exer
cise
Min
utes
per
Wee
k
Minimal Moderate Health Enhancing
u8, u12
u15u2u7
u20u14, u22, u24u4, u16, u23u17, u19u0, u25
u13u5
u10u1
u6
u9
u18, u21u11u3
Exercise Ability vs. Exercise Duration
OUTLINE
Introduction Background Hybrid Recommender System Architecture Design of the Hybrid Recommender System Illustrative Examples and Evaluation Conclusion and Future Works Demonstration
Conclusion• We presented a Hybrid Recommender System (HyRES) that can
effectively recommend exercises to participants. After presenting the overall architecture, the detailed design of the major modules were also presented.
• The Participant Dialog Module (PDM) gathered information from the participants based on the guidelines provided in the well-known IPAQ standard.
• The PWM Storage was designed to store participant records in a normalized object oriented manner.
• The Domain Knowledge Module (DKM) represented knowledge from the exercise science domain in rules. Based on the inputs gathered from the participants, the DKM rules determined the duration and intensity of exercises that could be recommended.
Conclusion cont.• The Exploration Module (EM) was designed using a
Collaborative Filtering techniques. Using the output of the DKM as a basis and participant preferences as input, the EM identified additional recommendations that could be recommended to the participants.
• Results based on synthetic participants demonstrated that DKM rules determined the recommended intensities and durations based on several factors and EM recommendations used to align with the decisions made by DKM.
Future Works• In the future, the rule-set in the DKM must be
expanded to incorporate additional factors and a rigorous field trial must be conducted to validate the efficacy of the approach after obtaining appropriate Institutional Review Board (IRB) clearance.
• For the large scale deployment, the Exploration Module should be distributed to enhance the performance; utilizing the support provided through Mahout Scalable ML Framework.
OUTLINE
Introduction Background Hybrid Recommender System Architecture Design of the Hybrid Recommender System Illustrative Examples and Evaluation Conclusion and Future Works Demonstration
Demonstration• We have developed a sample client application to
demonstrate the HyRES functionality;– Collects data through user inputs (PDM)– Triggers Expert System to get initial recommendations
(DKM)– Call Recommender Systems to explore more
recommendations (EM)– Presents the summarized exercise schedule to the
participants (IM)– Store participants records in the persistent store (PWM
Storage)• Android App developed to work with the RESTful web
service is also available
Thank You