=Paper=
{{Paper
|id=Vol-1891/paper1
|storemode=property
|title=Designing a Personalised Case-Based Recommender System for Mobile Self-Management of Diabetes During Exercise
|pdfUrl=https://ceur-ws.org/Vol-1891/paper1.pdf
|volume=Vol-1891
|authors=Yoke Yie Chen,Nirmalie Wiratunga,Stewart Massie,Jenny Hall,Kate Stephen,Amanda Croall,Jacky MacMillan,Lesley Murray,Geoff Wilcock,Sandra MacRury
|dblpUrl=https://dblp.org/rec/conf/ijcai/ChenWMHSCMMWM17
}}
==Designing a Personalised Case-Based Recommender System for Mobile Self-Management of Diabetes During Exercise==
Designing a Personalised Case-Based Recommender System for Mobile
Self-Management of Diabetes During Exercise
Yoke Yie Chen1 , Nirmalie Wiratunga1 , Stewart Massie1 , Jenny Hall2 , Kate Stephen2 ,
Amanda Croall3 , Jacky MacMillan4 , Lesley Murray4 , Geoff Wilcock5 , Sandra MacRury2
1
School of Computing Science and Digital Media, Robert Gordon University, Aberdeen,
2
Division of Health, University of the Highlands and Islands, 3 Diabetes Scotland,
4
Educational Development Unit, University of the Highlands and Islands
5
Openbrolly, Elgin, Scotland.
Abstract exercise using a case-based reasoning approach. The mobile
application aims to facilitate exercise sessions by logging user
Increasing physical activity for type 1 diabetes pa- data such as intensity of the physical exercise, blood glucose
tients is associated with physical and mental health levels, carbohydrate intake and insulin doses before, during
benefits. However, the control of blood glucose lev- and after exercise.Data collected from users for every exer-
els for diabetes requires an effective balance of car- cise session is used as the case base to produce personalised
bohydrate intake and insulin dosage to maintain a recommendations of carbohydrate intake (CHO) and insulin
balanced blood glucose level before, during and af- dosage (INS) by retrieving previous similar sessions. Further,
ter exercise. Existing mobile applications lack an presenting recommendations on a small screen device can be
intervention module that help users maintain an op- frustrating to users. Therefore, we present the recommenda-
timal blood glucose level while performing phys- tions to users using visual representations.
ical exercise. In this paper, we propose a per- The rest of the paper is organised as follows: in Section 2
sonalised case-based recommender system for self- we present previous work related to this paper. In Section 3
management of diabetes during exercise. One key we describe an existing guidelines on self-management of di-
aspect of the proposed recommender system is the abetes. Our proposed personalised mobile recommender sys-
recommendation of carbohydrate intake and insulin tem for self-management of diabetes is described in Section
dosage to users during exercise session using vi- 4. Further, we present the visual representations of the recom-
sual representations. We conduct a user study with mendations in Section 5. Finally, we present users’ feedback
10 type 1 diabetes patients focusing on usability on the mobile app in Section 6 and followed by our conclu-
of the visual representations and the helpfulness of sions in Section 7.
the recommendation. Preliminary results encour-
age future work towards the development of a mo-
bile application for patients.
2 CBR in Diabetes Management
Case-based reasoning (CBR) is an artificial intelligence ap-
proach that solves new problems using specific knowledge
1 Introduction extracted from previously solved problems. Previous works
Type 1 diabetes is a chronic disease that results from insuf- have demonstrated the effectiveness of applying CBR to
ficient insulin production by the pancreas. The loss of in- the management of chronic disease. In diabetes manage-
sulin production can cause long-term complications such as ment, a case be identified as corresponds to a periodical
heart disease, kidney disease and stroke that are caused by visit with a physician and each case consists of the fea-
hypoglycemia (blood sugar level too low) and hyperglycemia tures that represent a problem, its solution and the outcome
(blood sugar level too high). The quality of life for people obtained after applying the solution [Marling et al., 2012;
with type 1 diabetes can be improved by gaining better con- Montani et al., 2000]. In our work, we also identify prob-
trol on blood sugar level (BGL) as well as increasing physical lem, solution and outcome features, however the focus is on
exercise. However, the need for persistent monitoring of BGL supporting exercise and so a case corresponds to a particular
and insulin administration makes maintaining an optimal self- exercise session.
management regimen during physical activity a challenging The types of features used in representing a case can be
task. There are many mobile apps in the Google PlayStore a numerical value (e.g. weight, blood glucose level) or a
and the Apple AppStore that support self-management of di- textual description (e.g. symptoms of hypoglycemia event).
abetes through data logging with a goal-setting functionality. However, physicians often describe patients using imprecise
However, these mobile apps lack an intervention module that linguistic data that cause the case base to contain imprecise
recommends a self-management plan to the users during ex- knowledge and representation. To solve this problem, [El-
ercise. Sappagh et al., 2015] applies ontologies for case representa-
In this paper, we propose a personalised recommender sys- tion and a fuzzy semantic retrieval algorithm to retrieve cases.
tem for mobile self-management of type 1 diabetes during However, cases that are retrieved and recommended to users
may be ignored due to lack of transparency in the recommen-
dation. To improve users’ trust and acceptability of case-
based recommender systems, [Vargheese et al., 2015] pro-
posed to improve the transparency of recommender systems
by providing an explanatory summary that shows the reason-
ing process behind a proposed recommendation. In our work,
we provide explanation of the reasoning for the CHO and INS
recommendation using past users’ similar exercise sessions.
Figure 2: Visualisation
3 Rule-based Self-Management of Diabetes
Guidelines
the user’s current session (query case) and the top 5 most sim-
The self-management guidelines are developed by a group of ilar sessions (cases) are presented to the users. In this way,
healthcare professionals and individuals with type 1 diabetes. users can compare and self-adjust their CHO or INS accord-
There are three main stages in managing BGL: before, dur- ing to these similar sessions and strike a balance between high
ing and after an exercise session. For each exercise intensity and low BGL.
level, the guidelines provide a specific amount of CHO or INS Figure 2 shows the visual representation of the recom-
dosage that a user should take before exercise. Users decide mended cases for self-adjustment using CHO based on the
on the type of exercise they are undertaking and self-adjust user’s previous similar sessions. Each circle represents a pre-
their BGL based on the recommended amount of CHO or vious session and the amount of CHO taken. The color of
INS dosage. Thereafter, users proceed to measure their BGL the circle represent the outcome of the user’s action. A green
to decide if they are fit to start a physical exercise. If their circle represents a BGL within the balance range, a yellow
BGL is within an appropriate range, they proceed to begin circle represents a BGL slightly lower and a red circle rep-
the activity. Otherwise, users need to stop exercising when resents a BGL either too low or too high. A filled circle in-
their BGL is either too high or too low. In the case where dicates the amount of CHO taken is the same as the amount
the user’s BGL is not too low but falls out of the appropriate recommended by the rule-based self-management guidelines.
range, they are discouraged from beginning any activity in a Based on the scenario in Figure 2, the user may want to take
predetermined time period and taking a specific amount of 20g to 30g of CHO to achieve a balanced BGL. Finally, the
CHO or INS dosage according to the guidelines, after which user provides their feedback on the app during the exercise
they recheck their BGL to make sure that it is within an ap- session.
propriate range before the start of physical activity. During
exercise, the users are required to check their BGL on a regu- 4.1 Case Structure
lar basis in order to avoid a hypoglycemia (hypo) event. They
are advised to self-adjust their BGL using a specific amount A user exercise session is mapped into a case that contains all
of CHO or INS dosage stated in the guidelines. After com- relevant data from before, during and after exercise. There-
pleting the exercise session, users are required to check their fore, each case consists of multiple subcases where each sub-
BGL again and take a specific amount of CHO or INS dosage case represents a user measurement of their BGL. Formally,
as recommended in the guidelines. a case c is defined as a tuple:
The rule-based guidelines are developed for all individuals
with type 1 diabetes. However, they lack adaptability on CHO c = {I, U, F } (1)
and INS adjustment needed for a personalised recommender where I contains user and session information (e.g. id, age,
system. Therefore, we propose a case-based reasoning ap- weight etc), U is a set of subcases and F is the feedback from
proach to help similar users self-adjust their CHO and INS the users on the session. Each subcase subc is represented as
intake outside of fixed existing guideline prescriptions. follows:
4 Case-based Recommender System for subc = {S, A} (2)
Diabetes Management where S is the data collected from user measurement of BGL
The aim of the personalised recommender system is to rec- (problem description) and A is the actions taken for each
ommend CHO intake or INS dosage before, during and after measurement (solution description). A summary on the de-
an exercise session. Figure 1 illustrates the process of a user’s scription of each feature that is relevant in each subcase is
exercise session. In each session, users record their BGL in shown in Table 1.
three different self-management stages: before, during and Normally, each case will have a minimum of three sub-
after exercise. This helps the user monitor their BGL changes cases. However, in some situations where users are undertak-
throughout the exercise session and increase their confidence ing more than one hour of exercise, we record each hour of
in self-management during exercise. exercise as a subcase. Therefore, the size of S corresponds to
Once the users have recorded their BGL, the system re- the number of times users check their BGL in each session:
trieves a set of similar sessions from the case base. The re-
trieved cases are ranked by decreasing order of similarity to S = {S1 : {f1 , f2 , f3 }, ..., Sv : {f1 , f2 , f3 }} (3)
Figure 1: Overview of Personalised Recommender for Self-Management of Diabetes During Exercise
Features Description
f1 intensity Intensity level of the exercise
low intensity exercise such as tai chi. After one hour of ex-
ercise, the user’s BGL reading is 4.0 mmol/L and requires an
f2 stageid The three stages in self-management: be- increase of CHO intake to boost BGL to an appropriate range.
fore (B), during (D) and after (R) exer-
cise At this stage, a timer will start in the app. Once the time is up,
the user will record their BGL and a subcase is created in the
f3 BGL User’s blood glucose level case base. In this example, the user takes 20g of carbohydrate
f4 action The user’s action to manage glucose and rechecks their BGL 15 minutes later before continuing
level to exercise. However, the outcome of the user’s action (4.5
f5 outcome The outcome of the user’s action
mmol/L) does not increase their BGL to a satisfactory level.
Therefore, the user takes another 20g of CHO and rechecks
Table 1: Subcase Features their BGL. At this point, the user’s BGL reaches a satisfactory
level (5.0 mmol/L) and the user continues to exercise.
where v is the number of times the user checks their BGL and
Si is the data collected at each measurement i. For each mea-
surement, we consider the intensity of the exercise (f1 ), self-
management stage (f2 ) and BGL (f3 ) as the most relevant
features that describe the state of the user. The corresponding
action at each measurement is described in A.
Figure 3: Subcase 1 Figure 4: Subcase 2
A = {A1 : {f4 , f5 }, ..., Av : {f4 , f5 }} (4)
Here, there are two relevant features:
4.2 Case Retrieval
• action taken by the users (e.g. amount of CHO or INS
dosage) (f4 ). Case retrieval is driven by a similarity measure between the
new user’s exercise session and the completed sessions. In
• BGL after user’s action (f5 ). particular, we evaluate similarity of two different aspects in
Figure 3 and 4 shows example of subcases for a user ses- all self-management stages: exercise intensity and BGL. Fig-
sion during the exercise. Here, the user intends to perform a ure 5 shows the new user’s exercise session (User Query) and
the completed sessions in the case base (Case 100 to Case intake of the current user in previous similar sessions. Simi-
102). In this example, the user has started one hour of low larly, the bottom row shows the CHO intake by other similar
intensity exercise and recorded their BGL as 5.2 mmol/L be- users of the system who had similar sessions.
fore exercise (B001). After the first hour of exercise (D001)
the user’s BGL is low (4.6 mmol/L) and requires to take ad-
ditional CHO before continuing to exercise. At this point, the
system will recommend the amount of CHO to the user based
on the user’s previous similar sessions.
Similarity Measures
We divide the retrieval of similar cases in two stages. In the
first stage, we retrieve cases from the case base where:
Figure 6: Circle - User’s Similar Sessions
• the exercise intensity is same as the user query, and
• the number of subcases per self-management stage are
equal to or greater than the user query.
For instance, in Figure 5, we retrieve case 100 and 101
because they share the same exercise intensity with the
user query and both cases have one subcase for each self-
management stage (B001 and D001). Thereafter, we cate-
gorise the cases into two groups to recommend similar cases
from the user’s own previous sessions and from those of other
users of the system.
We measure the similarity between the user’s query case
and the remaining cases using the inverse Euclidean distance
as a measure of similarity across self-management stages. Es-
sentially, we want to make sure that the retrieved cases will
have a similar number of subcases to monitor the changes of
BGL and the corresponding user action. Therefore, the dis- Figure 7: Circle - User and other Users’ Similar Sessions
tance between a user query q and a candidate c is calculated
as follows: An alternative visual representation is a radar chart that
v shows the degree of similarity of the recommended cases to
1u
uK
X the user query (see Figure 8). The closer the case (circle) is
dist(q, c) = t (qs − cs )2 (5) to the centre point the higher the similarity of the case to the
K i=1 user query. Users are provided with options at the bottom of
Here, qs and cs are the BGL values in each subcase for the the screen to either view the user’s previous similar sessions
query and candidate case respectively and K is the minimum or other similar users’ sessions.
number of subcases across the self-management stages be-
tween a query and candidate case.
5 Visual Representation
In this work, we design five visual representations to present
recommendations to users. Figure 6 shows a sample screen
where users recorded their BGL in the range of 4.0 mmol/L
to 5.0 mmol/L. Besides the recommendation presented by the
system, there is also a timer and a message that informs the
user to take 20g of CHO and recheck their BGL in 15 min-
utes. By default, the app will present to the user the amount of
CHO intake proposed by the guideline as a reference. How-
ever, users may adjust the CHO amount if they are confident
to make the adjustment. Here, the system presents a row of
similar cases that shows the CHO intake of the users in pre- Figure 8: Alternate Visualisation - Radar Chart
vious similar sessions where the user is likely to follow the
guidelines. Each circle represents a case and the date when Figure 6 and 7 only show the CHO intake of a particular
the exercise session was undertaken. The leftmost circle is the self-management stage. In Figure 9 and 10, we consider alter-
case that is the most similar to the user query and the right- native visualisations to present the details of a complete sim-
most circle indicates the least similar case. In contrast, the ilar session to the users by using a bar chart and a line chart.
second visual representation provides two sets of recommen- These displays show the time when the participant recorded
dations as shown in Figure 7. The top row shows the CHO their BGL, the recorded BGL and the actions taken by the
Figure 5: Case Base
user. This detailed view is accessed when the user selects a
case that they want to view by clicking on the circle. Once a
case is chosen, the details of the case are displayed on top of
the recommended cases.
Figure 10: Detail Case View as Line Chart
The personalised recommendation of previous sessions to
users received a positive feedback. In particular, the users
Figure 9: Detail Case View as Bar Chart state that looking back on the previous similar sessions to
check how their BGL changed helps them self-adjust their in-
take of CHO and INS when doing the same intensity of exer-
cise. However, they found the recommendation of the similar
6 User Evaluation sessions from other users is mostly helpful to fill out generic
We conducted a user evaluation on the mobile app to eval- information that is less individualised, such as the outcome of
uate the usability of the five different visual representations performing long duration physical exercise.
that were used to present the recommendations as well as the Feedback from participants on the visual representations
recommendations provided on similar sessions. During the suggests that the circle and line chart are the preferred op-
evaluation period, a total of 119 sessions were logged and tions over the radar and bar chart. Specifically, the line chart
each user had an average of 3 exercise sessions per week. provides a clearer picture on the BGL trend over the entire
exercise session. One of the comments given by the users is
that the bar chart would be more helpful if the user could set
up a BGL threshold on the chart to show how far their BGL
is from the threshold. Based on the feedback, we observed
that users are not aware that the order of circles represents a
degree of similarity. Therefore, future design should include
a more explicit indicator to show the degree of similarity to
the user’s current session.
7 Conclusions
Personalised mobile recommender systems for self-
management of diabetes have the potential to assist patients
in maintaining an optimal blood glucose level and at the same
time increase their confidence to undertake physical activity.
In this paper, we propose a case-based recommender system
to recommend CHO intake and insulin dosage to users during
exercise. The recommendations are generated based on a
user’s past experience with similar exercise sessions and
on other users’ past experiences. We designed five visual
representations to present and explain the recommendations
to users. A preliminary study on the mobile app with 10
diabetes patients revealed that there are some improvements
needed on the design of the visual representations. Never-
theless, feedback from users was positive and suggested that
the case-based recommender system could be helpful for
self-management of diabetes.
References
[El-Sappagh et al., 2015] Shaker El-Sappagh, Mohammed
Elmogy, and AM Riad. A fuzzy-ontology-oriented case-
based reasoning framework for semantic diabetes diag-
nosis. Artificial intelligence in medicine, 65(3):179–208,
2015.
[Marling et al., 2012] Cindy Marling, Matthew Wiley, Raz-
van Bunescu, Jay Shubrook, and Frank Schwartz. Emerg-
ing applications for intelligent diabetes management. AI
Magazine, 33(2):67, 2012.
[Montani et al., 2000] Stefania Montani, Riccardo Bellazzi,
Luigi Portinale, Giuseppe dAnnunzio, Stefano Fiocchi,
and Mario Stefanelli. Diabetic patients management
exploiting case-based reasoning techniques. Computer
Methods and Programs in Biomedicine, 62(3):205–218,
2000.
[Vargheese et al., 2015] John Paul Vargheese, Rachel Harri-
son, Mireya Munoz Balbontin, Arantza Aldea, and Daniel
Brown. Increasing transparency of recommender systems
for type 1 diabetes patients. 1st ECAI Workshop on Artifi-
cial Intelligence for Diabetes, 119(1):26, 2015.