xlmr-large-vimed-ner
XLM-R-large fine-tuned for BIO NER on Vietnamese clinical notes (bệnh án). It is layer L1 of the JSL-style FHIR pipeline (fhir_jsl).
Labels: SIGN (signs, vital signs, observations), SYMP (symptoms), DX (diagnoses), MED (medications), DOSE (dosage).
Training
- Data: airace, de-identified Vietnamese medical records. Checkpoint
fullis trained on all 92 dev files (ids intrain_meta.json); the 9 blind test files are held out. - 8 epochs, lr 2e-5, batch 8, 737 windows / 8,284 spans, ~103 s on one H200.
Results (span IoU ≥ 0.5, macro F1)
| test (9 blind) | dev (4-fold CV) | |
|---|---|---|
| raw output | 0.880 | 0.859 |
| + span post-processing | 0.886 | 0.868 |
| GLM few-shot (reference) | 0.732 | 0.768 |
Miss rate obs / dx / med on test: 2.4% / 4.1% / 2.1%.
Post-processing matters. The XLM-R tokenizer splits accented Vietnamese syllables (Rối → ▁R + ối), so expand predicted spans to whole words and merge combined drugs written A + B.
Usage
from transformers import pipeline
ner = pipeline("token-classification", model="qminhlb/xlmr-large-vimed-ner", aggregation_strategy="simple")
ner("Bệnh nhân sốt 38,5 độ, ho khan. Chẩn đoán: Viêm phổi. Paracetamol 500mg x 2 viên/ngày")
Input is capped at 512 tokens; split long notes into overlapping windows.
Limitations
Trained on one highly templated dataset (101 records). Expect lower accuracy on other hospitals' formats and on OCR-noisy text. Not a medical device.
- Downloads last month
- 12
Model tree for qminhlb/xlmr-large-vimed-ner
Base model
FacebookAI/xlm-roberta-large