Text Classification
Transformers
Safetensors
English
gpt2
ai-text-detection
binary-classification
variable-position-readout
Instructions to use rasbt/ai-text-detector-gpt2-variable with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use rasbt/ai-text-detector-gpt2-variable with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="rasbt/ai-text-detector-gpt2-variable")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("rasbt/ai-text-detector-gpt2-variable") model = AutoModelForSequenceClassification.from_pretrained("rasbt/ai-text-detector-gpt2-variable", device_map="auto") - Notebooks
- Google Colab
- Kaggle
File size: 961 Bytes
946a240 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | {
"dataset": "rasbt/human-vs-ai-50k",
"base_model": "openai-community/gpt2",
"label_mapping": {
"human": 0,
"ai": 1
},
"readout_position": "variable",
"attention_implementation": "flash_attention_2",
"model_dtype": "torch.bfloat16",
"readout_token": "<|endoftext|>",
"pad_token": "<|pad|>",
"context_length": 1024,
"max_text_length": 1023,
"decision_threshold": 0.5,
"calibration": "temperature scaling",
"temperature": 2.770064980432574,
"best_validation_accuracy": 0.9744346116027532,
"best_checkpoint": "checkpoints-gpt2-variable-position/checkpoint-2535",
"trainable_parameters": 124442112,
"per_device_train_batch_size": 16,
"gradient_accumulation_steps": 1,
"training_runtime_seconds": 1540.0496,
"random_state": 17,
"python_version": "3.12.3",
"package_versions": {
"datasets": "4.1.0",
"numpy": "2.5.1",
"scikit-learn": "1.7.1",
"torch": "2.13.0",
"transformers": "5.14.1"
}
}
|