I am PsyAM: Modeling Happiness with Cognitive Appraisal Dimensions
Year: 2023

Abstract:
This paper proposes and evaluates PsyAM1, a framework that incorporates adaptor modules in a sequential multi-task learning setup to generate high-dimensional feature representations of hedonic well-being (momentary happiness) in terms of its psychological underpinnings. PsyAM models emotion in text through its cognitive antecedents, through auxiliary models that achieve multi-task learning through novel feature fusion methods. We show that BERT-PsyAM has cross-task validity and crossdomain generalizability through experiments with emotion-related tasks – on new emotion tasks and new datasets, as well as against traditional methods and BERT baselines. We further probe the robustness of BERT-PsyAM through feature ablation studies, as well as discuss the qualitative inferences we can draw regarding the effectiveness of the framework for representing emotional states. We close with a discussion of a future agenda of psychologyinspired neural network architectures.

heading: 1 Introduction
text: Governments are increasingly investing money into surveying and reporting nationwide psychological well-being as an indicator of success and wellness (Biswas-Diener et al., 2004), and some scholars have recommended monitoring social media for the unobtrusive measurement of regional trends in well-being and mental health. People are increasingly willing to post messages on social media to express their feelings. Words relate to emotions because they reflect how humans perceive their surroundings and ongoing events (Pennebaker et al., 2003); therefore, it is not surprising that language models trained on social media posts offer predictive insights into emotions. Emotions are an indicator of psychological states, such as happiness – the feelings of well-being related to momentary
1https://github.com/stephenlaw30/BERT-PsyAM
happiness or pleasure (Huta, 2016; Ryan and Deci, 2001).
Cognitive appraisal theory (CAT) posits that emotions result from how individuals appraise their situation and its impact on their wellbeing (Lazarus et al., 1980). CAT can model individual differences in emotional expressions; for instance, individuals may express happiness both, during a solitary walk as well as when they spend time with close friends if their core needs, drives, or motivations are suitably fulfilled. Therefore, we propose that relying on the stable cognitive antecedents of emotions could help us to train models that improve the state-of-the-art predictive accuracy for emotions detection tasks, and generalize more readily to other problems that infer psychological states from language, such as hedonic well-being.
In this work, we test a broad proposition that pretraining on cognitive auxiliary tasks improves emotion detection from text. This approach can bridge prior research in emotions classification with the increasing understanding of the link between selfexpression and psychology. We offer the following contributions:
• New framework: We introduce PsyAM - a framework of Psychological Adapter Modules2 for emotion modeling that learns cognitive appraisal dimensions as auxiliary tasks that inform learning for a primary task. • New tasks: We show that PsyAM (with BERT) improves over standard approaches in crossvalidation and replication on new messagelevel data for predicting the duration of experienced happiness, and on user-level data for predicting the in-person emotional variance associated with their subjective well-being. • Standard evaluation: We show that PsyAM (with BERT) outperforms the state-of-the-art
2Code and data is at https://github.com/stephenlaw30/BERT-PsyAM
1192
in cross-domain validation on standard tasks for detecting emotion in binary- and multiclass settings. • Real-world application: We demonstrate how PsyAM can offer real-world applications in predicting social media users’ well-being through their Twitter posts. • New annotated datasets: We have collected and annotated new happiness datasets from two nationally representative online surveys to validate our on new data and a real-world application.
Our work also offers a reality check to consider how leaderboard scores in emotion analysis translate to the real-world application of psycholinguistic models for unobtrusive mental health aggregates of communities. Recent studies have raised concerns about pre-trained psycholinguistic models’ cross-domain and cross-task validity beyond simple emotion detection. Many word-trait relationships, such as that of self-referential language use and depression (Tackman et al., 2019), or the of social words and extraversion (Chen et al., 2020), inexplicably break down in different communicative contexts. We believe this is because of overfitting models to training corpora and the lack of psychologically motivated machine learning architectures. Prior work also often does not theorize why words relate to emotions or traits in the first place. Consequently, it has been challenging to build research depth in the representational modeling of the psychology of emotions and develop sophisticated neural network models. Herein lies an opportunity for social impact, as appropriately modeling and spatially aggregating emotions in social media make it possible to monitor mental health on a large scale (Dodds et al., 2015).

