BackgroundInvestigating emotion sequence patterns in the posts of discussion forums in massive open online courses (MOOCs) holds a vital role in shaping online interactions and impacting learning achievement. While the majority of research focuses on the relationship between emotions and interactions in MOOC forum discussions, research on identifying the crucial difference in emotion sequence patterns among different interaction groups remains in its infancy.ObjectivesThis research utilizes deep learning and sequential pattern mining to investigate whether there are differences in emotion sequence patterns across different groups of learners who exhibit various types of interactions in online discussion forums.MethodsData from a comprehensive array of sources, including log files, discussion texts and scores from 498 learners in online discussion forums, were collected for this study. The agglomerative hierarchical algorithm is used to classify learners into groups with different levels of interactions. Additionally, we implement and evaluate multiple deep learning models for detecting different emotions from online discussions. Relevant emotion sequence patterns were identified using sequence pattern analysis and the identified emotion sequence patterns were compared across different groups with different levels of interactions.Results and ConclusionsUsing an agglomerative hierarchical algorithm, we classified learners into three distinct groups characterized by different levels of interactions: high, average and low level. Leveraging the bi‐directional long short‐term memory model for emotion detection yielded the highest predictive performance, with an impressive F‐measure of 94.01%, a recall rate of 93.83% and an accuracy score of 95.01%. The results also revealed that learners in the low‐level interaction group experienced more emotion transition from boredom to frustration than the other two groups. Therefore, the aggregation of students into groups and the utilization of their MOOC log data offer educators the capability to provide adaptive emotional feedback, customize assessments and offer more personalized attention as needed.