/ Модель

Характеристики

Контекст
512 токенов
Лицензия
Apache 2.0
Архитектура
distilbert · dense
Базовая модель
distilbert-base-uncased
Библиотека
transformers
Опубликована
6 сен 2025

distilbert-finetuned-sentiment-analysis

Классификация текстаТекст → label3 профессии

Модель на базе DistilBERT определяет положительную, нейтральную или отрицательную тональность англоязычных комментариев YouTube.

111скачиваний за 30 дней0лайковвеса обновлены6 окт 2025

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

Это модель классификации тональности на базе DistilBERT, дообученная iam-tsr на корпусе комментариев YouTube. Она присваивает тексту одну из трёх меток: POSITIVE, NEUTRAL или NEGATIVE; модель рассчитана на разговорный английский, включая сленг, эмодзи и неформальные выражения. Архитектура — DistilBertForSequenceClassification, базовая модель distilbert/distilbert-base-uncased; контекст составляет до 512 токенов, а в обучении использовалась максимальная длина последовательности 128 токенов.

Модель подходит для мониторинга реакции аудитории на видео, анализа отзывов и помощи в модерации комментариев. На тестовой выборке комментариев YouTube указаны accuracy 0,7301 и F1 0,7300. Распространяется по лицензии Apache-2.0.

Сценарии применения

  • анализ тональности комментариев YouTube
  • мониторинг реакции аудитории на видео
  • сортировка комментариев по положительной, нейтральной и отрицательной оценке
  • анализ отзывов в социальных сетях
  • помощь в модерации комментариев

Ограничения

Модель обучена на комментариях YouTube, поэтому качество на других типах текста и языках может снижаться. Она может ошибаться при сарказме, иронии, культурно обусловленных выражениях и смешанной тональности; три класса не охватывают весь спектр эмоций.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

Finetuned DistilBERT model card

This model is a fine-tuned version of distilbert-base-uncased post trained on a huge comments corpus for sentiment analysis.

Model description

The model is based on DistilBERT, a distilled version of BERT that is smaller, faster, and requires less computational resources while maintaining 97% of BERT's performance. This specific model has been fine-tuned to perform sentiment analysis on YouTube comments, classifying them into three categories: POSITIVE, NEUTRAL, and NEGATIVE.

The model is designed to understand the nuanced language used in social media comments, including slang, emojis, and informal speech patterns typically found in YouTube comment sections.

Model architecture

  • Base model: DistilBERT (distilbert-base-uncased)
  • Task type: Text Classification (Sentiment Analysis)
  • Number of labels: 3 (POSITIVE, NEUTRAL, NEGATIVE)
  • Label mapping: {"NEUTRAL": 0, "POSITIVE": 1, "NEGATIVE": 2}

Training and evaluation data

The model was trained on a custom dataset of YouTube comments with sentiment labels:

  • Dataset: im-tsr/comments-sentiments
  • Training set size: 7,20,977 samples
  • Test set size: 36,558 samples
  • Maximum sequence length: 128 tokens

Training procedure

The model was fine-tuned using the Hugging Face Transformers library with Pytorch.

Training hyperparameters

The following hyperparameters were used during training:

  • Learning rate: 5e-05
  • Train batch size: 64
  • Eval batch size: 64
  • Weight decay: 0.01
  • Optimizer: AdamW
  • Number of epochs: 3
  • Maximum sequence length: 128

Evaluation results

The model was evaluated on a test set of YouTube comments. The evaluation metrics are:

  • Accuracy: 0.730100
  • F1 Score: 0.730025

Using Hugging Face Transformers

import torch
import transformers
from transformers import pipeline

def get_sentiment(text):
    #Set to avoid warning messages.
    transformers.logging.set_verbosity_error()
    sentiment_classifier = pipeline(task="text-classification",
                                    model="iam-tsr/distilbert-finetuned-sentiment-analysis",
                                    tokenizer="iam-tsr/distilbert-finetuned-sentiment-analysis",)

    return sentiment_classifier(text)

get_sentiment("I love programming!")
#[{'label': 'POSITIVE', 'score': 0.9759756326675415}]

Intended uses

This model is intended for analyzing sentiment in YouTube comments and similar social media text. It can be used for:

  • Monitoring sentiment in YouTube comment sections
  • Content moderation assistance
  • Social media sentiment analysis
  • User feedback analysis
  • Tracking audience reaction to videos or content

Limitations

  • The model is specifically trained on YouTube comments, which may have different characteristics from other text sources
  • Performance may vary for comments in languages other than English
  • The model may not handle sarcasm, irony, or cultural context effectively
  • Limited to three sentiment categories which may not capture the full spectrum of emotions
  • May not perform optimally on very short texts or texts with multiple conflicting sentiments

Links

Framework versions

  • Transformers 4.53
  • Pytorch 2.8.0
  • Datasets 3.6.0

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers · text-classification

Можно запустить

Подбираем GPU…

Класс архитектуры
DistilBertForSequenceClassification
Ревизия весов
4e77f93

0 моделей