heading: 2 Background
text: Previous studies exploring the psycholinguistics of text have evaluated text classification approaches that can best correspond to the psychological measurements of different psychological traits and states (Turc et al., 2019; Guda et al., 2021; Guntuku et al., 2019). For instance, Buechel et al. (2018) elaborates on the psychological complexity of human reactions such as empathy and distress by annotating text data with the empathy assessments of their authors via multi-item scales and considering psychological tenets to be co-existent rather than correlated (Buechel et al., 2018).
In this study, we additionally offer two new tasks: predicting the duration of happiness and its fluctuation from linguistic expression. Both these concepts are grounded in psychology literature, where they are known to provide into emotional stability and well-being. Unlike a simple emotion detection task, the duration of happiness relates to distinguishing transient moods from persisting states of emotional well-being (Biswas-Diener et al., 2004). Therefore, it may require a more sophisticated representation of text semantics than one driven by affective words alone. Given that our primary datasets comprise textual descriptions of happy moments, the focus on hedonia is only appropriate. Secondly, emotional fluctuation has garnered a lot of recent interest as a more stable and tractable predictor of mental health as compared to mean-based emotion-based predictors, which are less sensitive to deviations and therefore to indicators of mental health issues. Emotional fluctuations expressed in verbal or written expressions has been evaluated for its relationship with within-person fluctuations in other personality states, including affective states (Sun et al., 2020; Golder and Macy, 2011), emotional experience (Back et al., 2010) and wellbeing (Pennebaker et al., 2003). In more recent work, emotional variance in social media posts has been also found to predict emotionally straining situations (Seraj et al., 2021), and daily emotional well-being (Lades et al., 2020).
We suggest that reorienting the understanding of emotions in text in its cognitive antecedents may offer a fruitful approach to its modeling, detection, and real-world application. We choose two cognitive constructs which, according to prior research, are often key to emotional appraisal (Ellsworth and Scherer, 2003; Karasawa, 1995; Moors, 2010). First, Agency reflects the role and accountability of an individual in a situation. Second, Social Interaction reflects the relationship of an individual with others in the situation (family, friends, or peers). Among many other appraisal dimensions, we find that agency and social interaction have also been explored in other perspectives on understanding how humans appraise happiness (Paulhus and Trapnell, 2008). These concepts were also applied to enrich the CLAff-HappyDB happiness dataset in Jaidka et al. (2020), but our work offers the first instance of applying them for the computational modeling of happiness. Furthermore, we extend the central premise of the authors to explore and model the
duration of happiness. Our choice of modeling the cognitive antecedents of emotions found no match in prior work.3 Firstly, representing emotion at different semantic levels of abstraction, such as word embeddings (Bengio et al., 2000; Mikolov et al., 2013; Htait and Azzopardi, 2021), phrase- and sentencelevel representations (Socher et al., 2013), or even paragraph-(Le and Mikolov, 2014) and documentlevel (Tang et al., 2015) representations involve evoked emotion rather than grounded emotion (Picard, 2000; Liu et al., 2017). Secondly, while finetuned LLMs like BERT offer state-of-the-art performance in emotion prediction, they are harder to adapt to multi-task learning problems. A finetuned BERT is also not ideal for knowledge transfer between multiple tasks. For instance, if we finetune BERT for n emotions, then we will need n times parameters inside BERT(n*110M), which would incur a huge memory overhead. Furthermore, our goal is to let different psychological tasks interact with the emotion task in the latent semantic space, which would necessitate re-engineering the end-toend finetuning pipeline. These considerations made us opt for interactive adaptor modules with fewer parameters.

heading: 3 Methods
text: PsyAM is a broad proposition which can generalize to other frameworks. We chose to design our experiments centered on PsyAM coupled with BERT (BERT-PsyAM), which offers the best and most
3We offer a more exhaustive discussion of related work in the Appendix.
challenging opportunity to evaluate our claim in the high-dimensional space. This section defines and discusses our multi-task learning architecture (Figure 1), learning strategy, and the latent representations of appraisal dimensions.4 In the rest of the paper, we have referred to the appraisal dimensions more generally as psychological constructs, and the adapter modules as psychological adaptor modules to suggest that the framework could generalize to include other kinds of cognitive and psychological antecedents of emotions.

heading: 3.1 BERT-PsyAM Architecture
text: In the BERT-PsyAM architecture for multi-task sequential learning of psychological constructs and emotion labels, we extended each BERT layer by attaching a Psychological Adaptor Module (PsyAM) in parallel, as seen in Figure 1.5
A PsyAM consists of trainable encoder-decoder weights along with multi-head attention and is instantiated uniquely for each psychological or emotional label. A PsyAM considers the activation state of the previous layer of BERT as its input. Further, the output of a PsyAM decoder is subject to recombination with the BERT layer as the residual connection and then serves as the input for the next BERT layer. The stack of PsyAMs is trained on the task of Psychological or Emotional Label Classification by attaching a unique classification head to the last layer of BERT-PsyAM.
PsyAM offers two innovations. First, for a
4https://github.com/stephenlaw30/BERT-PsyAM 5A detailed description of all of the PsyAM components is
reported in the Appendix.
deeper semantic understanding of the data, we designed auxiliary tasks to aid the predictive performance of the primary classification task in a sequential learning approach. Prior work offers a simplistic implementation of auxiliary pre-training (Mahmoud and Torki, 2020) through auxiliary contexts in a similarity detection task. Instead, we extend the auxiliary pre-training architecture with multitask learning (Fifty, 2021), which aims to learn multiple different tasks simultaneously. Therefore, we are able to pre-train on auxiliary tasks that are not mutually exclusive, such as the cognitive appraisal dimensions underlying an emotional expression. Incorporating auxiliary pretraining has shown a performance improvement over the BERT models finetuned on individual tasks in prior work (Yu et al., 2019; Mahmoud and Torki, 2020), and we cororoborate these reports with similar findings in our paper.
We use adaptor modules for extracting latent semantic features from the text. The original idea of adaptor modules (Rebuffi et al., 2018) comes from the ResNet concept of residual connection in computer vision and it is a type of ensemble learning approach that can help overcome degradation problems in machine learning. The idea was adopted for natural language processing by Houlsby et al. (2019), who used an unfrozen encoder-decoder structure between the feedforward network and the Layer Norm operation while freezing the parameters of the original BERT layers, which has the effect of reducing the number of parameters to be finetuned but with a performance trade-off. Building on their idea,Stickland and Murray (2019) also incorporated attention mechanisms in adaptor modules. Herein lies our second innovation, as what we do is that in fusing latent features, we did not directly combine the encodings of text and numerical features as is typical in multimodal transformers, which could result in performance degradation due to dimensionality reduction. Instead, we generate a higher-dimensional feature representation with a layer-by-layer propagation rather than simply completing the splicing at the output and evaluate the effect of different fusion methods on the final predictive performance.
In summary, while the common way to use BERT for multiclass classification is to freeze the parameters of the original BERT and add several classification heads at the same level to fine-tune the parameters of the last layer to achieve multi-
classification; however, because BERT’s overall model parameters are fixed, finetuning in this manner often cannot achieve the best results, which would imply its inability to achieve optimal performance in every single classification task. Therefore, in the present architecture we assume that the internal parameters of BERT are not frozen. Furthermore, in BERT-PsyAM, we have replaced the original BERT Layer for fine-tuning with a small number of other parameters, so this is a great way for us to optimize processing with reduced overload.

