AICodexLab commited on
Commit
1cb7350
Β·
verified Β·
1 Parent(s): af9d79b

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +90 -44
README.md CHANGED
@@ -3,69 +3,115 @@ library_name: transformers
3
  license: apache-2.0
4
  base_model: answerdotai/ModernBERT-base
5
  tags:
 
 
 
 
6
  - generated_from_trainer
7
  model-index:
8
  - name: answerdotai-ModernBERT-base-ai-detector
9
  results: []
10
  ---
11
 
12
- <!-- This model card has been generated automatically according to the information the Trainer had access to. You
13
- should probably proofread and complete it, then remove this comment. -->
14
-
15
  # answerdotai-ModernBERT-base-ai-detector
16
 
17
- This model is a fine-tuned version of [answerdotai/ModernBERT-base](https://huggingface.co/answerdotai/ModernBERT-base) on the None dataset.
 
18
  It achieves the following results on the evaluation set:
19
- - Loss: 0.0036
20
 
21
- ## Model description
22
 
23
- More information needed
 
 
24
 
25
- ## Intended uses & limitations
26
 
27
- More information needed
 
 
 
 
28
 
29
- ## Training and evaluation data
 
 
 
30
 
31
- More information needed
32
 
33
- ## Training procedure
 
 
 
 
 
34
 
35
- ### Training hyperparameters
36
 
 
 
37
  The following hyperparameters were used during training:
38
- - learning_rate: 2e-05
39
- - train_batch_size: 16
40
- - eval_batch_size: 16
41
- - seed: 42
42
- - optimizer: Use OptimizerNames.ADAMW_TORCH with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
43
- - lr_scheduler_type: linear
44
- - num_epochs: 3
45
- - mixed_precision_training: Native AMP
46
 
47
- ### Training results
 
 
 
 
 
 
 
 
 
 
48
 
 
49
  | Training Loss | Epoch | Step | Validation Loss |
50
- |:-------------:|:------:|:----:|:---------------:|
51
- | 0.0505 | 0.2228 | 500 | 0.0214 |
52
- | 0.0114 | 0.4456 | 1000 | 0.0110 |
53
- | 0.0088 | 0.6684 | 1500 | 0.0032 |
54
- | 0.0 | 0.8913 | 2000 | 0.0048 |
55
- | 0.0068 | 1.1141 | 2500 | 0.0035 |
56
- | 0.0 | 1.3369 | 3000 | 0.0040 |
57
- | 0.0 | 1.5597 | 3500 | 0.0097 |
58
- | 0.0053 | 1.7825 | 4000 | 0.0101 |
59
- | 0.0 | 2.0053 | 4500 | 0.0053 |
60
- | 0.0 | 2.2282 | 5000 | 0.0039 |
61
- | 0.0017 | 2.4510 | 5500 | 0.0046 |
62
- | 0.0 | 2.6738 | 6000 | 0.0043 |
63
- | 0.0 | 2.8966 | 6500 | 0.0036 |
64
-
65
-
66
- ### Framework versions
67
-
68
- - Transformers 4.48.3
69
- - Pytorch 2.5.1+cu124
70
- - Datasets 3.3.2
71
- - Tokenizers 0.21.0
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  license: apache-2.0
4
  base_model: answerdotai/ModernBERT-base
5
  tags:
6
+ - text-classification
7
+ - ai-content-detection
8
+ - bert
9
+ - transformers
10
  - generated_from_trainer
11
  model-index:
12
  - name: answerdotai-ModernBERT-base-ai-detector
13
  results: []
14
  ---
15
 
 
 
 
16
  # answerdotai-ModernBERT-base-ai-detector
17
 
18
+ This model is a fine-tuned version of [answerdotai/ModernBERT-base](https://huggingface.co/answerdotai/ModernBERT-base) on the **AI vs Human Text Classification dataset**.
19
+
20
  It achieves the following results on the evaluation set:
21
+ - **Validation Loss:** `0.0036`
22
 
23
+ ---
24
 
25
+ ## **πŸ“ Model Description**
26
+ This model is based on **ModernBERT-base**, a lightweight and efficient BERT-based model.
27
+ It has been fine-tuned for **AI-generated vs Human-written text classification**, allowing it to distinguish between texts written by **AI models (ChatGPT, DeepSeek, Claude, etc.)** and human authors.
28
 
29
+ ---
30
 
31
+ ## **🎯 Intended Uses & Limitations**
32
+ ### βœ… **Intended Uses**
33
+ - **AI-generated content detection** (e.g., ChatGPT, Claude, DeepSeek).
34
+ - **Text classification** for distinguishing human vs AI-generated content.
35
+ - **Educational & Research applications** for AI-content detection.
36
 
37
+ ### ⚠️ **Limitations**
38
+ - **Not 100% accurate** β†’ Some AI texts may resemble human writing and vice versa.
39
+ - **Limited to trained dataset scope** β†’ May struggle with **out-of-domain** text.
40
+ - **Bias risks** β†’ If the dataset contains bias, the model may inherit it.
41
 
42
+ ---
43
 
44
+ ## **πŸ“Š Training and Evaluation Data**
45
+ - The model was fine-tuned on **35,894 training samples** and **8,974 test samples**.
46
+ - The dataset consists of **AI-generated text samples (ChatGPT, Claude, DeepSeek, etc.)** and **human-written samples (Wikipedia, books, articles)**.
47
+ - Labels:
48
+ - `1` β†’ AI-generated text
49
+ - `0` β†’ Human-written text
50
 
51
+ ---
52
 
53
+ ## **βš™οΈ Training Procedure**
54
+ ### **Training Hyperparameters**
55
  The following hyperparameters were used during training:
 
 
 
 
 
 
 
 
56
 
57
+ | Hyperparameter | Value |
58
+ |----------------------|--------------------|
59
+ | **Learning Rate** | `2e-5` |
60
+ | **Train Batch Size** | `16` |
61
+ | **Eval Batch Size** | `16` |
62
+ | **Optimizer** | `AdamW` (`Ξ²1=0.9, Ξ²2=0.999, Ξ΅=1e-08`) |
63
+ | **LR Scheduler** | `Linear` |
64
+ | **Epochs** | `3` |
65
+ | **Mixed Precision** | `Native AMP (fp16)` |
66
+
67
+ ---
68
 
69
+ ## **πŸ“ˆ Training Results**
70
  | Training Loss | Epoch | Step | Validation Loss |
71
+ |--------------|--------|------|----------------|
72
+ | 0.0505 | 0.22 | 500 | 0.0214 |
73
+ | 0.0114 | 0.44 | 1000 | 0.0110 |
74
+ | 0.0088 | 0.66 | 1500 | 0.0032 |
75
+ | 0.0 | 0.89 | 2000 | 0.0048 |
76
+ | 0.0068 | 1.11 | 2500 | 0.0035 |
77
+ | 0.0 | 1.33 | 3000 | 0.0040 |
78
+ | 0.0 | 1.55 | 3500 | 0.0097 |
79
+ | 0.0053 | 1.78 | 4000 | 0.0101 |
80
+ | 0.0 | 2.00 | 4500 | 0.0053 |
81
+ | 0.0 | 2.22 | 5000 | 0.0039 |
82
+ | 0.0017 | 2.45 | 5500 | 0.0046 |
83
+ | 0.0 | 2.67 | 6000 | 0.0043 |
84
+ | 0.0 | 2.89 | 6500 | 0.0036 |
85
+
86
+ ---
87
+
88
+ ## **πŸ›  Framework Versions**
89
+ | Library | Version |
90
+ |--------------|------------|
91
+ | **Transformers** | `4.48.3` |
92
+ | **PyTorch** | `2.5.1+cu124` |
93
+ | **Datasets** | `3.3.2` |
94
+ | **Tokenizers** | `0.21.0` |
95
+
96
+ ---
97
+
98
+ ## **πŸ“€ Model Usage**
99
+ To load and use the model for text classification:
100
+ ```python
101
+ from transformers import AutoModelForSequenceClassification, AutoTokenizer, pipeline
102
+
103
+ model_name = "answerdotai/ModernBERT-base-ai-detector"
104
+
105
+ # Load model and tokenizer
106
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
107
+ model = AutoModelForSequenceClassification.from_pretrained(model_name)
108
+
109
+ # Create text classification pipeline
110
+ classifier = pipeline("text-classification", model=model, tokenizer=tokenizer)
111
+
112
+ # Run classification
113
+ text = "This text was written by an AI model like ChatGPT."
114
+ result = classifier(text)
115
+
116
+ print(result)
117
+ ```