CoolFace
Modelpublic

Saketh/entity-recognition-general-sota-v1-finetuned-ner

sourceHugging Facemitupdated 3y agoView on Hugging Face
1likes11downloads
Model Card

<!-- This model card has been generated automatically according to the information the Trainer had access to. You should probably proofread and complete it, then remove this comment. -->

Model description

entity-recognition-general-sota-v1-finetuned-ner

This model is a fine-tuned version of numind/entity-recognition-general-sota-v1 on Babelscape/MultiNerd dataset.

It achieves the following results on the validation set:

  • Loss: 0.0396
  • Precision: 0.9138
  • Recall: 0.9146
  • F1: 0.9142
  • Accuracy: 0.9857

Training and evaluation data

The dataset if filtered on english language and sampled first 1M on train and 100k on validation. further filtered with data containing atleast one tag from labels2ids mentioned below. Training data - 131280 items Validation data - 16410 items

Trained on all tags from the MultiNERD dataset.

labels2ids = { "O": 0, "B-PER": 1, "I-PER": 2, "B-ORG": 3, "I-ORG": 4, "B-LOC": 5, "I-LOC": 6, "B-ANIM": 7, "I-ANIM": 8, "B-BIO": 9, "I-BIO": 10, "B-CEL": 11, "I-CEL": 12, "B-DIS": 13, "I-DIS": 14, "B-EVE": 15, "I-EVE": 16, "B-FOOD": 17, "I-FOOD": 18, "B-INST": 19, "I-INST": 20, "B-MEDIA": 21, "I-MEDIA": 22, "B-MYTH": 23, "I-MYTH": 24, "B-PLANT": 25, "I-PLANT": 26, "B-TIME": 27, "I-TIME": 28, "B-VEHI": 29, "I-VEHI": 30, }

Training procedure

HF Trainer module

Training hyperparameters

The following hyperparameters were used during training:

  • learning_rate: 2e-05
  • trainbatchsize: 20
  • evalbatchsize: 20
  • seed: 42
  • optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
  • lrschedulertype: linear
  • num_epochs: 1

Training & Test set evaluation results

Training LossEpochStepValidation LossPrecisionRecallF1Accuracy
0.03231.065640.03960.91380.91460.91420.9857

Evaluation on test set: {'evalloss': 0.02707073651254177, 'evalprecision': 0.9378337879893957, 'evalrecall': 0.9518034704620784, 'evalf1': 0.9447669917943954, 'evalaccuracy': 0.9901678553418342, 'evalruntime': 133.0665, 'evalsamplespersecond': 247.305, 'evalstepspersecond': 30.917}

Framework versions

  • Transformers 4.35.2
  • Pytorch 2.1.0+cu118
  • Datasets 2.15.0
  • Tokenizers 0.15.0