Downloads · 30 days
5
15% of all-time downloads
zeynepcetin/distilbert-base-uncased-zeynepc-5dim
distilbert-base-uncased-zeynepc-5dim is a text classification model from zeynepcetin. Use it when you need a label for a piece of text. It is set up for transformers. The card lists the license as apache-2.0.
This model is a fine-tuned version of distilbert-base-uncased for personality classification based on the Five-Factor Model (FFM), also known as the Big Five Personality Traits. It predicts probabilities for five pers…
Downloads · 30 days
5
15% of all-time downloads
All-time downloads
34
Public
Repo size
804 MB
Likes
0
Public
Click a slice to open those files.
.h5268 MB · 100%
From the Hugging Face model README
This model is a fine-tuned version of distilbert-base-uncased for personality classification based on the Five-Factor Model (FFM), also known as the Big Five Personality Traits. It predicts probabilities for five personality dimensions: Extraversion, Agreeableness, Neuroticism, Openness, and Conscientiousness.
The model uses the distilbert-base-uncased architecture as a base and is fine-tuned to classify text into five personality dimensions. Probabilities for each dimension are calculated using a sigmoid activation function, making it suitable for multi-label classification.
The model was fine-tuned on a custom dataset related to personality analysis. The dataset includes labeled examples corresponding to the Five-Factor Model traits. The evaluation set results will depend on the size and quality of this dataset.
distilbert-base-uncased tokenizer with a maximum length of 512 tokens.The model can be used with the Hugging Face transformers library as follows:
from transformers import AutoTokenizer, TFAutoModelForSequenceClassification
import tensorflow as tf
# Load the tokenizer and model
tokenizer = AutoTokenizer.from_pretrained("zeynepcetin/distilbert-base-uncased-zeynepc-5dim")
model = TFAutoModelForSequenceClassification.from_pretrained("zeynepcetin/distilbert-base-uncased-zeynepc-5dim")
# Example text
text = "I enjoy working with others and find joy in social interactions."
# Tokenize and predict
inputs = tokenizer(text, truncation=True, padding=True, max_length=512, return_tensors="tf")
outputs = model(inputs)
probs = tf.nn.sigmoid(outputs.logits).numpy()
# Print probabilities for each personality trait
traits = ["Extraversion", "Agreeableness", "Neuroticism", "Openness", "Conscientiousness"]
for trait, prob in zip(traits, probs[0]):
print(f"{trait}: {prob:.2f}")