# Using Keystroke Dynamics in a Multi-Agent System for User Guiding in Online Social Networks
## 1 Introduction  
The presence of online applications in our daily lives has risen recently, and social network sites (SNSs) are some of the most predominant. In this scenario, it is interesting that the systems that are managing online sites could also help prevent potential issues that could arise from user interactions. Two aspects that a system should take into account when dealing with these kinds of scenarios are the potential risks that can arise from the interactions between users and what factors influence the likelihood of incurring in one risk or another. Regarding the risks, several risk factorshave been reported in [1, 2]. Between them, there are contact risks or the risk of interacting with strangers, content risks or the risk of receiving inappropriate content, and commercial risks or the risk of being asked for personal information. Another factor is the fact that certain social groups can be more vulnerable to risks. In [3] it is shown that teenagers, who belong to a social group that uses SNSs frequently [4], have characteristics that make them more vulnerable to risks navigating SNSs. Concerning the factors that can influence people to incur risks, we focus on the decision making process in the current work. In [5] authors reviewed the effects of several aspects of the emotional states of the users on decision making. They show that incidental moods affect decision making by altering the perception of a person, and that discrete emotions, integral affects, and regret also affect decision making (with regret acting as anticipated regret, as in thinking of a negative outcome before it happens). Furthermore, stress has been associated with a concrete emotional state and has been used to implement software called TensiStrength to detect stress and relaxation magnitude in texts in [6]. For this reason, it may be useful to create a module that specializes in detecting stress apart from the sentiment analysis module, in a system that guides users in online sites. Regarding the influence of the emotional state in the decision making process, and following the general idea of aiding decision making of users in SNSs through analyzing their emotional state and stress levels, in [7] we built a multi-agent system (MAS) used for analyzing the data of users in a SNS. The analyses in the MAS are used to detect the emotional states and stress levels of users and guide them based on this information. In this MAS only sentiment and stress analysis on text data was being performed. Nevertheless, in the literature, we found that keystroke dynamics have been used to successfully build models that detect the sentiment state of a person [8]. Keystroke dynamics are also a non-invasive way of gathering data from users that can be the input to models able to detect sentiment and stress levels. For these reasons, we consider that it is a way to improve the system that we presented in [7]. For this purpose, we designed, implemented, and integrated two new analyzers into a new version of our system, which are used to perform sentiment and stress analysis with keystroke dynamics data, respectively. The analyses of data that are performed by the new analyzers use artificial neural networks (ANNs) to improve the classification accuracy of the system since machine learning techniques have achieved state-of-art accuracies in aspect-based sentiment analysis tasks [9]. Moreover, a combined version of both sentiment and stress analysis has been proposed for text data and keystroke dynamics data. The contributions of the present work are, then, the design and implementation of agents capable of recognizing sentiment and stress in keystroke dynamics data, and their integration into a MAS that uses this information for guiding users in SNSs. This process has the goal of achieving better recognition of negative states that could produce negative outcomes on SNSs, so the system can better prevent them.