heading: 4 Experiments
text: Our experiments address the question, How well do the psychological constructs of agency and social interaction aid an understanding of emotions and well-being? We evaluate the BERT-PsyAM framework on 5 different settings based on happiness, emotions, and well-being datasets. Through extensive experiments, we show how different variants of the BERT-PsyAM framework compares favorably to other approaches. With an ablation study and qualitative exploration, we reiterate the critical role of cognitive appraisal in well-being and emotion prediction tasks.

heading: 4.1 Task Settings and Datasets

heading: 4.1.1 Duration of Happiness task
text: Departing from typical emotion prediction tasks, we considered whether psychology labels could provide a deeper view into predicting the duration of happiness, a measure with immediate implications for understanding and modeling hedonic wellbeing (Biswas-Diener et al., 2004). The duration task was formulated as a binary classification problem that distinguished transient from more longlasting feelings of happiness, on three datasets, with label distributions reported in Table 1:6.
• CLAff-HappyDB: For training, testing, and internal validation, we relied on its 27,697 observations annotated with agency and social interaction labels (Jaidka et al., 2019). • HappyDB-expand: The analysis was replicated on 59,664 further descriptions of happy moments (Asai et al., 2018) which constituted the superset of CLAff-HappyDB labeled through a semi-supervised approach.7
61 = “All day, I’m still feeling it” and 0 = “A few moments,” “A few minutes, ” “At least one hour,” and “Half a day”
7Labeling for Agency and Social Interactions was done

heading: 4.1.2 Emotion detection tasks
text: We evaluated the generalizability of PsyAM for binary emotion classification and multi-category classification task, on two popular industry benchmarks. Recent studies suggest that many affordances of Reddit make it imminently suitable for understanding and modeling individuals’ physical and mental health (Wanchoo et al., 2023; Liu et al., 2023), including but not limited to self-disclosure and social interaction (Yang et al., 2017; Jaidka et al., 2019; Yang et al., 2019), both of which offer signals of agency and social interaction respectively.
• Kaggle SA-Emotions: We used the Kaggle SA-Emotions dataset8 comprising 20,266 observations. We generated agency and social labels and subsequently predicted the Joy labels in a cross-validation setup. • GoEmotions dataset: The GoEmotions dataset (Demszky et al., 2020) has finegrained emotion labels on 58k datapoints from Reddit, from which we sampled a balanced dataset of 14,589 datapoints with 7907 having a positive label of ’Joy’. We followed the same semi-supervised labeling and binary classification setup as the SA-Emotions task.
The label distributions for the two emotion datasets are reported in Table 2 and Figure 2.
using the best-performing BERT-PsyAM classifiers trained on CLAff-HappyDB. Classification accuracies are reported in the Appendix.
8https://www.kaggle.com/c/sa-emotions

heading: 4.1.3 Well-being prediction task
text: We also introduce the TwitterUsers-2021 dataset to evaluate the real-world application of PsyAM to predict user-level subjective-wellbeing. The dataset comprises 217,910 tweets posted by 296 internet users recruited through Qualtrics, who took part in an online survey experiment and shared the link to their Twitter profiles.9 We used the Twitter API to collect the social media posts of the 337 legitimate Twitter users who had participated in the survey and shared their Twitter handles. Of these, 296 participants had legitimate accounts and had posted at least one tweet of 50 characters or more that was not a retweet. As before, we used weakly supervised methods to generate Agency and Social Interaction labels for each post. Subsequently, we used BERT-PsyAM to generate labels for the duration of happy moments, which we used to derive an Emotional Fluctuation variable corresponding to the within-person variance in the happiness scores.

heading: 4.2 Experiments
text: We performed the following experiments to test and validate the BERT-PsyAM framework:
• Cross-validation: The CLAff-HappyDB dataset with an 80-10-10 split is used for internal validation for the duration task. • Replication analysis: Experiments are replicated on the HappyDB-expand dataset and the HappyDB-2021 datasets, which constitute held-out data and data from a different cultural context.
9Participant demographics are reported in the Appendix.
included other contextual information (e.g. the reflection period) and respondent demographics (their marital status, which would affect their psychological outlook (Diener et al., 2000)).10 • Model visualization: We applied the Captum toolkit (Kokhlikyan et al., 2020) to visualize the impact of individual words on the classification confidence score for the duration task. Captum calculates the layer integrated gradient on the test cases input through BERTPsyAM with post-linear feature fusion. We then compared word attributions from token embeddings by a BERT-finetuned vs. a BERTPsyAM model. • Real-world application: We evaluated the predictive performance of Bert-PsyAM on user-level subjective well-being prediction based on duration of happiness scores generated on their Twitter posts.

