Downloads · 30 days
16
36% of all-time downloads
Moodlerz/bert-detector-eli5
bert-detector-eli5 is a text classification model from Moodlerz. Use it when you need a label for a piece of text. The card lists the license as mit.
This model was fine-tuned as part of a research project comparing transformer-based AI-text detectors across two benchmark datasets: HC3 and ELI5.
Downloads · 30 days
16
36% of all-time downloads
All-time downloads
45
Public
Parameters
109M
876 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors438 MB · 100%
From the Hugging Face model README
This model was fine-tuned as part of a research project comparing transformer-based AI-text detectors across two benchmark datasets: HC3 and ELI5.
The task is binary classification:
BERT (bert-base-uncased) fine-tuned on ELI5 for AI-text detection. Binary classifier: human (0) vs LLM-generated (1). Trained with 1 epoch, dropout=0.2, early stopping on ROC-AUC.
| Setting | Value |
|---|---|
| Epochs | 1 |
| Batch size (train) | 16 |
| Learning rate | 2e-5 |
| Warmup steps | 500 |
| Weight decay | 0.01 |
| Dropout | 0.2 |
| Max seq length | 512 |
| Validation split | 10% |
| Best model metric | ROC-AUC |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
model = AutoModelForSequenceClassification.from_pretrained("Moodlerz/bert-detector-eli5")
tokenizer = AutoTokenizer.from_pretrained("Moodlerz/bert-detector-eli5")
text = "Your input text here"
inputs = tokenizer(text, return_tensors="pt", truncation=True, max_length=512)
with torch.no_grad():
logits = model(**inputs).logits
prob_llm = torch.softmax(logits, dim=-1)[0][1].item()
print(f"P(LLM-generated): {prob_llm:.4f}")
./models/BERT_eli5Moodlerz.