Skip to content

Code for Hayati et al's paper "StyLEx: Explaining Styles with Lexicon-Based Human Perception"

Notifications You must be signed in to change notification settings

minnesotanlp/stylex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

StyLEx: Explaining Style Using Human Lexical Annotations

This repository provides datasets and code for preprocessing, training and testing models for style classification with human lexical annotations with the official Hugging Face implementation of the following paper:

StyLEx: Explaining Style Using Human Lexical Annotations
Shirley A. Hayati, Kyumin Park, Dheeraj Rajagopal, Lyle Ungar, Dongyeop Kang
EACL 2023

Installation

The following command installs all necessary packages:

pip install -r requirements.txt

The project was tested using Python 3.8.

Models

Model Checkpoints

Model Style F1 (Orig) F1 (Hummingbird) F1 (OOD)
BERT Politeness 0.96 0.91 0.87
BERT Sentiment 0.67 0.91 0.75
BERT Joy 0.88 0.92 0.73
BERT Sadness 0.89 0.94 0.78
BERT Fear 0.96 0.92 0.80
BERT Disgust 0.86 0.81 0.74
BERT Anger 0.89 0.82 0.78
BERT Offensiveness 0.97 0.87 0.88

Citation

If you find this work useful for your research, please cite our papers:

@article{hayati2022stylex,
  title={StyLEx: Explaining Styles with Lexicon-Based Human Perception},
  author={Hayati, Shirley Anugrah and Park, Kyumin and Rajagopal, Dheeraj and Ungar, Lyle and Kang, Dongyeop},
  journal={arXiv preprint arXiv:2210.07469},
  year={2022}
}

About

Code for Hayati et al's paper "StyLEx: Explaining Styles with Lexicon-Based Human Perception"

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages