Humor Classification
Can predicted brain responses (via TRIBE v2) distinguish humorous from non-humorous text? A logistic regression classifier trained on brain activation patterns attempts to decode humor from neural representations.
Summary
TRIBE v2 predicted brain responses distinguish humorous from neutral text with 100% accuracy on a held-out test set (20 unseen stimuli, AUC 1.000). The classifier was trained on 80 stimuli using a Pipeline with StratifiedKFold cross-validation (92.5% CV accuracy, 0.969 AUC), then evaluated on 20 completely held-out stimuli — 10 jokes and 10 neutral facts it never trained on. Every single holdout stimulus was classified correctly. This strongly suggests that TRIBE v2 encodes humor-relevant neural processing, including incongruity detection and reward signaling, in its predicted brain patterns — and that this signal generalizes robustly to unseen text.
Key metrics
Holdout Acc
100%
Accuracy on 20 held-out stimuli (10+10)
Holdout AUC
1.0
ROC AUC on holdout set — perfect
CV Accuracy
92.5%
5-fold StratifiedKFold on 80 training stimuli
CV AUC
0.969
ROC AUC on Pipeline CV
Train
80.0
40 humor + 40 neutral for training
Holdout
20.0
10 humor + 10 neutral held out
Features
20,484
Cortical vertices per sample
Regularization
L1 (C=1.0)
SAGA solver, lasso penalty
Confusion matrix
Actual
Predicted
Classification report
| Class | Precision | Recall | F1 | Support |
|---|---|---|---|---|
| Neutral | 1.00 | 1.00 | 1.00 | 10 |
| Humor | 1.00 | 1.00 | 1.00 | 10 |
| Macro avg | 1.00 | 1.00 | 1.00 | 20 |
PCA projection
PC1 (39.7% var)
PC2 (23.9% var)
Discriminative brain regions
98.1%
390 / 20,484
Humor-predictive
Neutral-predictive
Regions identified via L1-regularized logistic regression weights mapped onto the Destrieux cortical atlas (fsaverage5). Percentages reflect each region's share of total cortical weight for its category (excluding medial wall vertices).
Interested in what these regions mean? Read the full discussion — a region-by-region analysis comparing these findings to published neuroscience literature.
Figures

Holdout confusion matrix — Unseen stimuli
Perfect classification on 20 held-out stimuli (10 humor + 10 neutral). The classifier never saw these during training — 100% accuracy with zero errors.

CV confusion matrix — Training stimuli (StratifiedKFold)
5-fold StratifiedKFold cross-validation on 80 training stimuli with Pipeline (scaler inside CV). 92.5% accuracy — 6 misclassifications out of 80.

PCA scatter — Brain response patterns
First two principal components of brain activation vectors. Humor and neutral clusters separate clearly, consistent with the strong classification performance.

Classifier weights — Left lateral
Logistic regression weights projected onto the left lateral brain surface. Warm regions are humor-predictive.

Classifier weights — Left medial
Logistic regression weights on the left medial surface.

Classifier weights — Right lateral
Logistic regression weights on the right lateral surface.

Classifier weights — Right medial
Logistic regression weights on the right medial surface.
Experiment data excludes raw stimuli and large prediction arrays.
Back to experiments