DistilBERT for Named Entity Recognition

This repository contains a fine-tuned DistilBERT model trained on the CoNLL-2003 dataset for Named Entity Recognition (NER). The model identifies and classifies named entities in English text.

Model Details

  • Base Model: distilbert-base-uncased
  • Task: Named Entity Recognition (NER)
  • Dataset: CoNLL-2003
  • Framework: PyTorch and Hugging Face Transformers

The model recognizes four entity categories:

  • PER: Person
  • ORG: Organization
  • LOC: Location
  • MISC: Miscellaneous entities

It uses the BIO tagging scheme to identify entity boundaries.

How to Use

from transformers import pipeline

ner_pipeline = pipeline(
    "ner",
    model="mohammad748/distilbert-conll2003-ner",
    aggregation_strategy="simple"
)

text = "Barack Obama was born in Hawaii."

results = ner_pipeline(text)

for entity in results:
    print(entity)

The output includes the identified entities, their categories, confidence scores, and positions in the text.

Downloads last month
33
Safetensors
Model size
66.4M params
Tensor type
F32
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for mohammad748/distilbert-conll2003-ner

Finetuned
(12816)
this model

Dataset used to train mohammad748/distilbert-conll2003-ner