Downloads · 30 days
14
0% of all-time downloads
shuaifan/SentiWSP-base
SentiWSP-base is a text classification model from shuaifan. Use it when you need a label for a piece of text. It is set up for transformers.
We propose SentiWSP, a novel Sentiment-aware pre-trained language model with combined Word-level and Sentence-level Pre-training tasks. The word level pre-training task detects replaced sentiment words, via a generato…
Downloads · 30 days
14
0% of all-time downloads
All-time downloads
8.9K
Public
Repo size
876 MB
Likes
1
Public
Click a slice to open those files.
.bin438 MB · 100%
From the Hugging Face model README
We propose SentiWSP, a novel Sentiment-aware pre-trained language model with combined Word-level and Sentence-level Pre-training tasks. The word level pre-training task detects replaced sentiment words, via a generator-discriminator framework, to enhance the PLM's knowledge about sentiment words. The sentence level pre-training task further strengthens the discriminator via a contrastive learning framework, with similar sentences as negative samples, to encode sentiments in a sentence.
You can also load our model in huggingface (https://huggingface.co/shuaifan/SentiWSP-base) to fine-tunning in sentiment analysis tasks:
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
tokenizer = AutoTokenizer.from_pretrained("shuaifan/SentiWSP-base")
model = AutoModelForSequenceClassification.from_pretrained("shuaifan/SentiWSP-base")