Text Classification
Transformers
English
semeval
semeval-2026
emotion
affect-prediction
temporal-nlp
roberta
Instructions to use Haxxsh/AffectDynamics-SemEval2026Task2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Haxxsh/AffectDynamics-SemEval2026Task2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="Haxxsh/AffectDynamics-SemEval2026Task2")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("Haxxsh/AffectDynamics-SemEval2026Task2", dtype="auto") - Notebooks
- Google Colab
- Kaggle
Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,116 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: mit
|
| 3 |
+
language:
|
| 4 |
+
- en
|
| 5 |
+
library_name: pytorch
|
| 6 |
+
pipeline_tag: text-classification
|
| 7 |
+
base_model:
|
| 8 |
+
- roberta-large
|
| 9 |
+
tags:
|
| 10 |
+
- semeval
|
| 11 |
+
- semeval2026
|
| 12 |
+
- affective-computing
|
| 13 |
+
- emotion-regression
|
| 14 |
+
- valence-arousal
|
| 15 |
+
- temporal-modeling
|
| 16 |
+
datasets:
|
| 17 |
+
- semeval2026-task2
|
| 18 |
+
metrics:
|
| 19 |
+
- pearsonr
|
| 20 |
+
- r_within
|
| 21 |
+
- r_between
|
| 22 |
+
model-index:
|
| 23 |
+
- name: AffectDynamics-SemEval2026Task2
|
| 24 |
+
results:
|
| 25 |
+
- task:
|
| 26 |
+
type: text-classification
|
| 27 |
+
name: SemEval-2026 Task 2 (Composite)
|
| 28 |
+
dataset:
|
| 29 |
+
type: semeval2026-task2
|
| 30 |
+
name: SemEval-2026 Task 2 Validation Split
|
| 31 |
+
split: validation
|
| 32 |
+
metrics:
|
| 33 |
+
- type: r_composite
|
| 34 |
+
name: Composite Correlation
|
| 35 |
+
value: 0.6990
|
| 36 |
+
---
|
| 37 |
+
|
| 38 |
+
# AffectDynamics-SemEval2026Task2
|
| 39 |
+
|
| 40 |
+
This repository contains a correlation-optimized temporal affect model for **SemEval-2026 Task 2**: predicting **valence** and **arousal** dynamics from user-authored essays and feeling-word entries.
|
| 41 |
+
|
| 42 |
+
[](https://www.python.org/downloads/)
|
| 43 |
+
[](https://pytorch.org/)
|
| 44 |
+
[](https://lightning.ai/)
|
| 45 |
+
[](LICENSE)
|
| 46 |
+
|
| 47 |
+
## Model Card
|
| 48 |
+
|
| 49 |
+
### Model details
|
| 50 |
+
|
| 51 |
+
- **Model type**: Multi-task temporal regression (Subtask 1, 2A, 2B)
|
| 52 |
+
- **Backbone**: `roberta-large`
|
| 53 |
+
- **Temporal encoder**: 2-layer unidirectional GRU (hidden size 384)
|
| 54 |
+
- **Personalization**: Gated user embedding (24-dim)
|
| 55 |
+
- **Training objective**: Correlation-first, variance-aware losses aligned with task metrics
|
| 56 |
+
- **Primary checkpoint**: `best-epoch=14-val_r_composite_avg=0.6990.ckpt`
|
| 57 |
+
|
| 58 |
+
### Intended use
|
| 59 |
+
|
| 60 |
+
- Research use for longitudinal affect forecasting on SemEval-style data.
|
| 61 |
+
- Produces continuous predictions for:
|
| 62 |
+
- Subtask 1: `pred_valence`, `pred_arousal`
|
| 63 |
+
- Subtask 2A: `pred_state_change_valence`, `pred_state_change_arousal`
|
| 64 |
+
- Subtask 2B: `pred_dispo_change_valence`, `pred_dispo_change_arousal`
|
| 65 |
+
|
| 66 |
+
### Out-of-scope use
|
| 67 |
+
|
| 68 |
+
- Clinical diagnosis or mental health decision support.
|
| 69 |
+
- High-stakes individual-level decision making.
|
| 70 |
+
- Use on domains, languages, or demographics not represented in SemEval Task 2 data without re-validation.
|
| 71 |
+
|
| 72 |
+
### Training and evaluation data
|
| 73 |
+
|
| 74 |
+
- Source task: SemEval-2026 Task 2 (shared-task format).
|
| 75 |
+
- Training corpus in this repo includes:
|
| 76 |
+
- `data/train_subtask1.csv`
|
| 77 |
+
- `data/train_subtask2a.csv` (or computed from Subtask 1 timeline)
|
| 78 |
+
- `data/train_subtask2b_user_disposition_change.csv`
|
| 79 |
+
- Validation strategy: temporal per-user split to prevent future leakage.
|
| 80 |
+
|
| 81 |
+
### Metrics
|
| 82 |
+
|
| 83 |
+
- **Subtask 1**: `r_within`, `r_between`, `r_composite` (per SemEval evaluator)
|
| 84 |
+
- **Subtask 2A/2B**: Pearson correlation (`r`) on forecasting targets
|
| 85 |
+
- **Checkpoint selection signal**: `val_r_composite_avg`
|
| 86 |
+
|
| 87 |
+
### Quick start
|
| 88 |
+
|
| 89 |
+
Use the provided script to download the checkpoint and generate submission files:
|
| 90 |
+
|
| 91 |
+
```bash
|
| 92 |
+
python generate_submission.py
|
| 93 |
+
```
|
| 94 |
+
|
| 95 |
+
Or run local inference with custom inputs:
|
| 96 |
+
|
| 97 |
+
```bash
|
| 98 |
+
python predict.py
|
| 99 |
+
```
|
| 100 |
+
|
| 101 |
+
### Limitations and bias
|
| 102 |
+
|
| 103 |
+
- Performance depends on temporal history quality and per-user data sparsity.
|
| 104 |
+
- Arousal typically has lower correlation than valence due to lower target variance.
|
| 105 |
+
- Predictions are correlation-optimized for benchmark metrics and may require calibration for deployment settings.
|
| 106 |
+
|
| 107 |
+
### Citation
|
| 108 |
+
|
| 109 |
+
If you use this model, please cite the SemEval-2026 Task 2 shared task and this repository.
|
| 110 |
+
|
| 111 |
+
## 🎯 Task Overview
|
| 112 |
+
|
| 113 |
+
**Three interconnected subtasks:**
|
| 114 |
+
- **Subtask 1**: Longitudinal Affect Assessment - Predict valence/arousal for each text in a user's timeline
|
| 115 |
+
- **Subtask 2A**: State Change Detection - Predict short-term emotional shifts between consecutive texts
|
| 116 |
+
- **Subtask 2B**: Dispositional Change - Predict long-term changes in baseline emotional state
|