MaziyarPanahi commited on
Commit
ff919cb
·
verified ·
1 Parent(s): 5c0c8d8

Upload PII detection model OpenMed-PII-ClinicalE5-Base-109M-v1

Browse files
README.md ADDED
@@ -0,0 +1,326 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language:
3
+ - en
4
+ license: apache-2.0
5
+ base_model: intfloat/e5-base-v2
6
+ tags:
7
+ - token-classification
8
+ - ner
9
+ - pii
10
+ - pii-detection
11
+ - de-identification
12
+ - privacy
13
+ - healthcare
14
+ - medical
15
+ - clinical
16
+ - phi
17
+ - hipaa
18
+ - pytorch
19
+ - transformers
20
+ - openmed
21
+ datasets:
22
+ - nvidia/Nemotron-PII
23
+ pipeline_tag: token-classification
24
+ library_name: transformers
25
+ metrics:
26
+ - f1
27
+ - precision
28
+ - recall
29
+ model-index:
30
+ - name: OpenMed-PII-ClinicalE5-Base-109M-v1
31
+ results:
32
+ - task:
33
+ type: token-classification
34
+ name: Named Entity Recognition
35
+ dataset:
36
+ name: nvidia/Nemotron-PII (test_strat)
37
+ type: nvidia/Nemotron-PII
38
+ split: test
39
+ metrics:
40
+ - type: f1
41
+ value: 0.9487
42
+ name: F1 (micro)
43
+ - type: precision
44
+ value: 0.9520
45
+ name: Precision
46
+ - type: recall
47
+ value: 0.9454
48
+ name: Recall
49
+ widget:
50
+ - text: "Dr. Sarah Johnson (SSN: 123-45-6789) can be reached at sarah.johnson@hospital.org or 555-123-4567. She lives at 123 Oak Street, Boston, MA 02108."
51
+ example_title: Clinical Note with PII
52
+ ---
53
+
54
+ # OpenMed-PII-ClinicalE5-Base-109M-v1
55
+
56
+ **PII Detection Model** | 109M Parameters | Open Source
57
+
58
+ [![F1 Score](https://img.shields.io/badge/F1-94.87%25-brightgreen)]() [![Precision](https://img.shields.io/badge/Precision-95.20%25-blue)]() [![Recall](https://img.shields.io/badge/Recall-94.54%25-orange)]()
59
+
60
+ ## Model Description
61
+
62
+ **OpenMed-PII-ClinicalE5-Base-109M-v1** is a transformer-based token classification model fine-tuned for **Personally Identifiable Information (PII) detection** in text. This model identifies and classifies **54 types of sensitive information** including names, addresses, SSNs, medical record numbers, and more.
63
+
64
+ ### Key Features
65
+
66
+ - **High Accuracy**: Achieves strong F1 scores across diverse PII categories
67
+ - **Comprehensive Coverage**: Detects 50+ entity types spanning personal, financial, medical, and contact information
68
+ - **Privacy-Focused**: Designed for de-identification and compliance with HIPAA, GDPR, and other privacy regulations
69
+ - **Production-Ready**: Optimized for real-world text processing pipelines
70
+
71
+ ## Performance
72
+
73
+ Evaluated on a stratified 2,000-sample test set from NVIDIA Nemotron-PII:
74
+
75
+ | Metric | Score |
76
+ |:---|:---:|
77
+ | **Micro F1** | **0.9487** |
78
+ | Precision | 0.9520 |
79
+ | Recall | 0.9454 |
80
+ | Macro F1 | 0.9478 |
81
+ | Weighted F1 | 0.9478 |
82
+ | Accuracy | 0.9931 |
83
+
84
+ ### Top 10 PII Models
85
+
86
+ | Rank | Model | F1 | Precision | Recall |
87
+ |:---:|:---|:---:|:---:|:---:|
88
+ | 1 | [OpenMed-PII-SuperClinical-Large-434M-v1](https://huggingface.co/openmed/OpenMed-PII-SuperClinical-Large-434M-v1) | 0.9608 | 0.9685 | 0.9532 |
89
+ | 2 | [OpenMed-PII-BigMed-Large-560M-v1](https://huggingface.co/openmed/OpenMed-PII-BigMed-Large-560M-v1) | 0.9604 | 0.9644 | 0.9565 |
90
+ | 3 | [OpenMed-PII-EuroMed-210M-v1](https://huggingface.co/openmed/OpenMed-PII-EuroMed-210M-v1) | 0.9600 | 0.9681 | 0.9521 |
91
+ | 4 | [OpenMed-PII-SnowflakeMed-568M-v1](https://huggingface.co/openmed/OpenMed-PII-SnowflakeMed-568M-v1) | 0.9594 | 0.9640 | 0.9548 |
92
+ | 5 | [OpenMed-PII-SuperMedical-Large-355M-v1](https://huggingface.co/openmed/OpenMed-PII-SuperMedical-Large-355M-v1) | 0.9592 | 0.9632 | 0.9553 |
93
+ | 6 | [OpenMed-PII-ClinicalBGE-568M-v1](https://huggingface.co/openmed/OpenMed-PII-ClinicalBGE-568M-v1) | 0.9587 | 0.9636 | 0.9538 |
94
+ | 7 | [OpenMed-PII-mClinicalE5-Large-560M-v1](https://huggingface.co/openmed/OpenMed-PII-mClinicalE5-Large-560M-v1) | 0.9582 | 0.9631 | 0.9533 |
95
+ | 8 | [OpenMed-PII-ModernMed-Large-395M-v1](https://huggingface.co/openmed/OpenMed-PII-ModernMed-Large-395M-v1) | 0.9579 | 0.9639 | 0.9520 |
96
+ | 9 | [OpenMed-PII-BioClinicalModern-Large-395M-v1](https://huggingface.co/openmed/OpenMed-PII-BioClinicalModern-Large-395M-v1) | 0.9579 | 0.9656 | 0.9502 |
97
+ | 10 | [OpenMed-PII-ClinicalE5-Large-335M-v1](https://huggingface.co/openmed/OpenMed-PII-ClinicalE5-Large-335M-v1) | 0.9577 | 0.9604 | 0.9550 |
98
+
99
+ ### Best Performing Entities
100
+
101
+ | Entity | F1 | Precision | Recall | Support |
102
+ |:---|:---:|:---:|:---:|:---:|
103
+ | `biometric_identifier` | 1.000 | 1.000 | 1.000 | 234 |
104
+ | `email` | 0.995 | 0.996 | 0.993 | 763 |
105
+ | `health_plan_beneficiary_number` | 0.993 | 0.986 | 1.000 | 216 |
106
+ | `date_of_birth` | 0.993 | 0.986 | 1.000 | 273 |
107
+ | `blood_type` | 0.993 | 0.985 | 1.000 | 135 |
108
+
109
+ ### Challenging Entities
110
+
111
+ These entity types have lower performance and may benefit from additional post-processing:
112
+
113
+ | Entity | F1 | Precision | Recall | Support |
114
+ |:---|:---:|:---:|:---:|:---:|
115
+ | `pin` | 0.872 | 0.892 | 0.853 | 136 |
116
+ | `education_level` | 0.869 | 0.894 | 0.845 | 200 |
117
+ | `sexuality` | 0.857 | 0.815 | 0.904 | 83 |
118
+ | `gender` | 0.797 | 0.744 | 0.858 | 190 |
119
+ | `occupation` | 0.655 | 0.710 | 0.608 | 724 |
120
+
121
+ ## Supported Entity Types
122
+
123
+ This model detects **54 PII entity types** organized into categories:
124
+
125
+ <details>
126
+ <summary><strong>Identifiers</strong> (16 types)</summary>
127
+
128
+ | Entity | Description |
129
+ |:---|:---|
130
+ | `account_number` | Account Number |
131
+ | `api_key` | Api Key |
132
+ | `bank_routing_number` | Bank Routing Number |
133
+ | `certificate_license_number` | Certificate License Number |
134
+ | `credit_debit_card` | Credit Debit Card |
135
+ | `cvv` | Cvv |
136
+ | `employee_id` | Employee Id |
137
+ | `health_plan_beneficiary_number` | Health Plan Beneficiary Number |
138
+ | `mac_address` | Mac Address |
139
+ | `medical_record_number` | Medical Record Number |
140
+ | ... | *and 6 more* |
141
+
142
+ </details>
143
+
144
+ <details>
145
+ <summary><strong>Personal Info</strong> (14 types)</summary>
146
+
147
+ | Entity | Description |
148
+ |:---|:---|
149
+ | `age` | Age |
150
+ | `biometric_identifier` | Biometric Identifier |
151
+ | `blood_type` | Blood Type |
152
+ | `date_of_birth` | Date Of Birth |
153
+ | `education_level` | Education Level |
154
+ | `first_name` | First Name |
155
+ | `last_name` | Last Name |
156
+ | `gender` | Gender |
157
+ | `language` | Language |
158
+ | `occupation` | Occupation |
159
+ | ... | *and 4 more* |
160
+
161
+ </details>
162
+
163
+ <details>
164
+ <summary><strong>Contact Info</strong> (4 types)</summary>
165
+
166
+ | Entity | Description |
167
+ |:---|:---|
168
+ | `email` | Email |
169
+ | `phone_number` | Phone Number |
170
+ | `fax_number` | Fax Number |
171
+ | `url` | Url |
172
+
173
+ </details>
174
+
175
+ <details>
176
+ <summary><strong>Location</strong> (6 types)</summary>
177
+
178
+ | Entity | Description |
179
+ |:---|:---|
180
+ | `city` | City |
181
+ | `coordinate` | Coordinate |
182
+ | `country` | Country |
183
+ | `county` | County |
184
+ | `state` | State |
185
+ | `street_address` | Street Address |
186
+
187
+ </details>
188
+
189
+ <details>
190
+ <summary><strong>Network Info</strong> (3 types)</summary>
191
+
192
+ | Entity | Description |
193
+ |:---|:---|
194
+ | `device_identifier` | Device Identifier |
195
+ | `ipv4` | Ipv4 |
196
+ | `ipv6` | Ipv6 |
197
+
198
+ </details>
199
+
200
+ <details>
201
+ <summary><strong>Temporal</strong> (3 types)</summary>
202
+
203
+ | Entity | Description |
204
+ |:---|:---|
205
+ | `date` | Date |
206
+ | `date_time` | Date Time |
207
+ | `time` | Time |
208
+
209
+ </details>
210
+
211
+ <details>
212
+ <summary><strong>Organization</strong> (1 types)</summary>
213
+
214
+ | Entity | Description |
215
+ |:---|:---|
216
+ | `company_name` | Company Name |
217
+
218
+ </details>
219
+
220
+ ## Usage
221
+
222
+ ### Quick Start
223
+
224
+ ```python
225
+ from transformers import pipeline
226
+
227
+ # Load the PII detection pipeline
228
+ ner = pipeline("ner", model="openmed/OpenMed-PII-ClinicalE5-Base-109M-v1", aggregation_strategy="simple")
229
+
230
+ text = """
231
+ Patient John Smith (DOB: 03/15/1985, SSN: 123-45-6789) was seen today.
232
+ Contact: john.smith@email.com, Phone: (555) 123-4567.
233
+ Address: 456 Oak Street, Boston, MA 02108.
234
+ """
235
+
236
+ entities = ner(text)
237
+ for entity in entities:
238
+ print(f"{entity['entity_group']}: {entity['word']} (score: {entity['score']:.3f})")
239
+ ```
240
+
241
+ ### De-identification Example
242
+
243
+ ```python
244
+ def redact_pii(text, entities, placeholder='[REDACTED]'):
245
+ """Replace detected PII with placeholders."""
246
+ # Sort entities by start position (descending) to preserve offsets
247
+ sorted_entities = sorted(entities, key=lambda x: x['start'], reverse=True)
248
+ redacted = text
249
+ for ent in sorted_entities:
250
+ redacted = redacted[:ent['start']] + f"[{ent['entity_group']}]" + redacted[ent['end']:]
251
+ return redacted
252
+
253
+ # Apply de-identification
254
+ redacted_text = redact_pii(text, entities)
255
+ print(redacted_text)
256
+ ```
257
+
258
+ ### Batch Processing
259
+
260
+ ```python
261
+ from transformers import AutoModelForTokenClassification, AutoTokenizer
262
+ import torch
263
+
264
+ model_name = "openmed/OpenMed-PII-ClinicalE5-Base-109M-v1"
265
+ model = AutoModelForTokenClassification.from_pretrained(model_name)
266
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
267
+
268
+ texts = [
269
+ "Contact Dr. Jane Doe at jane.doe@hospital.org",
270
+ "Patient SSN: 987-65-4321, MRN: 12345678",
271
+ ]
272
+
273
+ inputs = tokenizer(texts, return_tensors='pt', padding=True, truncation=True)
274
+ with torch.no_grad():
275
+ outputs = model(**inputs)
276
+ predictions = torch.argmax(outputs.logits, dim=-1)
277
+ ```
278
+
279
+ ## Training Details
280
+
281
+ ### Dataset
282
+
283
+ - **Source**: [NVIDIA Nemotron-PII](https://huggingface.co/datasets/nvidia/Nemotron-PII)
284
+ - **Format**: BIO-tagged token classification
285
+ - **Labels**: 106 total (53 entity types × 2 BIO tags + O)
286
+ - **Splits**: 50K train / 5K validation / 45K test
287
+
288
+ ### Training Configuration
289
+
290
+ - **Max Sequence Length**: 384 tokens
291
+ - **Label Strategy**: First token only (`label_all_tokens=False`)
292
+ - **Framework**: Hugging Face Transformers + Trainer API
293
+
294
+ ## Intended Use & Limitations
295
+
296
+ ### Intended Use
297
+
298
+ - **De-identification**: Automated redaction of PII in clinical notes, medical records, and documents
299
+ - **Compliance**: Supporting HIPAA, GDPR, and privacy regulation compliance
300
+ - **Data Preprocessing**: Preparing datasets for research by removing sensitive information
301
+ - **Audit Support**: Identifying PII in document collections
302
+
303
+ ### Limitations
304
+
305
+ ⚠️ **Important**: This model is intended as an **assistive tool**, not a replacement for human review.
306
+
307
+ - **False Negatives**: Some PII may not be detected; always verify critical applications
308
+ - **Context Sensitivity**: Performance may vary with domain-specific terminology
309
+ - **Challenging Categories**: `occupation`, `time`, and `sexuality` have lower F1 scores
310
+ - **Language**: Primarily trained on English text
311
+
312
+ ## Citation
313
+
314
+ ```bibtex
315
+ @misc{openmed-pii-2026,
316
+ title = {OpenMed-PII-ClinicalE5-Base-109M-v1: PII Detection Model},
317
+ author = {OpenMed Science},
318
+ year = {2026},
319
+ publisher = {Hugging Face},
320
+ url = {https://huggingface.co/openmed/OpenMed-PII-ClinicalE5-Base-109M-v1}
321
+ }
322
+ ```
323
+
324
+ ## Links
325
+
326
+ - **Organization**: [OpenMed](https://huggingface.co/OpenMed)
all_results.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 3.0,
3
+ "eval_accuracy": 0.994285048763938,
4
+ "eval_f1": 0.9540518164994642,
5
+ "eval_loss": 0.023267928510904312,
6
+ "eval_precision": 0.9574556473290651,
7
+ "eval_recall": 0.9506721017130101,
8
+ "eval_runtime": 14.8896,
9
+ "eval_samples_per_second": 335.804,
10
+ "eval_steps_per_second": 5.306,
11
+ "test_accuracy": 0.9942960950558528,
12
+ "test_f1": 0.9545491518553041,
13
+ "test_loss": 0.022622624412178993,
14
+ "test_precision": 0.9572360415390746,
15
+ "test_recall": 0.9518773037460972,
16
+ "test_runtime": 189.6487,
17
+ "test_samples_per_second": 237.281,
18
+ "test_steps_per_second": 3.712,
19
+ "total_flos": 1.8767762625368064e+16,
20
+ "train_loss": 0.1060635477882836,
21
+ "train_runtime": 842.9188,
22
+ "train_samples_per_second": 177.953,
23
+ "train_steps_per_second": 5.563
24
+ }
config.json ADDED
@@ -0,0 +1,241 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "BertForTokenClassification"
4
+ ],
5
+ "attention_probs_dropout_prob": 0.1,
6
+ "classifier_dropout": null,
7
+ "dtype": "float32",
8
+ "gradient_checkpointing": false,
9
+ "hidden_act": "gelu",
10
+ "hidden_dropout_prob": 0.1,
11
+ "hidden_size": 768,
12
+ "id2label": {
13
+ "0": "O",
14
+ "1": "B-account_number",
15
+ "2": "B-age",
16
+ "3": "B-api_key",
17
+ "4": "B-bank_routing_number",
18
+ "5": "B-biometric_identifier",
19
+ "6": "B-blood_type",
20
+ "7": "B-certificate_license_number",
21
+ "8": "B-city",
22
+ "9": "B-company_name",
23
+ "10": "B-coordinate",
24
+ "11": "B-country",
25
+ "12": "B-county",
26
+ "13": "B-credit_debit_card",
27
+ "14": "B-customer_id",
28
+ "15": "B-cvv",
29
+ "16": "B-date",
30
+ "17": "B-date_of_birth",
31
+ "18": "B-date_time",
32
+ "19": "B-device_identifier",
33
+ "20": "B-education_level",
34
+ "21": "B-email",
35
+ "22": "B-employee_id",
36
+ "23": "B-employment_status",
37
+ "24": "B-fax_number",
38
+ "25": "B-first_name",
39
+ "26": "B-gender",
40
+ "27": "B-health_plan_beneficiary_number",
41
+ "28": "B-http_cookie",
42
+ "29": "B-ipv4",
43
+ "30": "B-ipv6",
44
+ "31": "B-language",
45
+ "32": "B-last_name",
46
+ "33": "B-license_plate",
47
+ "34": "B-mac_address",
48
+ "35": "B-medical_record_number",
49
+ "36": "B-occupation",
50
+ "37": "B-password",
51
+ "38": "B-phone_number",
52
+ "39": "B-pin",
53
+ "40": "B-political_view",
54
+ "41": "B-postcode",
55
+ "42": "B-race_ethnicity",
56
+ "43": "B-religious_belief",
57
+ "44": "B-sexuality",
58
+ "45": "B-ssn",
59
+ "46": "B-state",
60
+ "47": "B-street_address",
61
+ "48": "B-swift_bic",
62
+ "49": "B-tax_id",
63
+ "50": "B-time",
64
+ "51": "B-unique_id",
65
+ "52": "B-url",
66
+ "53": "B-user_name",
67
+ "54": "B-vehicle_identifier",
68
+ "55": "I-account_number",
69
+ "56": "I-api_key",
70
+ "57": "I-biometric_identifier",
71
+ "58": "I-blood_type",
72
+ "59": "I-certificate_license_number",
73
+ "60": "I-city",
74
+ "61": "I-company_name",
75
+ "62": "I-coordinate",
76
+ "63": "I-country",
77
+ "64": "I-county",
78
+ "65": "I-credit_debit_card",
79
+ "66": "I-customer_id",
80
+ "67": "I-date",
81
+ "68": "I-date_of_birth",
82
+ "69": "I-date_time",
83
+ "70": "I-device_identifier",
84
+ "71": "I-education_level",
85
+ "72": "I-email",
86
+ "73": "I-employee_id",
87
+ "74": "I-employment_status",
88
+ "75": "I-fax_number",
89
+ "76": "I-first_name",
90
+ "77": "I-gender",
91
+ "78": "I-health_plan_beneficiary_number",
92
+ "79": "I-http_cookie",
93
+ "80": "I-ipv4",
94
+ "81": "I-ipv6",
95
+ "82": "I-language",
96
+ "83": "I-last_name",
97
+ "84": "I-license_plate",
98
+ "85": "I-mac_address",
99
+ "86": "I-medical_record_number",
100
+ "87": "I-occupation",
101
+ "88": "I-password",
102
+ "89": "I-phone_number",
103
+ "90": "I-pin",
104
+ "91": "I-political_view",
105
+ "92": "I-postcode",
106
+ "93": "I-race_ethnicity",
107
+ "94": "I-religious_belief",
108
+ "95": "I-sexuality",
109
+ "96": "I-ssn",
110
+ "97": "I-state",
111
+ "98": "I-street_address",
112
+ "99": "I-swift_bic",
113
+ "100": "I-tax_id",
114
+ "101": "I-time",
115
+ "102": "I-unique_id",
116
+ "103": "I-url",
117
+ "104": "I-user_name",
118
+ "105": "I-vehicle_identifier"
119
+ },
120
+ "initializer_range": 0.02,
121
+ "intermediate_size": 3072,
122
+ "label2id": {
123
+ "B-account_number": 1,
124
+ "B-age": 2,
125
+ "B-api_key": 3,
126
+ "B-bank_routing_number": 4,
127
+ "B-biometric_identifier": 5,
128
+ "B-blood_type": 6,
129
+ "B-certificate_license_number": 7,
130
+ "B-city": 8,
131
+ "B-company_name": 9,
132
+ "B-coordinate": 10,
133
+ "B-country": 11,
134
+ "B-county": 12,
135
+ "B-credit_debit_card": 13,
136
+ "B-customer_id": 14,
137
+ "B-cvv": 15,
138
+ "B-date": 16,
139
+ "B-date_of_birth": 17,
140
+ "B-date_time": 18,
141
+ "B-device_identifier": 19,
142
+ "B-education_level": 20,
143
+ "B-email": 21,
144
+ "B-employee_id": 22,
145
+ "B-employment_status": 23,
146
+ "B-fax_number": 24,
147
+ "B-first_name": 25,
148
+ "B-gender": 26,
149
+ "B-health_plan_beneficiary_number": 27,
150
+ "B-http_cookie": 28,
151
+ "B-ipv4": 29,
152
+ "B-ipv6": 30,
153
+ "B-language": 31,
154
+ "B-last_name": 32,
155
+ "B-license_plate": 33,
156
+ "B-mac_address": 34,
157
+ "B-medical_record_number": 35,
158
+ "B-occupation": 36,
159
+ "B-password": 37,
160
+ "B-phone_number": 38,
161
+ "B-pin": 39,
162
+ "B-political_view": 40,
163
+ "B-postcode": 41,
164
+ "B-race_ethnicity": 42,
165
+ "B-religious_belief": 43,
166
+ "B-sexuality": 44,
167
+ "B-ssn": 45,
168
+ "B-state": 46,
169
+ "B-street_address": 47,
170
+ "B-swift_bic": 48,
171
+ "B-tax_id": 49,
172
+ "B-time": 50,
173
+ "B-unique_id": 51,
174
+ "B-url": 52,
175
+ "B-user_name": 53,
176
+ "B-vehicle_identifier": 54,
177
+ "I-account_number": 55,
178
+ "I-api_key": 56,
179
+ "I-biometric_identifier": 57,
180
+ "I-blood_type": 58,
181
+ "I-certificate_license_number": 59,
182
+ "I-city": 60,
183
+ "I-company_name": 61,
184
+ "I-coordinate": 62,
185
+ "I-country": 63,
186
+ "I-county": 64,
187
+ "I-credit_debit_card": 65,
188
+ "I-customer_id": 66,
189
+ "I-date": 67,
190
+ "I-date_of_birth": 68,
191
+ "I-date_time": 69,
192
+ "I-device_identifier": 70,
193
+ "I-education_level": 71,
194
+ "I-email": 72,
195
+ "I-employee_id": 73,
196
+ "I-employment_status": 74,
197
+ "I-fax_number": 75,
198
+ "I-first_name": 76,
199
+ "I-gender": 77,
200
+ "I-health_plan_beneficiary_number": 78,
201
+ "I-http_cookie": 79,
202
+ "I-ipv4": 80,
203
+ "I-ipv6": 81,
204
+ "I-language": 82,
205
+ "I-last_name": 83,
206
+ "I-license_plate": 84,
207
+ "I-mac_address": 85,
208
+ "I-medical_record_number": 86,
209
+ "I-occupation": 87,
210
+ "I-password": 88,
211
+ "I-phone_number": 89,
212
+ "I-pin": 90,
213
+ "I-political_view": 91,
214
+ "I-postcode": 92,
215
+ "I-race_ethnicity": 93,
216
+ "I-religious_belief": 94,
217
+ "I-sexuality": 95,
218
+ "I-ssn": 96,
219
+ "I-state": 97,
220
+ "I-street_address": 98,
221
+ "I-swift_bic": 99,
222
+ "I-tax_id": 100,
223
+ "I-time": 101,
224
+ "I-unique_id": 102,
225
+ "I-url": 103,
226
+ "I-user_name": 104,
227
+ "I-vehicle_identifier": 105,
228
+ "O": 0
229
+ },
230
+ "layer_norm_eps": 1e-12,
231
+ "max_position_embeddings": 512,
232
+ "model_type": "bert",
233
+ "num_attention_heads": 12,
234
+ "num_hidden_layers": 12,
235
+ "pad_token_id": 0,
236
+ "position_embedding_type": "absolute",
237
+ "transformers_version": "4.57.1",
238
+ "type_vocab_size": 2,
239
+ "use_cache": true,
240
+ "vocab_size": 30522
241
+ }
eval_results.json ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 3.0,
3
+ "eval_accuracy": 0.994285048763938,
4
+ "eval_f1": 0.9540518164994642,
5
+ "eval_loss": 0.023267928510904312,
6
+ "eval_precision": 0.9574556473290651,
7
+ "eval_recall": 0.9506721017130101,
8
+ "eval_runtime": 14.8896,
9
+ "eval_samples_per_second": 335.804,
10
+ "eval_steps_per_second": 5.306
11
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9369e0498e743fd2563ac1aee389eea156d6543b4d9858c54188e1e3400d605b
3
+ size 435915992
special_tokens_map.json ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "cls_token": {
3
+ "content": "[CLS]",
4
+ "lstrip": false,
5
+ "normalized": false,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "mask_token": {
10
+ "content": "[MASK]",
11
+ "lstrip": false,
12
+ "normalized": false,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "pad_token": {
17
+ "content": "[PAD]",
18
+ "lstrip": false,
19
+ "normalized": false,
20
+ "rstrip": false,
21
+ "single_word": false
22
+ },
23
+ "sep_token": {
24
+ "content": "[SEP]",
25
+ "lstrip": false,
26
+ "normalized": false,
27
+ "rstrip": false,
28
+ "single_word": false
29
+ },
30
+ "unk_token": {
31
+ "content": "[UNK]",
32
+ "lstrip": false,
33
+ "normalized": false,
34
+ "rstrip": false,
35
+ "single_word": false
36
+ }
37
+ }
test_results.json ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "test_accuracy": 0.9942960950558528,
3
+ "test_f1": 0.9545491518553041,
4
+ "test_loss": 0.022622624412178993,
5
+ "test_precision": 0.9572360415390746,
6
+ "test_recall": 0.9518773037460972,
7
+ "test_runtime": 189.6487,
8
+ "test_samples_per_second": 237.281,
9
+ "test_steps_per_second": 3.712
10
+ }
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "added_tokens_decoder": {
3
+ "0": {
4
+ "content": "[PAD]",
5
+ "lstrip": false,
6
+ "normalized": false,
7
+ "rstrip": false,
8
+ "single_word": false,
9
+ "special": true
10
+ },
11
+ "100": {
12
+ "content": "[UNK]",
13
+ "lstrip": false,
14
+ "normalized": false,
15
+ "rstrip": false,
16
+ "single_word": false,
17
+ "special": true
18
+ },
19
+ "101": {
20
+ "content": "[CLS]",
21
+ "lstrip": false,
22
+ "normalized": false,
23
+ "rstrip": false,
24
+ "single_word": false,
25
+ "special": true
26
+ },
27
+ "102": {
28
+ "content": "[SEP]",
29
+ "lstrip": false,
30
+ "normalized": false,
31
+ "rstrip": false,
32
+ "single_word": false,
33
+ "special": true
34
+ },
35
+ "103": {
36
+ "content": "[MASK]",
37
+ "lstrip": false,
38
+ "normalized": false,
39
+ "rstrip": false,
40
+ "single_word": false,
41
+ "special": true
42
+ }
43
+ },
44
+ "clean_up_tokenization_spaces": true,
45
+ "cls_token": "[CLS]",
46
+ "do_lower_case": true,
47
+ "extra_special_tokens": {},
48
+ "mask_token": "[MASK]",
49
+ "model_max_length": 512,
50
+ "pad_token": "[PAD]",
51
+ "sep_token": "[SEP]",
52
+ "strip_accents": null,
53
+ "tokenize_chinese_chars": true,
54
+ "tokenizer_class": "BertTokenizer",
55
+ "unk_token": "[UNK]"
56
+ }
train_results.json ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 3.0,
3
+ "total_flos": 1.8767762625368064e+16,
4
+ "train_loss": 0.1060635477882836,
5
+ "train_runtime": 842.9188,
6
+ "train_samples_per_second": 177.953,
7
+ "train_steps_per_second": 5.563
8
+ }
vocab.txt ADDED
The diff for this file is too large to render. See raw diff