--- language: en --- # Women's Clothing Reviews Sentiment Analysis with DistilBERT ## Overview This Hugging Face repository contains a fine-tuned DistilBERT model for sentiment analysis of women's clothing reviews. The model is designed to classify reviews into positive, negative, or neutral sentiment categories, providing valuable insights into customer opinions. ## Model Details - **Model Architecture**: Fine-tuned DistilBERT - **Sentiment Categories**: Positive, Negative, Neutral - **Input Format**: Text-based clothing reviews - **Output Format**: Sentiment category labels ## Usage ### Installation To use this model, you'll need to install the Hugging Face Transformers library and any additional dependencies. ```bash pip install transformers ### Model Loading You can easily load the pre-trained model for sentiment analysis using Hugging Face's AutoModelForSequenceClassification. ```python from transformers import DistilBertForSequenceClassification, DistilBertTokenizerFast import torch model_name = "ongaunjie/distilbert-cloths-sentiment" tokenizer = DistilBertTokenizerFast.from_pretrained(model_name) model = DistilBertForSequenceClassification.from_pretrained(model_name) ## Inference You can use this model to perform sentiment analysis on text. Here's an example of how to do it in Python: ```python review = "This dress is amazing, I love it!" inputs = tokenizer.encode(review, return_tensors="pt") with torch.no_grad(): outputs = model(inputs) predicted_class = int(torch.argmax(outputs.logits))