sec-bert-finer-ord-ner
A token-classification (NER) fine-tune of
nlpaueb/sec-bert-base on the
FiNER-ORD dataset,
for extracting person (PER), location (LOC), and organization (ORG)
entities from financial/SEC-filing-style English text.
This is an academic exercise: a small pipeline that runs financial-news NLP (sentiment + NER) over a corpus of company news articles.
Intended use
- Named entity recognition (PER/LOC/ORG) on financial news, earnings-call transcripts, and SEC-filing-style English text.
- Non-commercial use only — see License below.
Not intended for: general-domain NER (it's tuned for financial text), languages other than English, or any production/commercial deployment.
Label scheme
BIO tagging over three entity types:
| id | label |
|---|---|
| 0 | O |
| 1 | B-PER |
| 2 | I-PER |
| 3 | B-LOC |
| 4 | I-LOC |
| 5 | B-ORG |
| 6 | I-ORG |
Training data
FiNER-ORD
(gtfintechlab/finer-ord), a manually annotated financial NER dataset.
Token-level rows were regrouped into sentences (grouped by doc_idx/sent_idx)
and labels aligned to WordPiece subwords, keeping only the first subword of
each token labeled (other subwords set to -100, ignored in the loss).
| split | sentences |
|---|---|
| train | 3,262 |
| validation | 402 |
| test | 1,075 |
Training procedure
Fine-tuned from nlpaueb/sec-bert-base with Hugging Face Trainer:
- learning rate: 3e-5
- batch size: 16 (train) / 32 (eval)
- epochs: 8
- weight decay: 0.01
- mixed precision (fp16)
load_best_model_at_end=True, selected by validation F1- seed: 42
Evaluation results
Metrics on the FiNER-ORD test split, using the best-validation-F1 checkpoint (selected during training):
| metric | value |
|---|---|
| F1 | 0.770 |
| Precision | 0.741 |
| Recall | 0.802 |
| Accuracy | 0.979 |
(Best validation-split F1 during training: 0.820.)
Usage
from transformers import AutoTokenizer, AutoModelForTokenClassification, pipeline
tokenizer = AutoTokenizer.from_pretrained("gamug/sec-bert-finer-ord-ner")
model = AutoModelForTokenClassification.from_pretrained("gamug/sec-bert-finer-ord-ner")
ner = pipeline("ner", model=model, tokenizer=tokenizer, aggregation_strategy="simple")
ner("3M Company (NYSE:MMM) reported results with CEO Mike Roman on the call.")
License
This model is a derivative of two upstream works with different licenses:
- Base model
nlpaueb/sec-bert-base:CC-BY-SA-4.0 - Training data
gtfintechlab/finer-ord:CC-BY-NC-4.0
Because the training data is non-commercial-only, this fine-tuned model is
released under CC-BY-NC-4.0: attribution required, non-commercial use
only. Please credit both upstream works (linked above) if you use or build
on this model.
- Downloads last month
- 29
Model tree for gamug/sec-bert-finer-ord-ner
Base model
nlpaueb/sec-bert-base