Run this model with HF Jobs

Run bolewara/imdb-sentiment-distilbert on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.

Paste one of these prompts into your coding agent:

Fine-tune on my dataset

Use HF Jobs to fine-tune https://huggingface.co/bolewara/imdb-sentiment-distilbert. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.

Run batch inference

Use HF Jobs to run batch inference with https://huggingface.co/bolewara/imdb-sentiment-distilbert on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.

IMDB Sentiment Classifier (DistilBERT fine-tuned)

DistilBERT-base-uncased fine-tuned for binary sentiment classification (positive/negative movie reviews). A genuine transformer fine-tune performed locally on a 1,500-review IMDB subsample.

Model Characteristics

  • Base model: distilbert-base-uncased (Hugging Face)
  • Task: Binary sequence classification
  • Eval loss: 0.0005 (after early stopping on epoch 2)
  • Training: 2 epochs, lr 2e-5, batch 8, warmup 50 steps

Data Overview

  • Dataset: stanfordnlp/imdb (subsampled to 1,500 train / 300 test for CPU feasibility)
  • Text truncated/padded to 128 tokens

Evaluation Results

  • Eval loss: 0.000518
  • Early stopping triggered at epoch 2 of 3

Files

  • model.safetensors β€” fine-tuned weights
  • config.json β€” model config (2 labels)
  • tokenizer.json, tokenizer_config.json β€” tokenizer
  • eval_metrics.txt β€” final evaluation metrics

Usage

from transformers import AutoModelForSequenceClassification, AutoTokenizer
model = AutoModelForSequenceClassification.from_pretrained("bolewara/imdb-sentiment-distilbert")
tokenizer = AutoTokenizer.from_pretrained("bolewara/imdb-sentiment-distilbert")

Writeup

A full case study is in the accompanying writeup (also published on Kaggle): Fine-Tuning DistilBERT for Movie Review Sentiment Analysis.

Provenance

Fine-tuned by Anuj Bolewar (anujbolewar on Kaggle) from distilbert-base-uncased on stanfordnlp/imdb.

Downloads last month
4
Safetensors
Model size
67M params
Tensor type
F32
Β·
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for bolewara/imdb-sentiment-distilbert

Finetuned
(13,050)
this model