Informatica 42 (2018) 279–281 279 Application for Viral Hepatitis Infection Risk Assessment - HEPY Alen Ajanović, Andrej Ulčar, Ana Peterlin, Karolina Počivavšek and Gašper Fele-Žorž Faculty of Computer and Information Science, Večna pot 113, 1000 Ljubljana, Slovenia E-mail: polz@fri.uni-lj.si Anton Gradišek and Matjaž Gams Institut Jožef Stefan, Jamova cesta 39, 1000 Ljubljana, Slovenia E-mail: matjaz.gams@ijs.si Mojca Matičič Clinic for Infectious Diseases and Febrile Illnesses, University Medical Centre Ljubljana Japljeva 2, 1525 Ljubljana Slovenia E-mail: mojca.maticic@kclj.si Keywords: viral hepatitis, infection, health education, web application, preventive medicine Received: June 2, 2018 We present a web application to inform users about different types of viral hepatitises. The core of the application is a questionnaire about past behavior and risk factors. Based on the answers, it produces a personalised overview of any risky actions that the user might have taken in the past. The site also contains general information about these diseases, which can help users identify them or seek proper precautions in order to avoid them. Povzetek: Predstavljamo spletno aplikacijo za informiranje uporabnikov o različnih tipih virusnega hepatitisa. Središče aplikacije je vprašalnik, ki na podlagi odgovorov in dejanj uporabnika poda osebno oceno stopnje nevarnosti za različne okužbe hepatitisa. Stran vsebuje tudi splošne informacije o teh boleznih, ki lahko uporabniku pomagajo pri iskanju hitre in ustrezne pomoči. 1 Introduction Hepatitis is an inflammation of the liver. Hepatitis viruses are the most common cause of hepatitis. It presents an important global healthcare problem as it has been estimated to affect 330 million people worldwide [1]. In Slovenia, it is estimated that less than 1% of the population is infected with HBV (hepatitis B virus) and around 0.4% with HCV (hepatitis C virus) [2]. They are of greatest concern because of the burden of illness and death they cause and the potential for outbreaks and epidemic spread. Viral hepatitis may be present as an acute or chronic disease. In acute disease which may occur with mild or no symptoms, or may include symptoms such as jaundice, dark urine, pale stool, extreme fatigue, nausea, vomiting and abdominal pain. Acute HBV and HCV infection are most likely to become ongoing and chronic and are the most common cause of liver cirrhosis and hepatocellular carcinoma, which can lead to liver failure and death [3]. Due to mild and nonspecific signs and symptoms, patients with chronic viral hepatitis typically do not know they are infected and are the main source of spreading the disease, mostly by risky behavior. The main problem with hepatitis virus infections is that the patients do not know they are infected until the disease has already developed to an advanced stage of liver failure, at which point it becomes difficult to treat. Since serious liver complications of chronic hepatitis infections can be prevented or managed if the disease is detected and treated in its early stages, it is important to identify the infected individuals as soon as possible and act accordingly. Collecting and identifying valid health information online is difficult. Patients would be much better served by a centralized site which is endorsed by medical professionals and contains all the relevant information in one place. In this paper, we present a web application (https://hepy.mf.uni-lj.si/) that aims to educate users about viral hepatitis infections and to assess possible risks of infection, in a safe anonymous environment. The application is a follow-up of an application to educate about and assess risks for sexually transmitted infections ASPO [4], built on an improved platform with modified goals. We discuss the implementation and the functionality in the subsequent sections. 2 Related work To date, the number of web applications dealing with assessment of risk for viral hepatitis infection and informing general population on different types of viral hepatitises is limited. A descriptive observational study of available viral hepatitis smartphone applications was carried out by Cantudo-Cuenca et al. in 2013 [5]. They identified 232 applications related to viral hepatitis in Google Play Store (Android) and Apple App Store (iOS) of which 33 were selected for further analysis. Most of these apps were uploaded under the medical category. 280 Informatica 42 (2018) 279–281 A. Ajanović et al. Only 6 apps had exceeded 1000 downloads. A total of 12 apps were aimed at health professionals, while 4 focused on patients (7 on both of them). The participation of health professionals in the development of apps was 57% [5]. Lack of professional healthcare involvement and lack of public organisation participation in the development of such applications is raising concern regarding the reliability and accuracy of their medical content [6]. 3 Website description 3.1 General information The main purpose of our web application is to provide static information about different hepatitis diseases and general guidelines on how to identify the symptoms, as well as avenues to seek help if need-be. It provides a general overview of each individual disease as well as all recommended steps needed in order to avoid contracting one. This makes it useful both for a potentially sick patient, as well as a healthy person, as it provides necessary curative and preventative information. Figure 1: Landing page of the website. 3.2 Questionnaire The aim of the questionnaire is to analyse one’s symptoms and provide personal feedback based on the given answers. The questions are formed in a way that makes the user reflect on their actions and become acutely aware of the behavior they have exhibited in the past which might have led up to them contracting a potential disease. This is enforced by short messages which appear as the user is answering particular questions, informing them that such behavior is risky and why. At the end, users get a general overview of their answers and how risky their actions were, using color-coding for severity; green, orange, or red. 4 System description 4.1 Frontend The frontend uses Bootstrap [7] for styling and AngularJS [8] for dynamic content delivery. These technologies allow the page to seamlessly display information and track the user’s progress even in the case of a temporary server or internet outage. Each answer is only recorded on the client during the solving of the questionnaire. When finished, the user is prompted and can decide whether to permanently delete the data or to send it anonymously to the server for statistical analysis. If the user does not agree, no data is stored or sent to the server. After completing the questionnaire, they get their final risk assessment that consists of a personalised message based on their answers and risk factors. These may include not being vaccinated, travelling to foreign countries, etc. 4.2 Backend Django [9] was used for the backend in order to allow a combination of a static website and a dynamic questionnaire, as well as to make potential future improvements easier. The questionnaire contains single and multiple-choice questions. Since there is a large number of questions in total and some are mutually exclusive, answers to certain questions disable other questions. For example, as mandatory vaccination for HAV and HBV was introduced in 1993, people born after this year are not asked about their vaccination status. Similarly, people who did not travel to high-risk countries are not asked about their experience during such trips. This approach allows us to set an intricate web of questions while minimising the amount of time it takes for the user to answer them while still giving full feedback without skimping out on the important details. For easier access and maintenance, rules and other data regarding questions, along with the questions themselves, are stored in a relational database and made accessible via the Django REST framework [10]. 5 Methodology 5.1 Designing the database At first, we had to design our system very generally to allow the administrator to design the website as liberally as possible. This meant designing the structure in a such a way which would allow for possible expansion, as well as allow quick changes to content that is already available on the site. The goal was to create an interface where the administrator could log in with their credentials and change anything on the website at a moment’s notice. Django already provides one such feature in the shape of an administrator page. Once set up, it allows a quick overview of content on the website and running rudimentary queries directly through the page itself (such as inserting new instances of data, altering the existing ones, etc.). The first obstacle we faced is localisation, if we want the web page to be easily translatable and accessible via the admin page, all of the content would have to be stored inside of the database. This is not a problem in and of itself, but it does require some extra work to fetch the content, translate it, and put it back in. We had to sacrifice that accessibility in favour of the content being easily alterable, mostly because we don’t expect translations to happen often, but it can be very important to update the content in case of new relevant medical information. Another obstacle in designing the database was the functioning logic of the questionnaire itself. We could not afford to statically assign the questions as they were Application for Viral Hepatitis Infection... Informatica 42 (2018) 279–281 281 continually altered, switched, or completely scrapped even in the process of designing the site. We had to come up with a system that would allow us to assign different types of questions with different values regarding risk assessment, change the order and even which questions can preclude others from being shown based on their answers. All of this had to be easily adjustable by the administrator. 5.2 Designing the questionnaire In designing the aforementioned system there were a couple of options that we initially considered. We wanted to support different types of questions, so the easiest way to encode that was to have a number of discrete values and some type describing what the question was in the database. We could then programmatically extract the data and insert the appropriate question based on type in our frontend part of the application. This means that inserting a completely new type would require writing code, but for the purposes of our questionnaire, we mainly focused on discrete questions since they allow us to both inform the user, as well as guide them through the process of answering them. This also means that the administrator can switch between types with a single query, for example, changing a “radio” type questions to a “checkbox”. The second part was enabling a system that could potentially exclude other questions based on the user’s given answers. At first, we wanted questions to be separate entities that would be connected somehow, but we opted for a more flexible approach and utilised a queue. Every question has an assigned id and an order property. When the user begins answering questions, we construct a priority queue based on this order. Each question is comprised of entities called “answers”. Every answer has a property which contains a (possibly empty) set of references (ids) to the questions which should not be should if this answer is chosen. For example, if the user selects a certain answer and its exclusionID is set to 3, we will remove question with id=3 from the queue. As the user progresses through the questionnaire, this question is omitted. This also allows the user to go back and change their answer, making question 3 reappear unless some other answer disables it. It is also possible to alter the order of the questions. The administrator can do it by hand by simply changing the priority, but it is also possible for a particular answer to trigger the change. We grouped questions into clusters that have similar semantic meanings. If an entity has a special flag that rearranges these, it is possible for an answer to alter the order in which these groups appear in. This is simply done by having another property which tells us which group should come first. 6 Conclusion As the number of hepatitis infections increases, we need to find a way to inform the general public and provide its members with medically accurate information in order to combat the disease before it develops too far. While the internet holds a lot of information, not all of it is completely medically accurate. The aim of the application is to readily provide all relevant information to users, both identifying potential risk factors or symptoms and learning about preventative measures, while at the same time offering a safe anonymous online environment. With the introduction of this website, we hope to bridge the gap of knowledge and urge users to seek appropriate help and spread this valuable information to others. Acknowledgement The project was held under public tender "Po kreativni poti do praktičnega znanja" (Creative path to practical knowledge), funded by Ministry of Education, Science and Sport, and European Union. We thank other participants in the project: Matic Podpadec, Ana Prodan, Saša Rink, and Špela Pišek. References [1] WHO http://www.who.int/mediacentre/factsheets/ Accessed: 22-05-2018 [2] J. Tomažič and F. Strle, Infekcijske bolezni, vol. 1. Ljubljana: Združenje za infektologijo, Slovensko zdravniško društvo Ljubljana 2014/2015. A. Wasley, S. Grytdal, and K. Gallagher, “Surveillance for Acute Viral Hepatitis - United States, 2006,” MMWR Surveillance summaries, 2008.[Online]. Available: https://www.cdc.gov/ mmwr/preview/mmwrhtml/ss5702a1.htm. Accessed: 23-05-2018. [3] N. A. Terrault, N. H. Bzowej, K.-M. Chang, J. P. Hwang, M. M. Jonas, and M. H. Murad, “AASLD guidelines for treatment of chronic hepatitis B,” Hepatology, vol. 63, no. 1, pp. 261–283, Jan. 2016. [4] Ajanović, A., Konda, J., Fele-Žorž, G., Gradišek, A., Gams, M., Peterlin, A., ... & Matičič, M. Application for sexually transmitted infection risk assessment. Informatica, 41(2), June 2017. [5] Cantudo-Cuenca MR, Robustillo-Cortés MA, Cantudo-Cuenca MD, Morillo-Verdugo R. A better regulation is required in viral hepatitis smartphone applications. Farm Hosp; 38(2):112-7. April 2014. [6] S. D. Burdette, T. E. Herchline, R. Oehler, “Surfing the web practicing medicine in a technological age: using smartphones in clinical practice,” Clin Infect Dis; vol. 47, pp. 117-122, Jul. 2008. [7] Bootstrap CSS, https://getbootstrap.com/css/ Accessed: 2018-19-05. [8] AngularJS, https://angularjs.org/ Accessed: 2018- 19-05. [9] Django, https://www.djangoproject.com/ Accessed: 2018-19-05. [10] Django REST framework, http://www.django-rest- framework.org/, Accessed: 2018-19-05. 282 Informatica 42 (2018) 279–281 A. Ajanović et al.