heading: 4.3 Model Setup
text: We adapted the PyTorch BERT-base-uncased as our backbone, initialized with pre-trained weights. Our implementation comprises 12 layers, 12 attention heads and 768 as the hidden unit size. We modeled psychological constructs (agency, social) prediction as a binary classification task. We set the augmentation size a to be 204. We trained for each task with the AdamW optimizer (Loshchilov and Hutter, 2019) for 3 epochs, with a batch size of 32, a learning rate of 3e-5, and a maximum sequence length of 128 tokens.
We have compared the BERT-PsyAM framework against traditional and BERT-based methods.
10These experiments were conducted on the primary task and dataset with post-linear feature fusion.
Traditional methods adopt the pre-trained word embeddings (Mikolov et al., 2018) and the bagof-words model to generate the sequence representation which is passed to classifiers: Gaussian Naive Bayes (Gaussian-NB) and Multi-layer Perceptron classifier (MLP-classifier). In order to compare role of different representation of psychological features, we made a baseline called MLPclassifier+A+S which embeds agency and social information into the input of MLP-classifier with numerical features. Since BERT-PsyAM is constructed with a BERT backbone, BERT-Finetune and BERT-NPALS (Stickland and Murray, 2019) offer the ideal baselines to illustrate performance improvements.

heading: 5 Results & Analysis
text: As seen in Table 3, first, in the internal crossvalidation, BERT-PsyAM with the linear posttraining fusion strategy is the best performed model in the internal validation by surpassing baselines 1.5% in accuracy and nearly 2% in both ROC and F-1 in repeated iterations (Accuracy = 72.13 vs. 70.87; ROC = 77.41 vs. 75.64, p < 0.05). Next, in the replication analysis reported for HappyDBexpand, we see similar improvements as above (Accuracy = 72.75 vs. 71.54; ROC = 77.47 vs 76.19, p < 0.05), illustrating its robustness and general ability that leverages pre-trained models. Finally, the performance on HappyDB-2021 (Accuracy = 72.08 vs. 71.31; ROC = 77.27 vs 76.83, p < 0.05) suggests that the model also generalizes well to new cultural contexts.

heading: 5.1 External validation
text: Tables 4 and 5 and Table shows PsyAM’s performance at emotion classification. For SA-Emotions, in the binary classification task, BERT-PsyAM with pre-training feature fusion has the highest Accuracy and ROC that are statistically significantly higher than BERT-PALS by about 1% each in repeated runs (Accuracy = 85.35 vs 84.51; ROC = 89.90 vs. 89.32, p < 0.05), while for GoEmotions the postlinear feature fusion has the better performance. BERT-PsyAM also outperforms BERT-PALS in multi-task prediction by about 3% (Accuracy = 71.90 vs 68.91; ROC = 39.39 vs. 36.72, p < 0.05), suggesting that our framework has generalized well to new tasks, datasets, and emotions.
As seen in Table 6, adding both psychological constructs considerably improves over BERT-
finetune (ROC = 77.41 vs. 75.64). We also found that the performance increased further with the addition of a third adapter module related to emotional transience (Asai et al., 2018) - the reflection period (ROC = 77.67 vs 75.64).

heading: 5.2 Model visualization
text: Figure 3 reports a confusion matrix of classifications by BERT-FT reported in Table 3 vs. BERTPsyAM on CLAff-HappyDB data. Across the four quadrants, BERT-FT does attribute importance to emotion words such as ‘anniversary’ and ‘special,’ but also to irrelevant words such as ‘to,’ and ‘it’s’, confirming recent findings regarding BERT (Hayati et al., 2021). In contrast, BERT-PsyAM generates higher confidence scores and appears to pay attention to first person and possessive pronouns that denote agency (Rouhizadeh et al., 2018) (‘me’ and ‘my’), and social relationships and interactions (Jaidka et al., 2020) (‘husband’ and ‘daughter’; ‘we’ and ‘our’).

heading: 5.3 Real-world application
text: In Figure 4 (a), we demonstrate whether labels generated using PsyAM offer any psychological insights for real-world applications. In a regression analysis that predicts subjective wellbeing, after controlling for demographic covariates, higher emotional fluctuation scores based on BERT-PsyAM predictions predict lower wellbeing, a relationship which corroborates prior work in psychology (Seraj et al., 2021). The value of the coefficients suggests that a 1% decrease in emotional fluctuation predicts a 0.04% increase in the subjective well-being of an individual, or a magnitude of 0.4 points on a 10-point scale. Although the predicted R2 values are low, this is typical of models that use linguistic covariates to predict psychological traits (Boyd and Pennebaker, 2017). In Figure 4(b), We examined the interactive effect of age on this relationship and find that the interactive effect of age and emotional fluctuation is significant (and negative) among 18-34 year olds.

