{'fraction_non_alphanumeric': 0.0216787103946637, 'fraction_numerical': 0.0027793218454697055, 'mean_word_length': 5.545454545454546, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Towards Non-Invasive Recognition of Developers' Flow States with Computer Interaction Traces

Flow is a holistic description of people's optimal experiences during creative activities that can be characterized as being totally concentrated on, and actively involved in the task, enjoying the process of creation, and achieving a balance between one's skill and the task's challenge. Understanding software developers' flow states has attracted an increasing attention in both research and practice because of the strong link between being in flow and achieving good performance. In this paper, we study the problem of tracking and recognizing developers' flow states by tracing their computer interactions including activities of using the keyboard, mouse, IDE functions, and switching application windows. Compared to the traditional approaches that rely on self-reports or wearable sensors, a major advantage of the proposed approach is being non-invasive for not requiring any additional efforts from the developers after the training phase is completed, which is important because the developers' flow states can easily be interrupted by external interferences. Based on the captured interaction traces, we represent the developers' activities with extensive features, and propose to address the flow state recognition problem using machine learning technologies. And a hierarchical recognition model is built following the multi-dimensional construct of the flow concept, which is interpretable and effective. We develop a prototype system and conduct a 17-day field study in a medium-sized IT company in China to collect real-world data. The results show that our approach is effective by achieving the highest recognition accuracy of 92.6%, and efficient for performing real-time recognition.