Isotonic/distilbert_finetuned_ai4privacy_v2

token classificationtransformersentransformersonnxsafetensorsdistilberttoken-classificationgenerated_from_trainercc-by-nc-4.0
778.5K

distilbert_finetuned_ai4privacy_v2

This model is a fine-tuned version of distilbert-base-uncased on the English Subset of ai4privacy/pii-masking-200k dataset.

Useage

GitHub Implementation: Ai4Privacy

Model description

This model has been finetuned on the World's largest open source privacy dataset.

The purpose of the trained models is to remove personally identifiable information (PII) from text, especially in the context of AI assistants and LLMs.

The example texts have 54 PII classes (types of sensitive data), targeting 229 discussion subjects / use cases split across business, education, psychology and legal fields, and 5 interactions styles (e.g. casual conversation, formal document, emails etc...).

Take a look at the Github implementation for specific reasearch.

Intended uses & limitations

More information needed

Training and evaluation data

More information needed

Training hyperparameters

The following hyperparameters were used during training:

  • learning_rate: 5e-05
  • train_batch_size: 8
  • eval_batch_size: 8
  • seed: 42
  • optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
  • lr_scheduler_type: cosine_with_restarts
  • lr_scheduler_warmup_ratio: 0.2
  • num_epochs: 5

Class wise metrics

It achieves the following results on the evaluation set:

  • Loss: 0.0451

  • Overall Precision: 0.9438

  • Overall Recall: 0.9663

  • Overall F1: 0.9549

  • Overall Accuracy: 0.9838

  • Accountname F1: 0.9946

  • Accountnumber F1: 0.9940

  • Age F1: 0.9624

  • Amount F1: 0.9643

  • Bic F1: 0.9929

  • Bitcoinaddress F1: 0.9948

  • Buildingnumber F1: 0.9845

  • City F1: 0.9955

  • Companyname F1: 0.9962

  • County F1: 0.9877

  • Creditcardcvv F1: 0.9643

  • Creditcardissuer F1: 0.9953

  • Creditcardnumber F1: 0.9793

  • Currency F1: 0.7811

  • Currencycode F1: 0.8850

  • Currencyname F1: 0.2281

  • Currencysymbol F1: 0.9562

  • Date F1: 0.9061

  • Dob F1: 0.7914

  • Email F1: 1.0

  • Ethereumaddress F1: 1.0

  • Eyecolor F1: 0.9837

  • Firstname F1: 0.9846

  • Gender F1: 0.9971

  • Height F1: 0.9910

  • Iban F1: 0.9906

  • Ip F1: 0.4349

  • Ipv4 F1: 0.8126

  • Ipv6 F1: 0.7679

  • Jobarea F1: 0.9880

  • Jobtitle F1: 0.9991

  • Jobtype F1: 0.9777

  • Lastname F1: 0.9684

  • Litecoinaddress F1: 0.9721

  • Mac F1: 1.0

  • Maskednumber F1: 0.9635

  • Middlename F1: 0.9330

  • Nearbygpscoordinate F1: 1.0

  • Ordinaldirection F1: 0.9910

  • Password F1: 1.0

  • Phoneimei F1: 0.9918

  • Phonenumber F1: 0.9962

  • Pin F1: 0.9477

  • Prefix F1: 0.9546

  • Secondaryaddress F1: 0.9892

  • Sex F1: 0.9876

  • Ssn F1: 0.9976

  • State F1: 0.9893

  • Street F1: 0.9873

  • Time F1: 0.9889

  • Url F1: 1.0

  • Useragent F1: 0.9953

  • Username F1: 0.9975

  • Vehiclevin F1: 1.0

  • Vehiclevrm F1: 1.0

  • Zipcode F1: 0.9873

Training results

Training LossEpochStepValidation LossOverall PrecisionOverall RecallOverall F1Overall AccuracyAccountname F1Accountnumber F1Age F1Amount F1Bic F1Bitcoinaddress F1Buildingnumber F1City F1Companyname F1County F1Creditcardcvv F1Creditcardissuer F1Creditcardnumber F1Currency F1Currencycode F1Currencyname F1Currencysymbol F1Date F1Dob F1Email F1Ethereumaddress F1Eyecolor F1Firstname F1Gender F1Height F1Iban F1Ip F1Ipv4 F1Ipv6 F1Jobarea F1Jobtitle F1Jobtype F1Lastname F1Litecoinaddress F1Mac F1Maskednumber F1Middlename F1Nearbygpscoordinate F1Ordinaldirection F1Password F1Phoneimei F1Phonenumber F1Pin F1Prefix F1Secondaryaddress F1Sex F1Ssn F1State F1Street F1Time F1Url F1Useragent F1Username F1Vehiclevin F1Vehiclevrm F1Zipcode F1
0.64451.010880.33220.64490.70030.67140.89000.76070.87330.65760.17660.250.67830.36210.60050.69090.55860.00.24490.70950.28890.00.00.39020.77200.00.98620.80110.50880.77400.71180.54340.80880.00.83030.75620.53180.72940.46810.67790.00.89090.00.01070.99850.40000.73070.90570.86180.00.91270.82350.92110.80260.46560.63900.93830.97750.88680.82010.45260.05500.5368
0.2222.021760.12590.81700.87470.84490.94780.97080.98130.76380.74270.78370.89080.88330.87470.98140.87490.76010.97770.88340.53720.48280.00560.77850.81490.31400.99560.99350.91010.92700.94500.98530.92530.06500.00840.79620.90130.94460.92030.85550.68851.00.71520.64421.00.96230.93490.99050.97820.76560.93240.99030.97360.92740.85200.91380.96780.99220.98930.98040.96460.85560.8385
0.13313.032640.07730.91330.93710.92500.96540.98220.98150.91960.88520.97180.97850.92150.97570.99350.96510.87420.99210.94380.75680.77100.00.89980.78950.65780.99941.00.95540.95250.98230.99100.98660.04350.82930.78240.96710.97940.95710.94470.91411.00.88250.79881.00.97970.99210.99320.99430.87260.94010.98600.97920.99280.97400.96040.97300.99830.99640.99590.98900.97740.9247
0.08474.043520.05030.93680.96140.94890.97890.99550.99490.95730.94800.99290.98460.98080.99270.99620.98110.94360.99530.96950.78260.87130.16530.94580.87820.79961.01.00.98090.98160.99410.99100.99060.33890.83640.70660.98621.00.97950.96370.94291.00.94380.91651.00.98641.00.99320.99620.93520.94830.98600.98660.99760.98840.98270.98811.00.99530.99750.99450.99150.9841
0.05575.054400.04510.94380.96630.95490.98380.99460.99400.96240.96430.99290.99480.98450.99550.99620.98770.96430.99530.97930.78110.88500.22810.95620.90610.79141.01.00.98370.98460.99710.99100.99060.43490.81260.76790.98800.99910.97770.96840.97211.00.96350.93301.00.99101.00.99180.99620.94770.95460.98920.98760.99760.98930.98730.98891.00.99530.99751.01.00.9873

Framework versions

  • Transformers 4.35.0
  • Pytorch 2.0.0
  • Datasets 2.1.0
  • Tokenizers 0.14.1
DEPLOY IN 60 SECONDS

Run distilbert_finetuned_ai4privacy_v2 on Runcrate

Deploy on H100, A100, or RTX GPUs. Pay only for what you use. No setup required.