heading: 6 Discussion
text: Our findings offer the following insights towards a future agenda of neural networks inspired by human psychology:
• Feature-rich representation: PsyAM appears to help BERT pay more attention to words reflecting cognitive constructs, such as words
referencing the self, family members, and social activities, as seen in Figure 3. • Operational flexibility: Within PsyAM, different feature fusion methods had the best performance, suggesting that contextual and dataset differences can be accounted for through minor adjustments of the PsyAM framework. • Robust predictions: PsyAM works well with a variety of datasets, cultural contexts, and even tasks. Even when the label distribution differs from the original, the superior performance of PsyAM models signals that our architecture is robust to new data. • Semi-supervised extensions: Labeling existing datasets with models finetuned on small annotated datasets offers a low-cost alternative to obtaining high-quality annotations. This is
the approach we used, as reported in Table 8 of the Appendix, and the predictions have face-validity, as reported in Figure 3. • Cognitive construct extensions: Other cognitive constructs, such as reflection period, can offer additional measures of cognitive complexity to further improve the modeling of emotional expression.

heading: 7 Conclusion
text: The main advantage of the BERT-PsyAM framework is a modeling paradigm that transfers to new domains and tasks for detecting emotions and, by extension, well-being. Psychologists can use PsyAM to build and test new hypotheses about selfexpression, cognitive appraisal, and behavior. It could also be helpful in interventionist scenarios requiring live monitoring and reporting problematic social media posts.
PsyAM achieved substantive improvements over the state-of-the-art BERT alternatives, and we show that this is because of the contribution of the high-dimensional feature representation inside the Adaptor Modules. Different feature fusion methods achieved different degrees of improvement in different settings, and different latent variables may add value in different problem contexts.
Future directions: We have released the labeled datasets developed as part of the study for researchers to explore further how psychological traits and states can inspire better neural architectures for text classification. We plan to explore other appraisal dimensions, such as goal conduciveness and certainty, as well as individual differences through demographic and personality traits.
Limitations: The duration task focused only on data with a positive happiness label, but it would be interesting to see whether the framework generalizes to a complete dataset and more sophisticated problem definitions. The need for annotations limits the generalizability of our approach, but the BERT-PsyAM framework is effective even with labels generated through semi-supervised methods and other metadata.
Ethical considerations: The models are intended for aggregate- and group-level inferences, and not individual or message-level inferences. Despite our cross-domain validation efforts, we caution that relying exclusively on AI-inferred relationships between emotion, self-efficacy, and selfdetermination may lead to inaccurate measure-
ments. Finally, models trained in a specific sociocultural setting may nevertheless violate the social conventions in specific settings, such as in the workplace, and cultural conventions of individualism and collectivism in social life (Diener et al., 2009).
Acknowledgments: We thank Niyati Chhaya, Chaitanya Aggarwal, and Gerard Yeo for feedback on early versions of this work. This work was supported by an NUS CTIC grant and a Nanyang Presidential Postdoctoral fellowship.

heading: A Appendix
text: A.1 Background Psychological constructs including but not limited to empathy, distress, agency, social affinity have been widely studied by computational linguists (Turc et al., 2019; Guda et al., 2021; Rouhizadeh et al., 2018; Guntuku et al., 2019). Such studies, primarily, evaluate representational learning approaches for downstream tasks to predict the appropriate psychological constructs associated with the given text. For instance, Buechel et al. (2018) elaborates on the psychological complexity of human reactions such as empathy and distress, by annotating text data with the empathy assessments of their authors via multi-item scales. Even this study considered empathy and distress to be co-existent rather than correlated, offering little insight into the role of cognitive appraisals as the wellspring of emotional expression (Omdahl, 2014; Hoffner and Lee, 2015). We formulate our problem as the multi-task learning of psychological states in tandem with human emotions, which offers insight into the role of psychological self-appraisals as the wellspring of emotional expression (Luo and Hancock, 2020; Omdahl, 2014; Hoffner and Lee, 2015). In the following paragraphs, we first motivate the problem of modeling emotion in terms of its psychological underpinnings, followed by a review of
the literature on multitask learning and language modeling that is relevant to our context.
A.2 State of the art in emotion prediction
Emotion in text has been modeled in different studies at different levels of abstraction and meaning, such as sentiment-specific word embeddings (Bengio et al., 2000; Mikolov et al., 2013; Htait and Azzopardi, 2021), phrase- and sentence-level representations (Socher et al., 2013), and even at the paragraph-(Le and Mikolov, 2014) and documentlevel (Tang et al., 2015). Note that these approaches appear to conflate the detection of expressed versus evoked emotion (Picard, 2000), as they tend further and further away from the root of emotion (Liu et al., 2017). We suggest that grounding the emotion prediction task in its cognitive antecedents, similar to prior work focusing on its causes (Poria et al., 2021), may offer a fruitful approach to its modeling and detection.
In studies with a temporal component, LongShort Term Memory (LSTM) architectures and Gated Neural Networks have been used successfully; however, they often fall short of transformerbased models in tasks involving language understanding, such as emotion prediction. Therefore, given the stability and universality of transformerbased models, and the ability to benchmark against previous work and datasets, we opted to use the BERT model as the backbone for our experiments. BERT (Devlin et al., 2018) is a pre-training language model with two self- supervised pretraining objectives: masked language modeling (MLM) and next sentence prediction (NSP). The NSP task in pre-training is used to fine-tune the model using labeled data in order to obtain the prediction result. Although a finetuned BERT model is known to achieve good results in emotion prediction, it is not suitable for our purpose for two reasons. Firstly, a finetuned BERT is not ideal for knowledge transfer between multiple tasks. For instance, if we finetune BERT for n emotions, then we will need n*110M parameters, which would incur a huge memory overhead. Secondly, our goal is to let different psychological tasks interact with the emotion task at the semantic latent space, which implied that finetuned models would not meet our requirements. These considerations made us opt for an interactive module with fewer parameters.
A.3 Multi-task learning
A multi-task learning setup aims to learn multiple different tasks simultaneously. This can be thought of as predicting attributes of text that are not mutually exclusive, such as the psychological and emotional facets of the memory of a happy moment. In multi-task learning, more than one loss function is trained, or a part of the loss function comes from a different task, with the expectation that the model will apply the information it learns during training on one task to decrease the loss on other tasks included in training the network (Fifty, 2021). The initial proposal of adaptor modules for natural language processing by Houlsby (Houlsby et al., 2019) offered an end-to-end structure which offers finetuning parameters while employing fewer parameters than the entire BERT, but with a degraded final performance. However, their final performance was slightly worse than the whole BERT finetune model while reducing the number of parameters that must be fine-tuned.
The BERT-PsyAM architecture proposed in this study adapts the BERT and PALS architecture (Stickland and Murray, 2019) which included projected attention layers, as parts within the adaptor module. This constitutes an ensemble approach which is then used for the sequential training of psychological states and emotions. Our approach is novel in three ways: firstly, instead of using adaptors for parameter minimization, we use them to extract latent semantic features with the multi-head attention mechanism and feedforward layers. Secondly, instead of adding attention outputs, we use residual connections to combine the latent semantic features between tasks. This allows different tasks to interact and support each other with highdimensional (context-psychology) feature representations. In this paper, we have evaluated three different methods for feature fusion, all of which perform well. Thirdly, in the process of fusing latent features, we did not directly combine the encodings of text and numerical features as is typical in multimodal transformers, which could result in signal losses due to dimensionality reduction. Instead, we generate a higher-dimensional (context & psychology) feature representation with a layer-bylayer propagation rather than simply completing the splicing at output.
A.4 Context
Now that we have motivated our architecture, we will explain the theoretical concepts it realizes. This study focuses on the psychological concepts that are meaningful in the understanding of emotion – specifically, in understanding happiness. Psychologists define agency as the feeling of being in control of one’s life. It is related to the ideas of autonomy (Tay and Diener, 2011), and self efficacy (Deci and Ryan, 2000), which are known to have a strong relationship with personal health and well-being (Lachman and Weaver, 1998). Moreover, its linguistic correlates have been examined in prior work (Rouhizadeh et al., 2018). On the other hand, social interaction and feeling connected to others are also central to well-being (Helliwell and Putnam, 2004), the feeling of belongingness (Sandstrom and Dunn, 2014), and happiness (Epley and Schroeder, 2014).
The association of agency and social interaction in textual descriptions of happy moments was explored in the The CLAff-HappyDB Shared Task models happy moments in terms of their agency and social interaction (Jaidka et al., 2019). The Task proposes that a happy moment may involve either agency and social interaction, both, or neither of these; however, their interplay could be helpful for an enriched understanding of happiness. However, the labeled dataset was small in size, limiting the possibilities for technical and conceptual follow-up work. In this study, we have used semisupervised approaches to expand on the training data, collected new data, and tested our approach on standard emotion detection tasks on a well-known emotion dataset.

heading: B BERT-PsyAM architecture
text: B.0.1 BERT Layer Figure 1 illustrates how a BERT layer receives the activation state of the previous BERT layer as input, and generates dh dimensional hidden states for each token in the sequence, which are forwarded to the BERT attention and the feedforward network.
Multi-Head Attention: N different attention heads11 are applied to extract the attention score on tokens as the aggregate of previous hidden states.
Rescale: This sub-module splices and re-scales the feature space to make it more suitable for the task in context. It does so by calculating the mean
11We have used N = 12
µ and variance σ of each unit in the input vector x, and then re-scaling them by learning a gain g and bias b parameter sequentially.
Feed-forward Networks (FFN) Next, an FFN framework containing two linear transformations with a GELU activation function (Hendrycks and Gimpel, 2016) is applied to each position of hidden states by transforming them to a high-dimensional space and then transforming them back. Here we add BAN , the residual part we got from the multihead attention setup, which gives us the final BERTPsyAM layer output as:
Layer_output = Rescale(FFN(BAN (x))+ BAN (x) + PsyAM(x)) (1)
The PsyAM(x) component of Equation 1 is explained in the following paragraphs.
B.0.2 Adaptor Modules There are two types of Adaptor Modules: psychological constructs adaptor modules (PCAM) and emotion adaptor modules (EAM), connected through a hierarchical bottom-up structure to ensure the dependency of emotion on psychological constructs. PCAM. PCAMs consider the activation weights of the previous layer of BERT as the input. The activation weights are Xdi where, (a) d represents the dimensionality of the hidden states transmitted between each layer of BERT, and (b) i represents the layer number. The encoder inside, essentially, augments the dimensionality of the input to a which helps retrieve latent features specific to the psychological context:
Enc(Xdi ) = X d i A d∗a + ba (2)
We use a BERT Multi-Head Attention mechanism once again as the feature extractor, but reduce the number of heads to N/2 as it was achieving competitive performance with fewer parameters. We therefore obtain BAN/2(Enc(Xdi )). Next, we apply a Decoder to resize the augmented data to the original hidden size d of BERT.
Dec(BAN/2(Enc(X d i ))) = BAN/2(X d i )A a∗d + bd (3)
So, the output of PCAM is:
PCAM(Xdi ) = Dec(BAN/2(Enc(X d i ))) (4)
EAM EAM is the adaptor module for classification on emotion, which generates outputs for
PsyAM through one of three ways of feature fusion. First, pre-training fusion (pre) receives the last BERT layer’s output and all the features from PCAMs. It defines them as a list of features: [Xdi , PCAM1(X d i ), PCAM2(X d i )...]). Next, it concatenates all the features, then passes it into Encoder inside EAM. So the feature propagation through EAM with fusion occurring pre-training looks like:
pre(Xdi , PCAM1(X d i ), PCAM2(X d i )...) =
[Xdi , PCAM1(X d i ), PCAM2(X d i )...]
(5)
The output of residual from PsyAM is:
EAM(pre) = Dec(BAN/2(Enc(pre(X d i ,
PCAM1(X d i ), PCAM2(X d i )...))))
(6)
Alternatively, when pre-training feature fusion is disabled, the post-training feature fusion methods (post-linear and post-add) receive the EAM’s output and all the features from PCAMs, and then perform either an addition or a latent transformation of the concatenated features. The pooled output acts as the residual connection passed to the next BERT layer. In this case, the feature propagation through EAM looks like:
EAM(post− add) = Dec(BAN/2(Enc(Xdi )))+∑
j
PCAMj(X d i )
(7)
EAM(post− linear) = LinearTransform(D) (8)
D = post(Dec(BAN/2(Enc(X d i ))),
PCAM1(X d i ), PCAM2(X d i )...))
(9)
B.1 Training Approach After initializing the parameters for both BERT layers (pretrained BERT) and PsyAMs (Random), we train all of the psychological constructs tasks at the same time. Under the setting that (a) BERT layer parameters are frozen and (b) The EAM with feature fusion modules is disabled, these psychological constructs tasks contain their unique PCAM along with the BERT layer and classifier on the top, so they can be trained simultaneously without affecting the gradients of each other. Since feature fusion modules are disabled, inputs are directly propagated without transformation. Then the output of PCAM is passed to the output of BERT layer as residual:
Layer_output = Rescale(FFN(BAN (x))
+BAN (x) + PCAM(X d i ))
(10)
After finishing training on psychological constructs and to realize a hierarchical bottom-up structure, we adjust the following settings: (a) Start the emotion training through the PCAMs to ensure the dependency of EAM on PCAM, (b) Choose a feature fusion strategy for the EAM, and (c) Freeze the parameters in all PCAMs. The output of EAM is passed to the output of BERT-PsyAM layer as the residual:
Layer_output = Rescale(FFN(BAN (x))
+BAN (x) + EAM(X d i )))
(11)
For each task, the hidden states of the sequence input are transformed at each layer of BERT-PsyAM, but only the final hidden state of the [CLS] token is used for classification with the cross-entropy loss inside their unique classification head:
− M∑
c=1
yo,c log(po,c) (12)
where M is the number of classes, y is binary indicator (0 or 1), p is predicted probability observation o is of class c.

heading: C New datasets’ curation and annotation
text: HappyDB-2021 was collected through a Qualtrics Singapore panel sampled to obtain a gender- and age-representative split in terms of age and gender. Following the original data collection procedure, first we collected happy moments from survey respondents12, together with their self reported duration of experiencing happiness. Participants were asked about three happy moments they experienced recently. Besides the happy moment, participants were also asked about the duration (i.e., the length) of happiness they experienced. The detailed instructions are sourced from (Asai et al., 2018) and are reported in Figure 5(a). Participants came from a representative distribution of gender (51.1% Female), age (M = 39.13; SD = 13.18), educational (Median = undergraduate degree), economic (Median = $7000 to $8999 monthly income), and racial backgrounds (83% majority). 984 happy moments thus collected were annotated through Amazon Mechanical Turk annotators, as reported in the next subsection.
TwitterUsers-2021 was collected from a Qualtrics USA panel sampled to obtain a nationally
12The survey protocol for both surveys was approved by our university’s Institutional Review Board.
representative split in terms of age and gender. As a part of a larger survey, they were asked to share their Twitter handles and answer the Cantril Ladder question: “Think of a ladder, with the best possible life for you being a 10 and the worst possible life being a 0. Rate your own current life on that 0 to 10 scale.” They also shared basic demographic information, such as their age, sex, level of education, and income. The detailed participant demographics are reported in Table 7.
A sample of 1000 happy moments from HappyDB2021 was published as an Amazon Mechanical Task to get five annotations per moment, to obtain annotations for agency and social interaction, following the same instructions as the original CLAffHappyDB task. Annotators looked for evidence of:
• Personal agency: Describing whether or not the author was directly responsible for the happy moment that occurred. Example: “I made a nice birthday cake today.”
• Social Interaction: Indicating whether or not other the happy moment involved other people. Example: “I had a good lunch with my mom.”
The detailed annotator instructions are sourced
from (Jaidka et al., 2019) and are reported in Figure 5(b).
C.2 Semi-supervised labeling We used a semi-supervised approach to annotate HappyDB-expand and the Kaggle Emotion datasets with Agency and Social Interaction labels with the help of the best-performing BERT-PsyAM classifiers trained on CLAff-HappyDB. By loading the pretrained parameters of Agency and Social taskspecified psychological constructs adaptor modules(PCAMS), the BERT-PsyAM can easily predict psychological constructs labels. Furthermore, they can be applied to the main task of fine-tuning emotion classification in HappyDB-expand and the Kaggle Emotion datasets settings. Classification accuracies are reported in Table 8.
ACL 2023 Responsible NLP Checklist

heading: A For every submission:
text: 3 A1. Did you describe the limitations of your work?
Yes, in the Conclusion
3 A2. Did you discuss any potential risks of your work? Yes, in the Conclusion
3 A3. Do the abstract and introduction summarize the paper’s main claims? Left blank.
7 A4. Have you used AI writing assistants when working on this paper? Left blank.
B 3 Did you use or create scientific artifacts? Yes, Section 4
3 B1. Did you cite the creators of artifacts you used? Yes, Section 4
3 B2. Did you discuss the license or terms for use and / or distribution of any artifacts? We have included the link to the data repository where no PII is included.
3 B3. Did you discuss if your use of existing artifact(s) was consistent with their intended use, provided that it was specified? For the artifacts you create, do you specify intended use and whether that is compatible with the original access conditions (in particular, derivatives of data accessed for research purposes should not be used outside of research contexts)? Yes, in the Conclusion
B4. Did you discuss the steps taken to check whether the data that was collected / used contains any information that names or uniquely identifies individual people or offensive content, and the steps taken to protect / anonymize it? Not applicable. Left blank.
3 B5. Did you provide documentation of the artifacts, e.g., coverage of domains, languages, and linguistic phenomena, demographic groups represented, etc.? Yes, in the Appendix
3 B6. Did you report relevant statistics like the number of examples, details of train / test / dev splits, etc. for the data that you used / created? Even for commonly-used benchmark datasets, include the number of examples in train / validation / test splits, as these provide necessary context for a reader to understand experimental results. For example, small differences in accuracy on large test sets may be significant, while on small test sets they may not be. Yes, in Section 4 and in the Appendix
C 3 Did you run computational experiments? Yes, in Section 4 and 5
3 C1. Did you report the number of parameters in the models used, the total computational budget (e.g., GPU hours), and computing infrastructure used? Yes, in Section 4 and 5
The Responsible NLP Checklist used at ACL 2023 is adopted from NAACL 2022, with the addition of a question on AI writing assistance.
3 C2. Did you discuss the experimental setup, including hyperparameter search and best-found hyperparameter values? Yes, in Section 4 and 5
3 C3. Did you report descriptive statistics about your results (e.g., error bars around results, summary statistics from sets of experiments), and is it transparent whether you are reporting the max, mean, etc. or just a single run? Yes, in Section 5
3 C4. If you used existing packages (e.g., for preprocessing, for normalization, or for evaluation), did you report the implementation, model, and parameter settings used (e.g., NLTK, Spacy, ROUGE, etc.)? Yes, in Section 4 and 5
D 3 Did you use human annotators (e.g., crowdworkers) or research with human participants? Yes in Section 4 and in the Appendix
3 D1. Did you report the full text of instructions given to participants, including e.g., screenshots, disclaimers of any risks to participants or annotators, etc.? Yes in the Appendix
3 D2. Did you report information about how you recruited (e.g., crowdsourcing platform, students) and paid participants, and discuss if such payment is adequate given the participants’ demographic (e.g., country of residence)? Yes in Section 4 and in the Appendix
3 D3. Did you discuss whether and how consent was obtained from people whose data you’re using/curating? For example, if you collected data via crowdsourcing, did your instructions to crowdworkers explain how the data would be used? Yes in the Appendix
3 D4. Was the data collection protocol approved (or determined exempt) by an ethics review board? Yes in Section 4 and in the Appendix
3 D5. Did you report the basic demographic and geographic characteristics of the annotator population that is the source of the data? Yes in Section 4 and in the Appendix

heading: Future Work
text: Future directions: We have released the labeled datasets developed as part of the study for researchers to explore further how psychological traits and states can inspire better neural architectures for text classification. We plan to explore other appraisal dimensions, such as goal conduciveness and certainty, as well as individual differences through demographic and personality traits. Limitations: The duration task focused only on data with a positive happiness label, but it would be interesting to see whether the framework generalizes to a complete dataset and more sophisticated problem definitions. The need for annotations limits the generalizability of our approach, but the BERT-PsyAM framework is effective even with labels generated through semi-supervised methods and other metadata. Ethical considerations: The models are intended for aggregate- and group-level inferences, and not individual or message-level inferences. Despite our cross-domain validation efforts, we caution that relying exclusively on AI-inferred relationships between emotion, self-efficacy, and selfdetermination may lead to inaccurate measure-
ments. Finally, models trained in a specific sociocultural setting may nevertheless violate the social conventions in specific settings, such as in the workplace, and cultural conventions of individualism and collectivism in social life (Diener et al. , 2009). Acknowledgments: We thank Niyati Chhaya, Chaitanya Aggarwal, and Gerard Yeo for feedback on early versions of this work. This work was supported by an NUS CTIC grant and a Nanyang Presidential Postdoctoral fellowship